Signing too early #12

Closed
janithp opened this Issue Feb 20, 2014 · 3 comments

Projects

None yet

3 participants

@janithp
janithp commented Feb 20, 2014

Hi,

we're using the gem with ActionMailer 3.2.13 and Rails 3.2. Interceptor seems to be able to sign the message. But Using port25 verifier it fails saying "fail (wrong body hash: expected n9hw0s6A+39X2zHc07dPuzj1783GTadt3NHjLpqyZ/g=)".

I tried different lengths of html body in the email and it passes for small email body but fail for large ones. Is it possible that register_interceptor(Dkim::Interceptor) binds too early?

I have dkim initializer that calls register_interceptor. I'm also using html and text templates with ActionMailer.

Any ideas?

@carsonreinke
Collaborator

Is it possible your MTA is modifying the message? Try manually signing without the interceptor. Though, unless you have another interceptor, it is unlikely that the signed message is being modified via Mail gem.

@jhawthorn
Owner

@janithp is it possible for you to provide the exact signed message which had an incorrect body hash? (value of mail.to_s after delivery would provide this)

@janithp
janithp commented Feb 26, 2014

Thank for the support! Actually it seemed to just start working all of a sudden. This was a strange one. But this is not an issue anymore, I will close it.

@janithp janithp closed this Feb 26, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment