GithubHelp home page GithubHelp logo

Comments (11)

carsonreinke avatar carsonreinke commented on August 10, 2024

I think you forgot the link. Mind attaching?

from dkim.

JakeTheSnake3p0 avatar JakeTheSnake3p0 commented on August 10, 2024

Oops! Here you go: https://www.osso.nl/blog/thunderbird-postfix-dkim-invalid-body-hash/

I've logged into my spamdrain account and they say there's a problem as well. "Computed body hash is different from the expected one"

from dkim.

JakeTheSnake3p0 avatar JakeTheSnake3p0 commented on August 10, 2024

The first header shown here is generated whenever I send emails from my email client (Thunderbird):

DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
    d=whatever.com; s=default; h=Content-Type:MIME-Version:Date:
    Message-ID:Subject:From:To:Reply-To;
    bh=FVAhhJz6FzTfjyLzFYYUDyyNxa/NB6YNmUG8BROFscA=; b=0560610thBwMn0khOFFm5yFW2r
    /iNutZkbdGoLExrE0riCcoRjShKiIV5bRtumlHj69kp+XAi5RjmUtcVqYF1xhyizuifuSwqTwDh9V
    afCUX/FTCv8TxglpBErRpIoGUrJPAJUVO9j7OO66SCW1yYHbWSu6UDpDyp1c7xWN/Fh9CpeQXnDM6
    zI5QW7MwJbufPrXVQ1V010X1o447R6OSuVaMDi16u3G50u9RUGNLqZa+6cPJwEXx6QZ7hVt32LK1I
    QUDU34VjzyHFrTjmanT4Lp3NDr6PAF2BKK5LWm8XkHpEmHcu3yr9V4RfrYu07XLzJUjTM2n5lXOPs
    ux/aEJeA==;

However this is an example of one sent from my rails app:

DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=whatever.com; q=dns/txt; s=default; t=1446495573; bh=v+Gie+4nzghZzpOSiQC08piKoNeY/n4Q11yNcr/BPCM=; h=date:from:to:message-id:subject:mime-version:content-type:content-transfer-encoding; b=011109VB+ZbHcdo0JM4USctVg83vJvG9QKWlgn/bI8jwtI1LXdHg5f22huIxTwOruuh+6nXsRkBR/SMzTDQ5z1FnFbuYD0JbEW47X6Qu0ItMseZwBnkVNKsfP0Qxt3LbmPHsWhM1Rg3ne78tLq4OLBrs0J+fLMk2tRAHJ1JRWakP2hG8pg6FPEWjWKi3da5555TjVC0zg1osvwF1+l/QoruPZ+hoawKajG1LNY/Dub7xlGzDrJqtjxtvO+h7Iutk30y0MaiP7I3782uOJ+pAuBSQQBM8TEdisjkllymBT4skhSt+W2LjNiQBxCZtIS6mhAAuBK48FnOtMtC5v6QHhQ==

I modified the string so don't worry about its validity, I only illustrate the fact that the one sent from my email client has new lines and the one sent via the rails app is all on one line.

from dkim.

carsonreinke avatar carsonreinke commented on August 10, 2024

I see what you mean. A lot of the clients wrap the header too. Let me see what I can find.

On Nov 3, 2015, at 9:36 AM, Jake Mitchell [email protected] wrote:

The first header shown here is generated whenever I send emails from my email client (Thunderbird):

DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=sprucewoodshores.com; s=default; h=Content-Type:MIME-Version:Date:
Message-ID:Subject:From:To:Reply-To;
bh=FVAhhJz6FzTfjyLzFYYUDyyNxa/NB6YNmUG8BROFscA=; b=0560610thBwMn0khOFFm5yFW2r
/iNutZkbdGoLExrE0riCcoRjShKiIV5bRtumlHj69kp+XAi5RjmUtcVqYF1xhyizuifuSwqTwDh9V
afCUX/FTCv8TxglpBErRpIoGUrJPAJUVO9j7OO66SCW1yYHbWSu6UDpDyp1c7xWN/Fh9CpeQXnDM6
zI5QW7MwJbufPrXVQ1V010X1o447R6OSuVaMDi16u3G50u9RUGNLqZa+6cPJwEXx6QZ7hVt32LK1I
QUDU34VjzyHFrTjmanT4Lp3NDr6PAF2BKK5LWm8XkHpEmHcu3yr9V4RfrYu07XLzJUjTM2n5lXOPs
ux/aEJeA==;
However this is an example of one sent from my rails app:

DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sprucewoodshores.com; q=dns/txt; s=default; t=1446495573; bh=v+Gie+4nzghZzpOSiQC08piKoNeY/n4Q11yNcr/BPCM=; h=date:from:to:message-id:subject:mime-version:content-type:content-transfer-encoding; b=011109VB+ZbHcdo0JM4USctVg83vJvG9QKWlgn/bI8jwtI1LXdHg5f22huIxTwOruuh+6nXsRkBR/SMzTDQ5z1FnFbuYD0JbEW47X6Qu0ItMseZwBnkVNKsfP0Qxt3LbmPHsWhM1Rg3ne78tLq4OLBrs0J+fLMk2tRAHJ1JRWakP2hG8pg6FPEWjWKi3da5555TjVC0zg1osvwF1+l/QoruPZ+hoawKajG1LNY/Dub7xlGzDrJqtjxtvO+h7Iutk30y0MaiP7I3782uOJ+pAuBSQQBM8TEdisjkllymBT4skhSt+W2LjNiQBxCZtIS6mhAAuBK48FnOtMtC5v6QHhQ==
I modified the string so don't worry about its validity, I only illustrate the fact that the one sent from my email client has new lines and the one sent via the rails app is all on one line.


Reply to this email directly or view it on GitHub.

from dkim.

carsonreinke avatar carsonreinke commented on August 10, 2024

Related Perl lib for the wrapping: http://search.cpan.org/~jaslong/Mail-DKIM/lib/Mail/DKIM/TextWrap.pm

from dkim.

JakeTheSnake3p0 avatar JakeTheSnake3p0 commented on August 10, 2024

I'm not sure that this Perl lib is what I need as I'm using RoR/ActionMailer to generate my emails. This gem hooks into ActionMailer during the delivery process which happens outside of the scope of my app.

I tried forking your repo and figuring out at what point the headers are generated but I can't make heads or tails of how things come together. The wrapping would need to be done somewhere in this gem.

from dkim.

carsonreinke avatar carsonreinke commented on August 10, 2024

Sorry for not clarifying, I just noted that as a reference to the Perl library which wraps the DKIM header. A new feature would be have to be added to provide the wrapping.

If you are using the interceptor, the header is actually added here: https://github.com/jhawthorn/dkim/blob/master/lib/dkim/interceptor.rb#L18

from dkim.

cg2v avatar cg2v commented on August 10, 2024

I have a partial implementation of this feature at https://github.com/cg2v/dkim/tree/interceptor_wrap_dkim_header

It has no new tests, and fails the Dkim::InterceptorTest#test_same_output_as_direct_usage because I implemented the change in mail/dkim_field.rb and the output no longer matches.

from dkim.

carsonreinke avatar carsonreinke commented on August 10, 2024

@cg2v Definitely throw that over to a PR and lets get that going!!! The test failure is probably just because of assertion is against an unwrapped header.

from dkim.

cg2v avatar cg2v commented on August 10, 2024

It doesn't assert against a fixed result that includes an unwrapped header, but against a call to Dkim.sign that generates one. If most people use Dkim.sign, then you need a solution that works there too. I didn't touch that part because the mixture of data and presentation in the Dkim::Header classes makes this harder.

from dkim.

oz avatar oz commented on August 10, 2024

🆙 Hey!

I know that time is a finite and precious resource, but can I get someone to look at this PR some time, or maybe the issue is a won't fix ?

from dkim.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.