[Spambayes-checkins] spambayes pop3proxy.py,1.51,1.52

Tim Stone timstone4 at users.sourceforge.net
Sat Feb 8 18:25:48 EST 2003


Update of /cvsroot/spambayes/spambayes
In directory sc8-pr-cvs1:/tmp/cvs-serv30980

Modified Files:
	pop3proxy.py 
Log Message:
Added code to put classification into To: header to
accomodate email clients (e.g. Outlook Express) that cannot test for
presence/value of arbitrary headers.  These clients can test for the
classification in the recipient list.  The classification is not a valid email
address, so spammers will have to be a bit clever to spoof this,
though it is certainly possible.  A spoof-proof scheme for these (dumb)
mail clients may not be possible.

Index: pop3proxy.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/pop3proxy.py,v
retrieving revision 1.51
retrieving revision 1.52
diff -C2 -d -r1.51 -r1.52
*** pop3proxy.py	3 Feb 2003 07:53:12 -0000	1.51
--- pop3proxy.py	9 Feb 2003 02:25:45 -0000	1.52
***************
*** 499,502 ****
--- 499,509 ----
              headers, body = re.split(r'\n\r?\n', messageText, 1)
              headers = headers + "\n" + header + "\r\n"
+             
+             if options.pop3proxy_notate_to:
+                 # add 'spam' as recip
+                 tore = re.compile("^To: ", re.IGNORECASE | re.MULTILINE)
+                 headers = re.sub(tore,"To: %s," % (disposition),
+                      headers)
+                 
              messageText = headers + body
  





More information about the Spambayes-checkins mailing list