[rt-users] How to get RT to use Reply-To for returned emails
Gene LeDuc
gleduc at mail.sdsu.edu
Mon Sep 8 14:45:16 EDT 2008
Hi John,
It's possible to access the headers of the original e-mail in an on-create
scrip and then change the requestor to whatever is found in the reply-to
header. You would have to create a new user for the reply-to address if
that user does not already exist. You might end up with a bunch of bogus
users unless you also delete the original requestor/user after changing to
the new one because RT creates the user before the on-create trigger
happens (you might have to shred it, I'm not sure). And if there is no
reply-to header then obviously you wouldn't change the requestor. Doing
this might present some surprise gotchas as well, so be prepared.
Another thought is to change the requestor's "userid" to the reply-to
address. This seems like it would be cleaner, but I've never done it and
don't know whether it is feasible. If the user already exists, then you
change the requestor to that user. You still need to delete any bogus user
that gets created.
I think this will get you the Reply-To header:
my @ReplyTo =
$self->TicketObj->Transactions->First->Attachments->First->GetHeader('To');
but you might be able to simplify it to:
my @ReplyTo =
$self->TransactionObj->Attachments->First->GetHeader('Reply-To');
Give it a shot and have fun!
Regards,
Gene
At 11:27 AM 9/8/2008, John BORIS wrote:
>In my setup my users are sending emails to RT from a machine where their
>email address isn't valid. It is hard to explain. The corporate email
>address for my users is not the same as their login and email address on
>the server where the email is originating. We use Mutt as the client.
>The emails are sent from inside a program the user is running.
>It is like this
>User's login to server: joed
>email address on that server: joed at localserver.edu
>Corporate email is joed at corporateemail.org
>REPLY-TO joed at corporateemail.org
>
>The user sends the email to RT from the application on the server. Mutt
>sends the email to RT and RT takes it and processes it. It correctly
>adds the ticket to the proper Queue but it then sends the reply back to
>the From address not the REPLY-TO address. This reply is then refused by
>the local server.
>
>Is there a way to have RT use the REPLY-TO field for replies instead of
>the From field? Or is the REPLY-TO field not set in all email clients?
>
>
>I hope I gave enough info.
>
>TIA
>
>
>John J. Boris, Sr.
>JEN-A-SyS Administrator
>Archdiocese of Philadelphia
>"Remember! That light at the end of the tunnel
>Just might be the headlight of an oncoming train!"
>_______________________________________________
>http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
>
>Community help: http://wiki.bestpractical.com
>Commercial support: sales at bestpractical.com
>
>
>Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
>Buy a copy at http://rtbook.bestpractical.com
--
Gene LeDuc, GSEC
Security Analyst
San Diego State University
More information about the rt-users
mailing list