Read section five of RFC 2047 which explains where MIME encoded words can
be used
https://datatracker.ietf.org/doc/html/rfc2047#section-5
They cannot be used in addr-specs, which is where you're using them
On 2 May 2022 09:07:22 Alexander Neilson via mailop <mailop@mailop.org> wrote:
Hi Team
Please feel free to let me know this was not a suitable question for this
list, apologies in advance if so.
At $dayjob one of my fairly new staff forwarded me a bounce message from
gmail for an outbound email we were sending to a supplier.
Headers are down at the end of the email but the bounce message was:
554
5.0.0 <gmail-smtp-in.l.google.com #5.0.0 smtp; 550-5.7.1 [185.201.19.76 14]
Messages missing a valid address in From: 550 5.7.1 header, or having no From:
header, are not accepted. l6-20020a05600c2cc600b0039423b63859si6456162wmc.204 -
gsmtp>
A test email sent from the same system to my own emails (hosted by gmail)
didn't receive a bounce back so I am of the feeling there must be a From:
header being included correctly in the message. So trying to investigate
the header as to why it may not be a valid address and I was hoping for
some assistance / guidance as to if I am interpreting the RFC correctly as
to validity or am I barking up the wrong tree entirely.
The user whose email bounced has a last name with an accented character
which is not a valid ASCII printable character and if I am reading RFC 6854
S2.1 and RFC 5322 S2.2 correctly the header field must contain printable
ASCII code points (and a couple of allowed other characters in the header
field body.
I did note that the from header in the bounced email was shown as:
=?utf-8?b?IkZlcm5hbmRvIFNhbnRvcyBEZSBTw6EiIDxmZXJuYW5kby5zQGdsLmNvLm56?=
=?utf-8?b?Pg==?=
Converting this from Base64 encoded UTF-8 into plain UTF-8 I see the string:
"Fernando Santos De Sá" <fernand...@gl.co.nz>
Which is correct for my user (however obviously not ASCII.
A few questions
Have I correctly identified the issue (or most likely issue) triggering
this message from gmail?
Is there a good document for guidance on catching invalid values (including
UTF-8 strings) and how they should be handled for headers in email (I see
in RFC 5322 S3.2.4 there is an allowance for quoted strings that allow
characters that are other than allowed in atoms but I guess if that was
valid for what I was generating above the email wouldn't have bounced -
possibly an issue because the whole string was Base64 encoded?) so I can
look to catch situations that are problematic in future and provide a
generalized system?
Does anyone have any guidance on other situations they have hit with email
systems rejecting what is often accepted so I can try to generally test for
known "fun interactions" and handle them?
(noting these emails are generated out of our in house developed operations
management system so its my code that did the wrong thing originally here
and what I need to get fixed)
Thank you for your time.
Headers from the bounce:
Notes:
email system isn't currently depositing emails into the sent box so user
receives CC of emails sent on their behalf so they see what has gone out
antispamcloud is our spam filter provider who scans all inbound and
outbound emails but error message was generated by gmail when trying to
hand off the email. Providers web portal for checking message status
decoded source email address and name string.
Original
message headers:
Return-Path: <fernand...@gl.co.nz>
Received: from gl-ex02.gl.co.nz ([45.118.188.115])
by mx262.antispamcloud.com with esmtps
(TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128)
(Exim 4.92)
(envelope-from <fernand...@gl.co.nz>)
id 1nlMq1-000A9Y-Mo
for <SUPPLIER EMAIL ADDRESS>; Mon, 02 May 2022 05:35:15 +0200
Received: from GL-EX02.internal.gl.co.nz (192.168.33.22) by
GL-EX02.internal.gl.co.nz (192.168.33.22) with Microsoft SMTP Server
(version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
15.2.1118.7; Mon, 2 May 2022 15:35:02 +1200
Received: from gl-be04.internal.gl.co.nz (192.168.33.37) by
GL-EX02.internal.gl.co.nz (192.168.33.22) with Microsoft SMTP Server id
15.2.1118.7 via Frontend Transport; Mon, 2 May 2022 15:35:02 +1200
Content-Type: text/plain
MIME-Version: 1.0
From: =?utf-8?b?IkZlcm5hbmRvIFNhbnRvcyBEZSBTw6EiIDxmZXJuYW5kby5zQGdsLmNvLm56?=
=?utf-8?b?Pg==?=
To: <SUPPLIER EMAIL ADDRESS>
CC: <fernand...@gl.co.nz>
Subject: Global Jobsheet <INTERNAL REFERENCE NUMBER> - Fixing
Message-ID: <0368d464-ce75-4993-893a-6861eaebc...@gl-ex02.internal.gl.co.nz>
Date: Mon, 2 May 2022 15:35:02 +1200
X-Originating-IP: 45.118.188.115
X-MailAssure-Domain: gl.co.nz
X-MailAssure-Username: 45.118.188.115
Authentication-Results: antispamcloud.com; auth=pass
smtp.auth=45.118.188....@gl.co.nz
X-MailAssure-Outgoing-Class: ham
X-MailAssure-Outgoing-Evidence: Combined (0.09)
X-Recommended-Action: accept
X-Filter-ID:
Pt3MvcO5N4iKaDQ5O6lkdGlMVN6RH8bjRMzItlySaT/SWj98WPq4CtCgxem7mj3kPUtbdvnXkggZ
3YnVId/Y5jcf0yeVQAvfjHznO7+bT5yFJoHAUTOjf1aFNKd7CnV+O+QzD67WU21zwtdtt9m3QQ/C
h5SE4jAyhe1COeASyU/5LRRHPJulhFeIJoq48nHN5WCy5VkstzhnxgTXqsdmp0LoMm7rojSS/Sxh
qDMvUmM1LQhYNBd1FP7U4OZT407FpuGXed8VjoeeEKguXydrkSH+3gVyyqW6++HqPXPhE0NcYe4a
MjKFhzJKmH0BGgJrQLk01CIbYZxgOAvibIM/Z6W7d1t4HzZ7ipKhj9PWSiyZOZh/196Uh/xDSW9g
kA3LEWgKIJ7Ay0RVJqlA03GHx5mIvc52cbna8kydvLENQgQtChAJ8MhPXbXvhZAyklffRAwX31WV
Y5lWjWxuGSRuxRfiiXKDnS3cS+VcIvEFMphhKzy27dJ+eI97x1+KvbnG5YE5enyccp7RH4WQio3u
Ga0qZK6eP2yJPYHuIR7M4/shEWyJzIkwSFAW0Pw8uiKeltK+MtP+Q+MOaQQT+Vn8BIlSPGIn6LIh
6vfZt6Tuc+uVfVL7ygxIxIEhQBgsu7ia6J1fhOzjF0b4LXcjJZ5loquXN5jFSCbczMwQYmA5Fgmk
3lS1t6QdEPz08qMKOQH7dKFTuGZxy4YnIveHBkunQM3tbGkpI7MoUuyldIYotCoZ2o2u/CrAXLOd
WYnYEYBY7yFM015AwIoiYphoS1BbksZFIaiNfA1zBMRlEGhUgk1m29ZSQVhuDL+eB599vr8wv9JV
jn9o4RbEfAAaUi4E6ZotLE92++nhcRkxchgMy3wccBIk1Sag4dKiqCrF8eZZ6QJJezUWPaFxkAYK
LAdXMiInFuivqX43I6n3Msjvp21riINHgmmecAYSEJNZL831ZtvWUkFYbgy/ngeffb6/MCvyXVr4
HdvxYmxHTDNCZ8bv1XAEUSSYNAj1RlxWAO8Qse0lmQaXQFAK5/0rdNGhms0k82NhtXl7s69uM9s5
/Cb06J8uG+dikNJv32G4gfdf
X-Report-Abuse-To: s...@quarantine11.antispamcloud.com
X-Exim-DSN-Information: Due to administrative limits only headers are returned
Regards
Alexander
Alexander Neilson
Neilson Productions Limited
alexan...@neilson.net.nz
021 329 681022 456 2326
_______________________________________________
mailop mailing list
mailop@mailop.org
https://list.mailop.org/listinfo/mailop
--
Paul Smith Computer Services
Tel: 01484 855800
Vat No: GB 685 6987 53
Sign up for news & updates at http://www.pscs.co.uk/go/subscribe
_______________________________________________
mailop mailing list
mailop@mailop.org
https://list.mailop.org/listinfo/mailop