Hi everyone, I am trying to get message bounces/delays piped into a script while keeping the user-visible From: header intact. To do this, I have asked the senders to relay through me and include a header of the form X-bounces-to: [email protected]. In the postfix relay host I added main.cf: header_checks = regexp:/etc/postfix/header_checks header_checks: /^Return-Path: (.*)/ REPLACE X-Original-Return-Path: $1 /^X-bounces-to: (.*)/ REPLACE Return-Path: $1 The log does say postfix/cleanup: replace: header X-bounces-to: [email protected] somehost[1.2.3.4]; from=< [email protected]> to=<[email protected]> proto=SMTP: Return-Path: [email protected] which sounds a bit odd - is this a concatenation of several informations from the message headers or some error on my part?
The messages do go out with the wrong return-path - the address used in the MAIL FROM: line, in this case [email protected]. My question would be: does cleanup(8) do another replace of the headers just before the message leaves the system? If so, can it be disabled?
