Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X-NCJF-Result: header confuses webmail due to incorrect termination #108

Open
AurumVR opened this issue Nov 15, 2021 · 4 comments
Open

X-NCJF-Result: header confuses webmail due to incorrect termination #108

AurumVR opened this issue Nov 15, 2021 · 4 comments
Labels
bug Something isn't working

Comments

@AurumVR
Copy link

AurumVR commented Nov 15, 2021

My email server received a mail sent by WP-Mail SMTP and while Thunderbird displays it properly it confuses my webmail to display the long X-NCJF-Result header as part of the email, with the actual content at the bottom.

After analyzing the issue with my servers maker they came to the following conclusion:
"the reason is that the lines for that header are terminated by 0D0D0A (carriage return, carriage return, linefeed) instead of carriage return, linefeed. So webmail is seeing this as two lines."

Relevant part of the header:

X-Mailer: WPMailSMTP/Mailer/smtp 3.2.0
MIME-Version: 1.0
Content-Type: text/html; charset=utf-8
X-Virus-Scanned: ClamAV using ClamSMTP
X-NCJF-Result: VYyUq+rDJF2I/ZmOHmn7Xnxn1A4fbuKO03TTGjHf3dgUFmIek19gQrN9HlDR/z2

J5hK9U6FgB6njLc4naqRPfY4j53ceImRRZdBU/OF2F3nB9H4ze/wzla2c3U/d1P1LwqMY3QTgIpcBY

+KlO+r+Onk8gTOzymBqGb1DeqtVhDsndwBS3egOE0NW44DiP0Xa4kQuH0g6+OvOo7TRar3kDDArO3L

[ ... ]

vTOXIdlPewRSuXBh/f//lcJAVlJt5N0j8LuN3xaNlWgCJbgXL24hvP8n1aZUbG98j5cJ39+/Vq/5gU

xoLdwwzNFb8W9ujS9PcxPfkZRNsd5mCgk7LwSRRlRa7sp7JEQeUzrZePe2vaZVX94UvC8M=

X-NCJF-Version: 13
Return-Path: [email protected]

@AurumVR AurumVR added the bug Something isn't working label Nov 15, 2021
@capuderg
Copy link
Contributor

Hi @AurumVR,

so if I understand this correctly, the X-NCJF-Result header has the 0D0D0A string in it and this breaks your webmail client and does not display the email properly?

Our plugin does not add any special header line ending code to the emails that are sent, we are using the WP Core PHPMailer in some of our mailers or direct API implementation with the mailer providers.

Which mailer are you using in our plugin settings?

Which plugin adds this X-NCJF-Result header to the email?

Take care!

@AurumVR
Copy link
Author

AurumVR commented Nov 15, 2021

Hi!

I haven't analysed the mail for protocol errors, MailEnable guys did as I run their server.

Setup is:
WP-Mail sends through a smart host, which also serves as another mail account for me. To double check sent a mail from there to the account affected, that arrived fine, readable no problem.

WP notified me about a login attempt (that I performed) through the same smart host to the same email, that arrived with the X-NCJF header in the mail, actual content at the bottom.

Regarding which plugin adds this X-NCJF-Result header to the email... I have no idea. If not yours, then.. I'll have to contact my web dev for ideas.

Attached the source of a mail affected, before opened by webmail:

3A6DD2D9C7FF4E959F633085BD891D65.MAI.txt

@capuderg
Copy link
Contributor

Hi @AurumVR,

I just tested by adding a custom header (with 165 char long value) to an email that was sent with our plugin. I used our Sendinblue and Other SMTP mailers to send two test emails... Which mailer are you using (in our plugin settings)?

The value of this custom header was not broken down into several 78 char long rows, like your example. The value was kept as a single string without linebreaks...

I think you should contact the support of the plugin that is adding this custom header X-NCJF-Result to the email and ask them if they add those line breaks manually...

Let me know what they'll say.

Take care!

@AurumVR
Copy link
Author

AurumVR commented Nov 15, 2021

Hi!

I'm using "Other SMTP".

I've taken a look into the test email I sent through the smart host WP-Mail uses and there are the X-NCJF headers in it but it doesn't cause a problem in webmail like when it comes from WP.

I've attached its source here, perhaps you notice a difference I can't:

A8281985F8904C3389C1F7B0CBA5E174.MAI.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants