[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kdepim-users
Subject:    Re: [kdepim-users] Re: Two newbee Kmail questions:
From:       jedd <jedd () progsoc ! org>
Date:       2004-03-28 3:28:15
Message-ID: 200403281328.15794.jedd () progsoc ! org
[Download RAW message or body]

On Sun March 28 2004 11:41 am, Renaud (Ron) OLGIATI wrote:
 ] My problem remains: 
 ] I have several hundred messages, with several hundred attached files; is there 
 ] a way to recover all of those without going through the routine of opening 
 ] each message, and individually saving each attachment ?

 No, not through kmail at least.

 ] Where, oh where are those attachment files hidden ?

 Where are the words from this email 'hidden'?  The answer's the same.
 In the text (yes, text) files that live in and under your ~/Mail/ directory.

 I had a quick play with munpack, but that doesn't seem to want to scan
 through an entire file - it stops after extracting the first attachment.
 To backtrack a smidge, mime encoding is used to convert binary attachments
 to ascii-safe looks-like-text attachments.  Crank up a text editor and look
 at your ~/Mail/inbox file and you'll see what I mean.  You'll see justified
 paragraphs of non-english text.

 So the theory is that you could use a mime-decoder to extract the
 attachments in each of the files in your Mail directory.

 It should be relatively trivial to wrap a script around this process.

 You'd need to search for 'Content-Transfer-Encoding: base64' and
 then extract from a few lines before that down to a few lines after
 the next blank line, pipe that through munpack, and store the resultant
 file somewhere it won't be overwritten by a file with the same name.

 With a little wangling you could create a sub-directory structure that
 matches mail folder, and within that directories named after the time
 and date of the message.

 Cheers,
 Jedd.
_______________________________________________
KDE PIM users mailing list
kdepim-users@kde.org
https://mail.kde.org/mailman/listinfo/kdepim-users
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic