Scrip to modify a ticket's text content?

We are using Exchange 2007 and tickets get created just fine by using
Exchange’s smarthost feature.
The issue is that we have set some of that disclaimers that get added to
every email, and sadly 2007 doesn’t seem to have an option to remove the
disclaimer as an exception for an specific recipient, so i am guessing i may
be able to do it with a scrip.

The content of the disclaimer is (starts below this line):

USO DEL CORREO ELECTRONICO DE SEGUROS CATATUMBO, C.A. HACIA INTERNET: Este
mensaje y cualquier anexo pueden ser confidenciales o tener privilegios
legales. Si usted recibe este mensaje por error o no es su destinatario,
deberá notificar a webmaster@seguroscatatumbo.com y eliminar el mensaje y
cualquier anexo o copias. Está prohibida su distribución, divulgación o
utilización de cualquier información contenida en el mismo.

SEGUROS CATATUMBO, C.A.: This message may contain information solely of the
interest of SEGUROS CATATUMBO, C.A. or its businesses. Copying,
distribution, disclosure or any use of the information contained in this
message is permitted only to authorized parties. If you have received this
e-mail by error, please notify webmaster@seguroscatatumbo.com.
Por favor, no imprima este e-mail a menos que realmente necesite hacerlo.
Please, don’t print this e-mail unless you really need to.

As you see, it’s kind of long, so i don’t have a clue on how to do this. My
guess is to look for the ________________________________ line and delete
everything from there. This would also need to work on ticket replies by
email.

I can code a little, but don’t know perl enough to do this by myself, but
with a working example i could see myself adapting it. I have seen the
RT::Ticket but i don’t see anything regarding the ticket content.

View this message in context: http://requesttracker.8502.n7.nabble.com/Scrip-to-modify-a-ticket-s-text-content-tp58650.html

We are using Exchange 2007 and tickets get created just fine by using
Exchange’s smarthost feature.
The issue is that we have set some of that disclaimers that get added to
every email, and sadly 2007 doesn’t seem to have an option to remove the
disclaimer as an exception for an specific recipient, so i am guessing i may
be able to do it with a scrip.

Scrips run after the transaction is recorded.

You’d be better served stripping this before the mail is recorded,
before it got to rt-mailgate.

While you could do it in the mail gateway of RT (and we’ve refactored
that heavily and backported some of those changes as a plugin), these
are changes you want to do before things are saved to the database,
not after.

-kevin

I just found a tool called MIMEDefang http://www.mimedefang.org/ that may
help me to edit mail content. I will see that i can do with it.

View this message in context: http://requesttracker.8502.n7.nabble.com/Scrip-to-modify-a-ticket-s-text-content-tp58650p58731.html