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

Bug: Current DKIM header canonicalization can lead to invalid DKIM #215

Closed
tadcos opened this issue Jul 17, 2019 · 5 comments
Closed

Bug: Current DKIM header canonicalization can lead to invalid DKIM #215

tadcos opened this issue Jul 17, 2019 · 5 comments

Comments

@tadcos
Copy link

tadcos commented Jul 17, 2019

In DKIMSigner class header Canonicalization is hard coded to SIMPLE (RELAXED should be better, or we could let the user choose). This may lead to Invalid Dkim, see https://wordtothewise.com/2016/12/dkim-canonicalization-or-why-microsoft-breaks-your-mail/

dkimSigner.setHeaderCanonicalization(Canonicalization.SIMPLE);

@bbottema
Copy link
Owner

Hmm, interesting. I wonder if I should make relaxed the default, assuming most users won't know about this gotcha. Does that make sense? I'm not really into DKIM that much to be able to judge that properly though :/

@tadcos
Copy link
Author

tadcos commented Jul 27, 2019 via email

@bbottema
Copy link
Owner

Ok, if you feel up to it, I would accept a PR on master. Else I will pick it up in some time.

@bbottema
Copy link
Owner

@toKrause do you have any strong feelings on this (or safety-warning)?

@bbottema bbottema changed the title Dkim signature - Feature request Feature request: Make DKIM header canonicalization RELAXED instead of SIMPLE Aug 16, 2019
@bbottema bbottema changed the title Feature request: Make DKIM header canonicalization RELAXED instead of SIMPLE Enhancement: Make DKIM header canonicalization RELAXED instead of SIMPLE Aug 16, 2019
@bbottema bbottema changed the title Enhancement: Make DKIM header canonicalization RELAXED instead of SIMPLE Bug: Current DKIM header canonicalization can lead to invalid DKIM Aug 16, 2019
@bbottema
Copy link
Owner

Released in 5.3.0. I'll revert it if @toKrause comes up with something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants