[NTLUG:Discuss] changing FROM or REPYTO in mail

David Stanaway david at stanaway.net
Tue Sep 3 13:01:59 CDT 2002


On Tue, 2002-09-03 at 12:20, Fred James wrote:
> just trying to get replies to me rather than to the 
> server I send the email from - no I don't want to alias all root mail to 
> me, just certain ones.
> 
> If someone could refresh my memory, I should be greatly appreciative.


dstanawa at ciderbox:~$ cat <<EOF | /usr/sbin/sendmail
> To: d at mena.us
> From: david at stanaway.net
> Subject: Mail from david
> X-Mailer: $(cat --version|head -1)
>
> Message starts here after a totaly blank line (\n\n which gets
translated to \r\n\r\n).
> EOF


Yields:

Return-Path: <dstanawa at stanaway.net>
Delivered-To: david at stanaway.net
Received: by ciderbox.stanaway.net (Postfix, from userid 1000) id
        C56F592ABD; Tue,  3 Sep 2002 12:58:02 -0500 (CDT)
To: d at mena.us
From: david at stanaway.net
Subject: Mail from david
X-Mailer: cat (textutils) 2.1
Message-Id: <20020903175802.C56F592ABD at ciderbox.stanaway.net>
Date: Tue,  3 Sep 2002 12:58:02 -0500 (CDT)
X-Evolution-Source: mbox:/var/spool/mail/dstanawa
Mime-Version: 1.0

Message starts here after a totaly blank line (\n\n which gets
translated to \r\n\r\n).


If you wanted to change this for all mails, your MTA can be set to do
so: eg: in postfix:
# SYNOPSIS
#        postmap /etc/postfix/canonical
#
# DESCRIPTION
#        The  optional canonical table specifies an address mapping
#        for local and non-local addresses. The mapping is used  by
#        the  cleanup(8) daemon.  The address mapping is recursive.


-- 
David Stanaway




More information about the Discuss mailing list