To header of forwarded mail

Discussion in 'ISPConfig 3 Priority Support' started by francoisPE, May 25, 2024.

  1. francoisPE

    francoisPE Active Member HowtoForge Supporter

    Hello,
    I face a change in postfix behaviour since few days.
    I setup a mail forward in ispconfig
    - destination for user is : [email protected]
    - forward to : [email protected]
    upload_2024-5-25_9-4-23.png

    During months, in the header of the mail received in mailbox [email protected], the tag 'To' was: [email protected]
    but now, when I look at the header I see : To [email protected]

    It is very penalising because mailis are sorted based on mail+code value... So that my architecture is broken...

    Where is the setup to have postfix writing To [email protected] instead of [email protected] ?
    I found for "from" address but not "To"

    thank you
    FrancoisPE
    Code:
    Return-Path: <[email protected]>
    Received: from mail1.dom.fr
            by mail1.dom.fr with LMTP
            id 8H9eBLOVxxxA4t0oRA
            (envelope-from <[email protected]>); Tue, 21 May 2024 14:38:11 +0200
    Received: from dom.com (h2web170.xx.com [IPv6:2001:16...ff:fe76:57f7])
            (Authenticated sender: [email protected])
            by mail1.dom.fr (Postfix) with ESMTPSA id 6863xxx7463
            for <[email protected]>; Tue, 21 May 2024 14:38:10 +0200 (CEST)
    DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dom.com;
            s=dom; t=17190; h=from:from:reply-to:reply-to:subject:subject:date:date:
             message-id:message-id:to:to:cc:mime-version:mime-version:
             content-type:content-type:  content-transfer-encoding:content-transfer-encoding;
            bh=PZbuame+dPjpJalpUvyYNIxhWJY=;
            b=WlMWOqGjQfMhljl/dkigDAJhNCEFmuDdW
            lOZ9cu9fsX9602P/xk42ZVI7MSDC7EWWKRFe/MxA9fkIr55gMVeU/tW3N1X2dw==
    Authentication-Results: mail1.dom.fr;
            auth=pass [email protected] [email protected]
    Date: Tue, 21 May 2024 12:38:09 +0000
    To: [email protected]
    From: [email protected]
    Reply-To: "\"[email protected]\"" <[email protected]>
    Subject: Nouveau Message De TOM- Quelle est votre question?
    Message-ID: <[email protected]>
    
     
    Last edited: May 29, 2024
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I do not use plus addressing on my systems, so I can't say much. As it worked before, do you remember what you changed in the config that might have made it stop working?
     
  3. pyte

    pyte Well-Known Member HowtoForge Supporter

    The postfix documentation regarding plus adressing can be found here:
    https://www.postfix.org/postconf.5.html#recipient_delimiter
    and what you are most likly looking for here:
    https://www.postfix.org/postconf.5.html#propagate_unmatched_extensions

    However i did not really understand the description of your porblem above. If you want mails that are outgoing or internally forwarded to use the plus addressing you don't want to set "propagate_unmatched_extensions" as this will remove the adressing because external mailservers are not aware of "[email protected]" as a valid recipient.
     
  4. francoisPE

    francoisPE Active Member HowtoForge Supporter

    Hello,
    Thank you for your advice.
    Probably my english is quite short because what you mention is not my issue

    The problem is that there is no more rewrite

    I have this header. Let's call it current_header
    Code:
    Return-Path: <[email protected]>
    Received: from mail1.dom.fr
            by mail1.dom.fr with LMTP
            id 8H9eBLOVxxxA4t0oRA
            (envelope-from <[email protected]>); Tue, 21 May 2024 14:38:11 +0200
    ...
    Date: Tue, 21 May 2024 12:38:09 +0000
    To: [email protected]
    
    I would like this header. Let's call it header_of_past_week
    Code:
    Return-Path: <[email protected]>
    Received: from mail1.dom.fr
            by mail1.dom.fr with LMTP
            id 8H9eBLOVxxxA4t0oRA
            (envelope-from <[email protected]>); Tue, 21 May 2024 14:38:11 +0200
    ...
    Date: Tue, 21 May 2024 12:38:09 +0000
    To: [email protected]
    
    The behavior changed past week.

    Past week, in the mail box, using ispconfig email forward, I had the header : header_of_past_week
    Now, I have current_header

    The problem is I need To: mail+code@dom.com in my header.
    I changed absolutely nothing except apt upgrade (cron)

    What I suspect is a change of behavior of postfix.
    Would you please tell me how I can force rewrite "To:" ?

    thank you
     
    Last edited: May 29, 2024
  5. francoisPE

    francoisPE Active Member HowtoForge Supporter

    No idea ?
     
  6. pyte

    pyte Well-Known Member HowtoForge Supporter

    Can you post a real header from these situations?

    This "To"-Field is set by the sending client. Postfix should not modify it, expect you have some rules doing that.
     

Share This Page