How to add Date: header to received emails without break DKIM signatures

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












Some server send email without Date header, and Thunderbird doesn't recognize the date.So, I want to use following settings and add Date header.



local_header_rewrite_clients = permit_inet_interfaces, ermit_sasl_authenticated
always_add_missing_headers = yes


But postfix.org says this may break DKIM signatures.
Is there a way to add Date headers withoud break DKIM signatures ?
(My mail server using DKIM.)



Example of no Date header mail :



Return-Path: <xxxxxx@example.com>
X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on example.net
X-Spam-Level: ***
X-Spam-Status: No, score=3.7 required=8.0 tests=CONTENT_TYPE_PRESENT,
FROM_MISSP_EH_MATCH,IP_LINK_PLUS,ISO2022JP_BODY,ISO2022JP_CHARSET,
MISSING_DATE,MISSING_MID,NORMAL_HTTP_TO_IP,ONEGAI,QENCPTR1,RCVD_IN_DNSWL_NONE,
RCVD_IN_MSPIKE_H2,RENRAKU,SPF_HELO_PASS,SPF_SOFTFAIL,TO_NO_BRKTS_FROM_MSSP
autolearn=no autolearn_force=no version=3.4.0
X-Original-To: xxxxx@example.net
Delivered-To: xxxxx@example.net
Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
(No client certificate requested)
by example.net (Postfix) with ESMTPS id D53991D45
for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
DKIM-Filter: OpenDKIM Filter v2.11.0 example.net D53991D45
Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
by xxxxx.example.org (Postfix) with ESMTP id 77EFF8DC01
for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
Received: (qmail 23991 invoked by uid 101); 5 Sep 2018 20:44:43 +0900
Received: from unknown (HELO xxxxx.example.org) (xxx.xxx.xxx.xxx)
by 0 with SMTP; 5 Sep 2018 20:44:43 +0900
Subject: ---email subject---
From: ---email subject---
To: ---email subject---
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-2022-JP
Content-Transfer-Encoding: 7bit
X-Mailer: Bap Version1
---email body---









share|improve this question

























    up vote
    1
    down vote

    favorite












    Some server send email without Date header, and Thunderbird doesn't recognize the date.So, I want to use following settings and add Date header.



    local_header_rewrite_clients = permit_inet_interfaces, ermit_sasl_authenticated
    always_add_missing_headers = yes


    But postfix.org says this may break DKIM signatures.
    Is there a way to add Date headers withoud break DKIM signatures ?
    (My mail server using DKIM.)



    Example of no Date header mail :



    Return-Path: <xxxxxx@example.com>
    X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on example.net
    X-Spam-Level: ***
    X-Spam-Status: No, score=3.7 required=8.0 tests=CONTENT_TYPE_PRESENT,
    FROM_MISSP_EH_MATCH,IP_LINK_PLUS,ISO2022JP_BODY,ISO2022JP_CHARSET,
    MISSING_DATE,MISSING_MID,NORMAL_HTTP_TO_IP,ONEGAI,QENCPTR1,RCVD_IN_DNSWL_NONE,
    RCVD_IN_MSPIKE_H2,RENRAKU,SPF_HELO_PASS,SPF_SOFTFAIL,TO_NO_BRKTS_FROM_MSSP
    autolearn=no autolearn_force=no version=3.4.0
    X-Original-To: xxxxx@example.net
    Delivered-To: xxxxx@example.net
    Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
    (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
    (No client certificate requested)
    by example.net (Postfix) with ESMTPS id D53991D45
    for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
    DKIM-Filter: OpenDKIM Filter v2.11.0 example.net D53991D45
    Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
    by xxxxx.example.org (Postfix) with ESMTP id 77EFF8DC01
    for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
    Received: (qmail 23991 invoked by uid 101); 5 Sep 2018 20:44:43 +0900
    Received: from unknown (HELO xxxxx.example.org) (xxx.xxx.xxx.xxx)
    by 0 with SMTP; 5 Sep 2018 20:44:43 +0900
    Subject: ---email subject---
    From: ---email subject---
    To: ---email subject---
    MIME-Version: 1.0
    Content-Type: text/plain; charset=ISO-2022-JP
    Content-Transfer-Encoding: 7bit
    X-Mailer: Bap Version1
    ---email body---









    share|improve this question























      up vote
      1
      down vote

      favorite









      up vote
      1
      down vote

      favorite











      Some server send email without Date header, and Thunderbird doesn't recognize the date.So, I want to use following settings and add Date header.



      local_header_rewrite_clients = permit_inet_interfaces, ermit_sasl_authenticated
      always_add_missing_headers = yes


      But postfix.org says this may break DKIM signatures.
      Is there a way to add Date headers withoud break DKIM signatures ?
      (My mail server using DKIM.)



      Example of no Date header mail :



      Return-Path: <xxxxxx@example.com>
      X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on example.net
      X-Spam-Level: ***
      X-Spam-Status: No, score=3.7 required=8.0 tests=CONTENT_TYPE_PRESENT,
      FROM_MISSP_EH_MATCH,IP_LINK_PLUS,ISO2022JP_BODY,ISO2022JP_CHARSET,
      MISSING_DATE,MISSING_MID,NORMAL_HTTP_TO_IP,ONEGAI,QENCPTR1,RCVD_IN_DNSWL_NONE,
      RCVD_IN_MSPIKE_H2,RENRAKU,SPF_HELO_PASS,SPF_SOFTFAIL,TO_NO_BRKTS_FROM_MSSP
      autolearn=no autolearn_force=no version=3.4.0
      X-Original-To: xxxxx@example.net
      Delivered-To: xxxxx@example.net
      Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
      (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
      (No client certificate requested)
      by example.net (Postfix) with ESMTPS id D53991D45
      for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
      DKIM-Filter: OpenDKIM Filter v2.11.0 example.net D53991D45
      Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
      by xxxxx.example.org (Postfix) with ESMTP id 77EFF8DC01
      for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
      Received: (qmail 23991 invoked by uid 101); 5 Sep 2018 20:44:43 +0900
      Received: from unknown (HELO xxxxx.example.org) (xxx.xxx.xxx.xxx)
      by 0 with SMTP; 5 Sep 2018 20:44:43 +0900
      Subject: ---email subject---
      From: ---email subject---
      To: ---email subject---
      MIME-Version: 1.0
      Content-Type: text/plain; charset=ISO-2022-JP
      Content-Transfer-Encoding: 7bit
      X-Mailer: Bap Version1
      ---email body---









      share|improve this question













      Some server send email without Date header, and Thunderbird doesn't recognize the date.So, I want to use following settings and add Date header.



      local_header_rewrite_clients = permit_inet_interfaces, ermit_sasl_authenticated
      always_add_missing_headers = yes


      But postfix.org says this may break DKIM signatures.
      Is there a way to add Date headers withoud break DKIM signatures ?
      (My mail server using DKIM.)



      Example of no Date header mail :



      Return-Path: <xxxxxx@example.com>
      X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on example.net
      X-Spam-Level: ***
      X-Spam-Status: No, score=3.7 required=8.0 tests=CONTENT_TYPE_PRESENT,
      FROM_MISSP_EH_MATCH,IP_LINK_PLUS,ISO2022JP_BODY,ISO2022JP_CHARSET,
      MISSING_DATE,MISSING_MID,NORMAL_HTTP_TO_IP,ONEGAI,QENCPTR1,RCVD_IN_DNSWL_NONE,
      RCVD_IN_MSPIKE_H2,RENRAKU,SPF_HELO_PASS,SPF_SOFTFAIL,TO_NO_BRKTS_FROM_MSSP
      autolearn=no autolearn_force=no version=3.4.0
      X-Original-To: xxxxx@example.net
      Delivered-To: xxxxx@example.net
      Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
      (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
      (No client certificate requested)
      by example.net (Postfix) with ESMTPS id D53991D45
      for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
      DKIM-Filter: OpenDKIM Filter v2.11.0 example.net D53991D45
      Received: from xxxxx.example.org (xxxxx.example.org [xxx.xxx.xxx.xxx])
      by xxxxx.example.org (Postfix) with ESMTP id 77EFF8DC01
      for <xxxxx@example.net>; Wed, 5 Sep 2018 20:44:48 +0900 (JST)
      Received: (qmail 23991 invoked by uid 101); 5 Sep 2018 20:44:43 +0900
      Received: from unknown (HELO xxxxx.example.org) (xxx.xxx.xxx.xxx)
      by 0 with SMTP; 5 Sep 2018 20:44:43 +0900
      Subject: ---email subject---
      From: ---email subject---
      To: ---email subject---
      MIME-Version: 1.0
      Content-Type: text/plain; charset=ISO-2022-JP
      Content-Transfer-Encoding: 7bit
      X-Mailer: Bap Version1
      ---email body---






      email postfix opendkim






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Sep 8 at 6:09









      takumi9942

      82




      82




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          0
          down vote



          accepted










          It doesn't really matter that your server uses DKIM. A DKIM signature is something added by the sender, and making one requires the sender's private key.



          As a part of DKIM signing, the sender's mail server takes some headers, typically including the Date header, concatenates these, and cryptographically signs the result. If you change any of those headers, or add one that wasn't there, you change the concatenated string and the signature will be invalid.



          The mail you show is not DKIM signed.



          The short version is: You can't do what you ask about.






          share|improve this answer




















          • Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
            – takumi9942
            Sep 8 at 9:41










          • yes, thunderbird should be making the date header.
            – Jasen
            Sep 11 at 8:05










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f467665%2fhow-to-add-date-header-to-received-emails-without-break-dkim-signatures%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          0
          down vote



          accepted










          It doesn't really matter that your server uses DKIM. A DKIM signature is something added by the sender, and making one requires the sender's private key.



          As a part of DKIM signing, the sender's mail server takes some headers, typically including the Date header, concatenates these, and cryptographically signs the result. If you change any of those headers, or add one that wasn't there, you change the concatenated string and the signature will be invalid.



          The mail you show is not DKIM signed.



          The short version is: You can't do what you ask about.






          share|improve this answer




















          • Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
            – takumi9942
            Sep 8 at 9:41










          • yes, thunderbird should be making the date header.
            – Jasen
            Sep 11 at 8:05














          up vote
          0
          down vote



          accepted










          It doesn't really matter that your server uses DKIM. A DKIM signature is something added by the sender, and making one requires the sender's private key.



          As a part of DKIM signing, the sender's mail server takes some headers, typically including the Date header, concatenates these, and cryptographically signs the result. If you change any of those headers, or add one that wasn't there, you change the concatenated string and the signature will be invalid.



          The mail you show is not DKIM signed.



          The short version is: You can't do what you ask about.






          share|improve this answer




















          • Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
            – takumi9942
            Sep 8 at 9:41










          • yes, thunderbird should be making the date header.
            – Jasen
            Sep 11 at 8:05












          up vote
          0
          down vote



          accepted







          up vote
          0
          down vote



          accepted






          It doesn't really matter that your server uses DKIM. A DKIM signature is something added by the sender, and making one requires the sender's private key.



          As a part of DKIM signing, the sender's mail server takes some headers, typically including the Date header, concatenates these, and cryptographically signs the result. If you change any of those headers, or add one that wasn't there, you change the concatenated string and the signature will be invalid.



          The mail you show is not DKIM signed.



          The short version is: You can't do what you ask about.






          share|improve this answer












          It doesn't really matter that your server uses DKIM. A DKIM signature is something added by the sender, and making one requires the sender's private key.



          As a part of DKIM signing, the sender's mail server takes some headers, typically including the Date header, concatenates these, and cryptographically signs the result. If you change any of those headers, or add one that wasn't there, you change the concatenated string and the signature will be invalid.



          The mail you show is not DKIM signed.



          The short version is: You can't do what you ask about.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Sep 8 at 7:57









          Henrik

          3,3001418




          3,3001418











          • Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
            – takumi9942
            Sep 8 at 9:41










          • yes, thunderbird should be making the date header.
            – Jasen
            Sep 11 at 8:05
















          • Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
            – takumi9942
            Sep 8 at 9:41










          • yes, thunderbird should be making the date header.
            – Jasen
            Sep 11 at 8:05















          Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
          – takumi9942
          Sep 8 at 9:41




          Thank you for your answer! Hmmm, I'll configure Thunderbird instead.
          – takumi9942
          Sep 8 at 9:41












          yes, thunderbird should be making the date header.
          – Jasen
          Sep 11 at 8:05




          yes, thunderbird should be making the date header.
          – Jasen
          Sep 11 at 8:05

















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f467665%2fhow-to-add-date-header-to-received-emails-without-break-dkim-signatures%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          How to check contact read email or not when send email to Individual?

          Displaying single band from multi-band raster using QGIS

          How many registers does an x86_64 CPU actually have?