Re: postfix + .forward and forcing the From address

2011-06-07 Thread /dev/rob0
On Tue, Jun 07, 2011 at 10:38:44AM -0400, Michael Way wrote: > > So why not just take MSexChange out of the picture? Set up direct > > authentication to gmail. SASL_README.html#client_sasl just as you > > did, setting it up to authenticate to MSexChange. > > > > Have your .forward invoke sendmail(1

Re: postfix + .forward and forcing the From address

2011-06-07 Thread Michael Way
>> I can send emails via this system just fine using mutt or >> whatever command line mail I like, BUT I also use fetchmail to >> get email from our IMAP server. I then use a .forward file to >> keep a local copy AND send a copy to gmail as a backup. > > Ugly and complex, but, oh well. Until they

Re: postfix + .forward and forcing the From address

2011-06-07 Thread /dev/rob0
On Mon, Jun 06, 2011 at 02:46:57PM -0400, Michael Way wrote: > I have a setup where I use postfix to connect to my work smtpd > exchange server via TLS encryption and normal login authentication. > This smtpd server also requires that the "From" address in the > email header is from the same use

Re: postfix + .forward and forcing the From address

2011-06-07 Thread Michael Way
Sorry I didn't read your e-mail before hitting the send button. You are correct about it going into a loop, and the only way to stop it is to remove the rules in main.cf and then postfix reload. I'm wondering why you call it "unsafe"? Is this because it will fill up your log files if you don't rea

Re: postfix + .forward and forcing the From address

2011-06-07 Thread Michael Way
It seems my smtpd exchange server is still unhappy even with this last solution. I'm getting: "550 5.7.1 Client does not have permissions to send as this sender (in reply to end of DATA command))" This follows your suggestion to put this in /etc/postfix/sender_canonical: /./ user1.h...@work.com

Re: postfix + .forward and forcing the From address

2011-06-07 Thread Wietse Venema
Wietse Venema: > Wietse Venema: > > Michael Way: > > > it would be?: > > > if !/[[:<:]]user1\.home@work\.com$/ > > > /./ user1\.home@work\.com Don't use \ in the replacement text! > > > endif > > > > Looks like you want to replace all senders in outbound email by your own > > email address

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Wietse Venema
Wietse Venema: > Michael Way: > > it would be?: > > if !/[[:<:]]user1\.home@work\.com$/ > > /./ user1\.home@work\.com Don't use \ in the replacement text! > > endif > > Looks like you want to replace all senders in outbound email by your own > email address. In that case it is sufficient

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Wietse Venema
Michael Way: > it would be?: > if !/[[:<:]]user1\.home@work\.com$/ > /./ user1\.home@work\.com Don't use \ in the replacement text! > endif Looks like you want to replace all senders in outbound email by your own email address. In that case it is sufficient to do this: /etc/postfix/ma

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Michael Way
Unfortunately it seems that Wietse's suggestion was not sufficient for the smtp server. I now get a different (but similar) error: Jun 6 17:14:53 localhostname postfix/smtp[76133]: D7ED9A18A05: to=, relay=smtp.work.com[192.168.1.89]:587, delay=1.7, delays=0/0/1.4/0.35, dsn=5.7.1, status=bounced (h

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Wietse Venema
Wietse Venema: > Wietse: > > Why do you believe that it complains about the "From" address in > > the email header, instead of the SMTP "MAIL FROM" address? > > Michael Way: > > Sorry Wietse, my bad you are correct. It is the MAIL FROM: I > > should have included the full line: 550 5.7.1 Client

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Wietse Venema
Wietse: > Why do you believe that it complains about the "From" address in > the email header, instead of the SMTP "MAIL FROM" address? Michael Way: > Sorry Wietse, my bad you are correct. It is the MAIL FROM: I > should have included the full line: 550 5.7.1 Client does not > have permissions t

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Michael Way
Sorry Wietse, my bad you are correct. It is the MAIL FROM: I should have included the full line: 550 5.7.1 Client does not have permissions to send as this sender (in reply to MAIL FROM command)) I'm not sure of the difference honestly, or rather how I would filter this and replace it. --mike O

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Michael Way
My work is a HUGE institution and there are just a few of us old unix dudes around who use command line (and cron) for such things so they will not allow any changes as you suggest. Otherwise, I agree that it IS an ugly/wrong solution, but the only one at my disposal... --mike On Mon, Jun 6, 201

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Wietse Venema
Michael Way: > Hi All, > > I have a setup where I use postfix to connect to my work smtpd > exchange server via TLS encryption > and normal login authentication. This smtpd server also requires that > the "From" address in the email header > is from the same user that authenticates, otherwise I ge

Re: postfix + .forward and forcing the From address

2011-06-06 Thread Victor Duchovni
On Mon, Jun 06, 2011 at 02:46:57PM -0400, Michael Way wrote: > I have a setup where I use postfix to connect to my work smtpd > exchange server via TLS encryption > and normal login authentication. This smtpd server also requires that > the "From" address in the email header > is from the same use

postfix + .forward and forcing the From address

2011-06-06 Thread Michael Way
Hi All, I have a setup where I use postfix to connect to my work smtpd exchange server via TLS encryption and normal login authentication. This smtpd server also requires that the "From" address in the email header is from the same user that authenticates, otherwise I get a: "Client does not have