[Tutor] Working with Email question
Joel Ricker
joejava@dragoncat.net
Sat, 23 Feb 2002 15:47:40 -0500
This is a multi-part message in MIME format.
------=_NextPart_000_006F_01C1BC81.6C982D40
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Wow, things have changed since I've last worked with Python which was in =
1.5(.2?).
As a warmup excercise to get back into the swing of things, I want to =
write a spam filter. I'm pretty liberal with my e-mail address, which =
is great because people can find me but the drawback is of course that =
so can all the spammers in the world :(
I've got a little script going that does a good job as connecting to a =
POP3 server and query for messages and the sort. What I need now is the =
ability to dissect those messages for spam. Digging around I found the =
libraries for working with MIME data that seems to be related to working =
with email but they seem to be more for working with MIME files =
(building up files rather that analyzing already created emails). Is =
there a library already for working with messages? Something like given =
the text of a message, you can easily extract the body, to: lines, etc, =
or am I'm going to have to write one myself? Just wanted to check =
before I re-invent anything.
Thanks
Joel
=20
------=_NextPart_000_006F_01C1BC81.6C982D40
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-1" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.3314.2100" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Wow, things have changed since I've =
last worked=20
with Python which was in 1.5(.2?).</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=3DArial size=3D2>As a warmup excercise to get back into =
the swing of=20
things, I want to write a spam filter. I'm pretty liberal with my =
e-mail=20
address, which is great because people can find me but the drawback is =
of course=20
that so can all the spammers in the world :(</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=3DArial size=3D2>I've got a little script going that =
does a good job=20
as connecting to a POP3 server and query for messages and the =
sort. What I=20
need now is the ability to dissect those messages for spam. =
Digging around=20
I found the libraries for working with MIME data that seems to be =
related to=20
working with email but they seem to be more for working with MIME files=20
(building up files rather that analyzing already created emails). =
Is there=20
a library already for working with messages? Something like =
given the=20
text of a message, you can easily extract the body, to: lines, etc, =
or am=20
I'm going to have to write one myself? Just wanted to check =
before I=20
re-invent anything.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>Thanks</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Joel</FONT></DIV>
<DIV> </DIV></BODY></HTML>
------=_NextPart_000_006F_01C1BC81.6C982D40--