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

validation rule for RFC5322 headers From and Sender is too strict #380

Closed
pengux opened this issue Jul 7, 2023 · 3 comments
Closed

validation rule for RFC5322 headers From and Sender is too strict #380

pengux opened this issue Jul 7, 2023 · 3 comments
Labels
bug Something isn't working released

Comments

@pengux
Copy link

pengux commented Jul 7, 2023

The check for value in From and Sender header at

if len(senderAddr) == 1 && senderAddr[0].Address == addresses[0].Address {

seems too strict as the specification doesn't mention that the values in the fields cannot be the same. Furthermore, it is common for email messages to have different names in the fields but with the same email addresses such as:

From: "John Doe via Service" <no-reply@example.com>
Sender: "Service" <no-reply@example.com>

The check should either be removed or perhaps modified so it takes into consideration the equality of the names too.

@LBeernaertProton
Copy link
Contributor

Hey @pengux. Thank you for the report and for bringing this up. We have internally tracked this as GODT-2776.

@LBeernaertProton LBeernaertProton added the bug Something isn't working label Jul 7, 2023
@pengux
Copy link
Author

pengux commented Jul 7, 2023

@LBeernaertProton Thanks! I've also investigated a bit more and there are many email messages that also have the same name values in both headers, so modifying the rule won't help. Only removing it would allow those emails to be accepted.

LBeernaertProton added a commit that referenced this issue Jul 7, 2023
They were too restrictive. From and Sender can have the same address.

Closes: #380
@github-actions
Copy link

github-actions bot commented Jul 7, 2023

🎉 This issue has been resolved in version 0.17.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

No branches or pull requests

2 participants