procmail
[Top] [All Lists]

Re: procmail-formail-sendmail not spoofing From addr

2007-05-20 02:06:41
On Sat, May 19, 2007 at 10:25:03PM -0500, 
matt(_at_)c3p0(_dot_)reverse(_dot_)net wrote:
I wrote the following code for my .procmailrc file.  It mainly works fine,
fowarding the body of the received "test(_at_)mydomain" msg to the new address
after replacing the subject, but it will not spoof the "From:" or
"Reply-To:" address.  Instead, it always shows as being from my main
account.  The email is fwd'ed going to a handheld device that has a rather
cumbersome keyboard and extremely limited email handling.

What am I doing wrong?

I don't have time to look closely right now, but I would say you need
the -f option to $SENDMAIL at the end and a server that recognizes
invocations of the -f option for it to work as desired.


# still not spoofing FROM addr
:0:
| (formail -rk -p "" \
      -i "Reply-To: test(_at_)mydomain(_dot_)com" \
      -i "From: test(_at_)mydomain(_dot_)com" \
      -I "To: mydevice(_at_)otherdomain(_dot_)com" \
      -I "Subject: test" ;\
      echo "." \
 )| $SENDMAIL -t -oi

}

   | "$SENDMAIL" $SENDMAILFLAGS -f

Again, I did not have time to look at the code you offered or test this.
Sorry.  I do use something like that above suggestion myself, though.

Dallman

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail