* Re: Extracting Binaries from MIME-Encoded messages
@ Martin McCormick
0 siblings, 0 replies; 9+ messages in thread
From: Martin McCormick @ UTC (permalink / raw)
To: Linux for blind general discussion
My thanks to all the rest who had suggestions. I am more
interested in a faster way to extract the attachments than I am in
trying to use what data are there as I read the mail. So anything
that ends up with 1 or more extracted files is fine with me. It is
basic laziness on my part.
Martin McCormick
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Extracting Binaries from MIME-Encoded messages
@ Martin McCormick
0 siblings, 0 replies; 9+ messages in thread
From: Martin McCormick @ UTC (permalink / raw)
To: Linux for blind general discussion
Since several of you pointed me in the right direction, I have
found that uudeview is one of the ports in the FreeBSD distribution
and, as previously stated, mpack and munpack are found in Debian.
Those two utilities appear to be installed when you build a normal
installation of Debian. The uudeview utility is part of the FreeBSD
ports collection which is similar to all the Redhat RPM's and the
Debian .deb packages.
I installed the uudeview package because I use FreeBSD at work
and hit it with a message somebody had sent that had about 4 pdf
documents in it. It extracted them all in about half a second. Sure
beats manually looking for them. It also gave them their correct file
names so I didn't even have to think about that.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Extracting Binaries from MIME-Encoded messages
@ Martin McCormick
0 siblings, 0 replies; 9+ messages in thread
From: Martin McCormick @ UTC (permalink / raw)
To: Linux for blind general discussion
Kirk Reiser writes:
>Yes, the mpack and munpack utilities do it very nicely. I'm not sure
>where to tell you to look though because I use debian and they have a
>package called mpack which contains the utilities.
Thank you. I use Debian also so I'll just take care of that.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Extracting Binaries from MIME-Encoded messages
@ Karl Dahlke
0 siblings, 0 replies; 9+ messages in thread
From: Karl Dahlke @ UTC (permalink / raw)
To: blinux-list
My edbrowse program handles this pretty well.
http://www.eklhad.net/linux/app
^ permalink raw reply [flat|nested] 9+ messages in thread
* Extracting Binaries from MIME-Encoded messages
@ Martin McCormick
` Kirk Reiser
` (2 more replies)
0 siblings, 3 replies; 9+ messages in thread
From: Martin McCormick @ UTC (permalink / raw)
To: Linux for blind general discussion
I use nmh for reading Email. This user agent places each
incoming message in to a directory with the name of a given folder
such as inbox for all messages that don't belong in other folders. Is
there a good utility for stripping attachments out of a message when
it may contain one or more? Right now, I do it by hand when I need to
and I can probably write a program to do it, but I thought I would
check to see if that is necessary.
The manual process is to copy the message to some scratch
file, run vi on the scratch file and look for base64 which is one type
of encoding, and then strip away all but the garbage of the 7-bit data
which is the base64 representation of the binary. Then, I run a perl
script that has been out on the Internet for years which is called
base64decode. It's standard output is the decoded data stream.
I know that base64 decoding is part of many applications so I
want simply to be able to extract attachments that aren't understood
or can't be displayed such as sound files, etc.
By the way, it is kind of funny to see some of those spam
messages that claim to be the document I requested or some other
enticement to open them. When I do extract the binary just for fun
and run strings on it, I see something like w32.dll or a message
stating that this program can't run in DOS. I saw that on a file that
had a .wav extension. Some poor Windows user was going to dance to
some pretty bad music if they plaid that file.
Martin McCormick WB5AGZ Stillwater, OK
OSU Information Technology Division Network Operations Group
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: Extracting Binaries from MIME-Encoded messages
Martin McCormick
@ ` Kirk Reiser
` Mike Gorse
` Henry Yen
2 siblings, 0 replies; 9+ messages in thread
From: Kirk Reiser @ UTC (permalink / raw)
To: Linux for blind general discussion
Yes, the mpack and munpack utilities do it very nicely. I'm not sure
where to tell you to look though because I use debian and they have a
package called mpack which contains the utilities.
Kirk
--
Kirk Reiser The Computer Braille Facility
e-mail: kirk@braille.uwo.ca University of Western Ontario
phone: (519) 661-3061
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Extracting Binaries from MIME-Encoded messages
Martin McCormick
` Kirk Reiser
@ ` Mike Gorse
` Henry Yen
2 siblings, 0 replies; 9+ messages in thread
From: Mike Gorse @ UTC (permalink / raw)
To: Linux for blind general discussion
I sometimes use uudeview; it might do what you want.
-- Michael Gorse / AIM:linvortex / http://mgorse.home.dhs.org --
A better world is possible! http://www.kucinich.us
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Extracting Binaries from MIME-Encoded messages
Martin McCormick
` Kirk Reiser
` Mike Gorse
@ ` Henry Yen
` Hart Larry
2 siblings, 1 reply; 9+ messages in thread
From: Henry Yen @ UTC (permalink / raw)
To: Linux for blind general discussion
It sounds to me that your issue is more of how to extract the attachments
and less of what to do with them once extracted. As mentioned in other
threads, munpack, uudecode, etc., are various base64 decoders.
For automatic processing of attachments, I've used the "mhn" utility
with success in scripts, although it seems to be split into multiple
commands in recent releases. It's a little more complicated than your
usual unix/linux utility, but once you've got it set up, it works fine.
Also, you might want to consider the "mutt" mail client, which
is a full-screen (not graphical) program that handles attachments
as well. It operates similar to elm and pine.
On Fri, Jun 18, 2004 at 10:28:39AM -0500, Martin McCormick wrote:
> I use nmh for reading Email. This user agent places each
> incoming message in to a directory with the name of a given folder
> such as inbox for all messages that don't belong in other folders. Is
> there a good utility for stripping attachments out of a message when
> it may contain one or more?
>
> The manual process is to copy the message to some scratch
> file, run vi on the scratch file and look for base64 which is one type
> of encoding, and then strip away all but the garbage of the 7-bit data
> which is the base64 representation of the binary. Then, I run a perl
> script that has been out on the Internet for years which is called
> base64decode. It's standard output is the decoded data stream.
>
> I know that base64 decoding is part of many applications so I
> want simply to be able to extract attachments that aren't understood
> or can't be displayed such as sound files, etc.
--
Henry Yen Aegis Information Systems, Inc.
Senior Systems Programmer Hicksville, New York
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~ UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
Extracting Binaries from MIME-Encoded messages Martin McCormick
-- strict thread matches above, loose matches on Subject: below --
Martin McCormick
Martin McCormick
Karl Dahlke
Martin McCormick
` Kirk Reiser
` Mike Gorse
` Henry Yen
` Hart Larry
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).