Sendmail and .

email-serversendmailsmtp

I have a Sendmail MTA running version 8.15.2 on Debian 9 that relays mail for a single domain. My issue is that when the server encounters a . at anytime after the headers and the DATA command, it terminates the mail connection, as it should according to RFC 5321. This could occur prior to the end of a boundary for a multipart message, effectively truncating any other content including attachments. (eg. if a . was encountered within an HTML multipart with attachments, all remaining HTML content including any other multipart objects such as attachments would be truncated).

My confusion is that other MTAs (eg. Exchange) for other organizations will receive the same message and process the content without any truncation. (I am assuming they are waiting for an EOF instead.)

I have attempted the define(confIGNORE_DOTS',true') in the m4 sendmail configuration with no luck, however, I understand this configuration is essentially ignored during server operations, and is intended for local transmission from the command line.

My only other option that I can think of would be to encode any . to hex (ie. 2E) prior to Sendmail's processing, however I have not been able to find any examples on the web.

I am assuming other MTAs such as Postfix or Exim would run into the same issue.

If necessary, I can post Sendmail's configuration file and server runtime parameters.

Any help is truly appreciated.

Best Answer

sendmail (SMTP/MTA) server masks "single dot" lines in the message itself in RFC described way.

Most likely you do not provide some important "detail".

RFC-5321 section 4.5.2

4.5.2. Transparency

Without some provision for data transparency, the character sequence "." ends the mail text and cannot be sent by the user. In general, users are not aware of such "forbidden" sequences. To allow all user composed text to be transmitted transparently, the following procedures are used:

o Before sending a line of mail text, the SMTP client checks the first character of the line. If it is a period, one additional period is inserted at the beginning of the line.

o When a line of mail text is received by the SMTP server, it checks the line. If the line is composed of a single period, it is treated as the end of mail indicator. If the first character is a period and there are other characters on the line, the first character is deleted.