Re: i want to hide return path...
On Tue, 2004-05-04 at 14:45, Marcin wrote:
> I am using debian postfix. When a mail from the PHP (under apache) the mail header contain:
> Return-Path: <email@example.com>
> I want to hide only this ONE user.
> It is possible ?
> header_checks with:
> /^Return-Path: <www/ IGNORE
> /^Return-Path: <www-data/ IGNORE
> /^Return-Path: <firstname.lastname@example.org>/ IGNORE
> is not working :(
> why ?
> and how to ignore it ?
It can't ignore something that isn't there.... Return-Path is not an
header used by the MTA (like Postfix), but is a header added by the MDA
when the mail is delivered. It uses the value of the enveloppe from
address (MAIL FROM in the smtp session). Because it is not in a header,
you can't use header_checks for it.
All you can do with Postfix (AFAIK) is to reject mail from this sender.
You can rewrite the entire domain, using the Address Masquerading
functionality in Postfix.
> The best solution will be replacing
> with for example
Add -email@example.com to the sendmail_path in php.ini or use:
mail($to,$subject,$message,$headers,'-firstname.lastname@example.org'); to send
mail in the php scripts.