Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Reading an Outlook PST FIle

by BaldPenguin (Friar)
on Jun 13, 2005 at 05:39 UTC ( #466065=perlquestion: print w/ replies, xml ) Need Help??
BaldPenguin has asked for the wisdom of the Perl Monks concerning the following question:

My Fellow Monks:

Here is my quandry. I use Spamassassin to filter the mail on my mail server, a mail server that hosts more that just my mail. It works quite well. But those wiley spammers are good at hiding their spam from the likes of SA. I want to use the sa-learn to start teaching my bayesian filter what gets missed. Using outlook, I can automatically mark items as junk, which does it's own learning in outlook. Wanting to share this education with everyone else using the mail server, I would like to create a PERL script that reads my 'Junk Mail' folder in the Outlook PST file and runs those mails against the sa-learn binary.

Has anyone done that before, a quick search on CPAN didn't find anything, likewise my searching skills found minimal solutions here within the monestary.

Any pointers?

Don
WHITEPAGES.COM | INC

Comment on Reading an Outlook PST FIle
Re: Reading an Outlook PST FIle
by tachyon (Chancellor) on Jun 13, 2005 at 06:56 UTC

    I would suggest this ready rolled, free, with source code, (non Perl) solution: Personal Message Store (PST) Export Utility 1.0. You can export a PST of just the junk mail folder from outlook with File|Export|etc beforehand to separate out the junk.

    This gives you the original full headers (probably), newline separated ie in standard *nix format.

    cheers

    tachyon

Re: Reading an Outlook PST FIle
by monarch (Priest) on Jun 13, 2005 at 07:04 UTC

    Just looking on the 'net I found this link which basically says that the .pst file format is protected, and accessing the files through OLE might be the way to go (with a running instance of Microsoft Outlook).

    A perl FAQ (How do I create a new folder in Outlook?) may be a stepping stone..

      accessing the files through OLE might be the way to go
      This question just came up again on the Chatterbox, and looking through CPAN I found a module (by Barbie): Mail::Outlook, which apparently is built on top of Win32::OLE. So you no longer have to start from zero.
Re: Reading an Outlook PST FIle
by rob_au (Abbot) on Jun 13, 2005 at 10:08 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://466065]
Approved by monkfan
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (14)
As of 2014-12-18 15:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (56 votes), past polls