views:

81

answers:

2

I have a web app that only registered users can use, therefore I should have a valid e-mail address for the creator of the message.

One part of this web app will allow a user to create and send a e-mail message to an e-mail address that the user enters. My web server will be creating and sending the e-mail, however if there is a delivery problem with the e-mail I would like the bounce to go to the user's e-mail address instead of the server. This will allow the user to know that there was a problem delivering the message and they can take the appropriate action.

Would setting the "return-path" attribute to the user's e-mail address handle this?

A: 

You could set up windows service on your server to periodically check BadMail folder and parse the bounced messages and resend them to the original sender. This solution would work in most cases. I don't think return-path would help in every instance (if it would at all), because different mail servers handle bounces differently.

Ilya Volodin
+1  A: 

As RFC2821 says:

The primary purpose of the Return-path is to designate the address to which messages indicating non-delivery or other mail system failures are to be sent. For this to be unambiguous, exactly one return path SHOULD be present when the message is delivered.

So yes, all standard compliant servers should account for the Return-path you set.

Quassnoi