[Mimedefang] Apostrophes escaped in "To:" address

David F. Skoll dfs at roaringpenguin.com
Thu Oct 9 16:29:01 EDT 2003


On Thu, 9 Oct 2003, Patrick Morris wrote:

> Weird -- I see the message get passed through a couple servers before it
> gets to one of my MD+SpamAssassin machines, and up until that point the
> address is intact.  When that machine then relays to the recipient's
> server, the address is mangled.

You are right; there is a bug in MIMEDefang.

I guess there will be a 2.39 release fairly soon. :-(

Here's a patch against 2.38.  Apply this patch, re-run ./configure and make
and make install.

Regards,

David.

--- mimedefang.pl.in-2.38	Thu Oct  9 16:27:52 2003
+++ mimedefang.pl.in	Thu Oct  9 16:26:01 2003
@@ -15,7 +15,7 @@
 # This program was derived from the sample program "mimeexplode"
 # in the MIME-Tools Perl module distribution.
 #
-# $Id: mimedefang.pl.in,v 1.398 2003/10/08 12:15:30 dfs Exp $
+# $Id: mimedefang.pl.in,v 1.399 2003/10/09 20:26:01 dfs Exp $
 #***********************************************************************

 # MIME-Tools requires this?
@@ -4479,6 +4479,10 @@
 	} elsif ($cmd eq "R") {
 	    my($recip, $rcpt_mailer, $rcpt_host, $rcpt_addr);
 	    ($recip, $rcpt_mailer, $rcpt_host, $rcpt_addr) = split(' ', $rawarg);
+	    $recip = percent_decode($recip);
+	    $rcpt_mailer = percent_decode($rcpt_mailer);
+	    $rcpt_host = percent_decode($rcpt_host);
+	    $rcpt_addr = percent_decode($rcpt_addr);
 	    $rcpt_mailer = "?" unless (defined($rcpt_mailer) and ($rcpt_mailer ne ""));
 	    $rcpt_host = "?" unless (defined($rcpt_host) and ($rcpt_host ne ""));
 	    $rcpt_addr = "?" unless (defined($rcpt_addr) and ($rcpt_addr ne ""));



More information about the MIMEDefang mailing list