[Spambayes] hammie appending headers

Toby Dickenson tdickenson@devmail.geminidataloggers.co.uk
Fri Nov 1 16:42:49 2002


Hammie currently appends the X-Hammie-Disposition header. Any existing 
X-Hammie-Disposition headers are left intact. I think we should be removing 
them, to prevent spammers (or testers ;-) adding headers that confuse 
downstream filters.


Index: hammie.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/hammie.py,v
retrieving revision 1.33
diff -c -4 -r1.33 hammie.py
*** hammie.py   27 Oct 2002 22:56:15 -0000      1.33
--- hammie.py   1 Nov 2002 16:39:25 -0000
***************
*** 266,273 ****
--- 266,274 ----
          else:
              disp = "Unsure"
          disp += "; %.2f" % prob
          disp += "; " + self.formatclues(clues)
+         del msg[header]
          msg.add_header(header, disp)
          return msg.as_string(unixfrom=(msg.get_unixfrom() is not None))

      def train(self, msg, is_spam):