smtp: fix processing of initial dot in data #2304

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants
@monnerat
Collaborator

monnerat commented Feb 11, 2018

This fixes a long standing bug in SMTP.
Even test 911 was inaccurate. Test server did not handle the case.

smtp: fix processing of initial dot in data
RFC 5321 4.1.1.4 specifies the CRLF terminating the DATA command
should be taken into account when chasing the <CRLF>.<CRLF> end marker.
Thus a leading dot character in data is also subject to escaping.

Tests 911 and test server are adapted to this situation.
New tests 951 and 952 check proper handling of initial dot in data.
@bagder

bagder approved these changes Feb 12, 2018

@monnerat monnerat closed this in 62cf2d1 Feb 12, 2018

@monnerat monnerat deleted the monnerat:smtpdotescape branch Feb 12, 2018

@curl curl locked as resolved and limited conversation to collaborators May 13, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.