[issue43949] binascii.Error raised in smtplib when initial_response_ok=False

2021-05-06 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: > I am using Magic Winmail Server2.4(build 0530) as a SMTP server, which > appears dont support initial_response, so I set initial_response_ok=False and > got this Error. currently I catch this error and ignore it to evade program > failed, i

[issue43949] binascii.Error raised in smtplib when initial_response_ok=False

2021-05-06 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: A stronger case is the "Formal Syntax" on https://tools.ietf.org/html/rfc4954#page-13 : > continue-req= "334" SP [base64] CRLF > ;; Intermediate response to the AUTH >

[issue43949] binascii.Error raised in smtplib when initial_response_ok=False

2021-05-06 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: Technically, that is not the fault of smtplib.SMTP The standard for SMTP AUTH specifies that characters following "334 " MUST be Base64 encoded. See https://tools.ietf.org/html/rfc4954#page-4 , 3rd paragraph: > A server challenge is sent a

[issue27820] Possible bug in smtplib when initial_response_ok=False

2021-03-09 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: Hi Senthil, You're right, it does need a guard. According to my knowledge there is no AUTH mechanism that will send more than 3 challenges; they should fail afterwards with 535 or similar. Servers that don't do that should be considered buggy/broken. So

[issue27820] Possible bug in smtplib when initial_response_ok=False

2021-02-25 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: PR available on GitHub and it's already more than one month since the PR was submitted, so I'm pinging this issue. -- ___ Python tracker <https://bugs.python.org/issue27

[issue39232] asyncio crashes when tearing down the proactor event loop

2021-01-29 Thread Pandu E POLUAN
Change by Pandu E POLUAN : -- nosy: +pepoluan ___ Python tracker <https://bugs.python.org/issue39232> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41868] SMTPLIB integrate or provide option to use "logging"

2021-01-11 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: Will patching smtplib.SMTP._print_debug do? You can subclass from smtplib.SMTP this way: class MySMTPClient(smtplib.SMTP): def __init__(self, *args, logger=None, **kwargs): super().__init__(*args, **kwargs) self.logger = logger def

[issue27820] Possible bug in smtplib when initial_response_ok=False

2021-01-11 Thread Pandu E POLUAN
Change by Pandu E POLUAN : -- components: +Tests ___ Python tracker <https://bugs.python.org/issue27820> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27820] Possible bug in smtplib when initial_response_ok=False

2021-01-05 Thread Pandu E POLUAN
Change by Pandu E POLUAN : -- keywords: +patch pull_requests: +22948 stage: -> patch review pull_request: https://github.com/python/cpython/pull/24118 ___ Python tracker <https://bugs.python.org/issu

[issue42498] smtplib is glitchy after receive server code 500

2021-01-05 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: The "problem" is that smtplib.SMTP does the following, in essence: 1. Open connection to server 2. Send EHLO 3. Read server response The PROXY injection causes a response from the server, but the response gets "cached" in the

[issue27820] Possible bug in smtplib when initial_response_ok=False

2021-01-04 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: Okay, I finally figured out what's wrong. This piece of code in `test_smtplib.py`: if self.smtp_state == self.AUTH: line = self._emptystring.join(self.received_lines) print('Data:', repr(line), file=smtpd.DEBUGSTREAM

[issue27820] Possible bug in smtplib when initial_response_ok=False

2020-12-31 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: I tried adding the code below to test_smtplib.py: def testAUTH_LOGIN_initial_response_notok(self): self.serv.add_feature("AUTH LOGIN") smtp = smtplib.SMTP(HOST, self.port, local_hostname='localhost',

[issue27820] Possible bug in smtplib when initial_response_ok=False

2020-12-30 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: I tried creating a PR, but for the life of me I couldn't wrap my head around how testAUTH_LOGIN is being performed (it's in Lib/test/test_smtplib.py) All I know is, the test doesn't AT ALL test for situations where initial_response_ok=False. ALL tests

[issue27820] Possible bug in smtplib when initial_response_ok=False

2020-12-13 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: This issue is still a bug for Python 3.6 and Python 3.8 I haven't checked on Python 3.7 and Python 3.9 -- versions: +Python 3.6, Python 3.8 ___ Python tracker <https://bugs.python.org/issue27

[issue27820] Possible bug in smtplib when initial_response_ok=False

2020-12-13 Thread Pandu E POLUAN
Pandu E POLUAN added the comment: Hi, I'm one of the maintainers of aio-libs/aiosmtpd. This issue also bit me when trying to write unit tests for aio-libs/aiosmtpd AUTH implementation But I partially disagree with Dario D'Amico's changes, specifically the suggested change in the auth_login