1 |
.TH MUNPACK 1 |
2 |
.SH NAME |
3 |
munpack \- unpack messages in MIME or split-uuencode format |
4 |
.SH SYNOPSIS |
5 |
.B munpack |
6 |
[ |
7 |
.B \-f |
8 |
] |
9 |
[ |
10 |
.B \-q |
11 |
] |
12 |
[ |
13 |
.B \-t |
14 |
] |
15 |
[ |
16 |
.B \-C |
17 |
.I directory |
18 |
] |
19 |
[ |
20 |
.I "filename \&..." |
21 |
] |
22 |
.SH DESCRIPTION |
23 |
The |
24 |
.I munpack |
25 |
program reads each RFC-822 message |
26 |
.I filename |
27 |
and writes all non-text MIME parts or split-uuencoded files as files. |
28 |
If no filename argument is given, |
29 |
.B munpack |
30 |
reads from standard input. |
31 |
.LP |
32 |
If the message suggests a file name to use for the imbedded part, that |
33 |
name is cleaned of potential problem characters and used for the |
34 |
output file. If the suggested filename includes subdirectories, they |
35 |
will be created as necessary. |
36 |
If the message does not suggest a file name, the names |
37 |
"part1", "part2", etc are used in sequence. |
38 |
.LP |
39 |
If the imbedded part was preceded with textual information, that |
40 |
information is also written to a file. The file is named the same as |
41 |
the imbedded part, with any filename extension replaced with ".desc". |
42 |
.SH OPTIONS |
43 |
.TP |
44 |
.B \-f |
45 |
Force overwriting of existing files. If a message suggests a file |
46 |
name of an existing file, the file will be overwritten. Without this |
47 |
flag, |
48 |
.B |
49 |
munpack |
50 |
appends ".1", ".2", etc to find a nonexistent file. |
51 |
.TP |
52 |
.B \-q |
53 |
Be quiet. Supresses messages about saving partial messages and about |
54 |
messages with no interesting information. |
55 |
.TP |
56 |
.B \-t |
57 |
Also write the text MIME parts of multipart messages as files. By |
58 |
default, text parts that do not have a filename parameter do not get |
59 |
unpacked. This option effectively disables the ".desc" file feature |
60 |
for MIME messages. |
61 |
.TP |
62 |
.BI \-C " directory" |
63 |
Change the current directory to |
64 |
.I directory |
65 |
before reading any files. This is useful when invoking |
66 |
.B munpack |
67 |
from a mail or news reader. |
68 |
.SH "DECODING MIME" |
69 |
.LP |
70 |
To decode a MIME message, first save it to a text file. If possible, |
71 |
save it with all headers included. |
72 |
.I Munpack |
73 |
can decode some MIME files |
74 |
when the headers are missing or incomplete, other files it cannot |
75 |
decode without having the information in the headers. In general, |
76 |
messages which have a statement at the beginning that they are in MIME |
77 |
format can be decoded without the headers. Messages which have been |
78 |
split into multiple parts generally require all headers in order to be |
79 |
reassembled and decoded. |
80 |
.LP |
81 |
Some LAN-based mail systems and some mail providers (including America |
82 |
Online, as of the writing of this document) place the mail headers at |
83 |
the bottom of the message, instead of at the top of the message. If |
84 |
you are having problems decoding a MIME message on such a system, you |
85 |
need to convert the mail back into the standard format by removing the |
86 |
system's nonstandard headers and moving the standard Internet headers |
87 |
at the top of the message (separated from the message body with a |
88 |
blank line). |
89 |
.LP |
90 |
There must be exactly one message per file. |
91 |
.I Munpack |
92 |
cannot deal with |
93 |
multiple messages in a single file, to decode things correctly it must |
94 |
know when one message ends and the next one begins. |
95 |
.LP |
96 |
To decode a message, run the command: |
97 |
.IP |
98 |
.IB munpack " file" |
99 |
.LP |
100 |
where "file" is the name of the file containing the message. More than |
101 |
one filename may be specified, |
102 |
.I munpack |
103 |
will try to decode the message in |
104 |
each file. For more information on ways to run |
105 |
.IR munpack , |
106 |
see the section "OPTIONS" above. |
107 |
.SH ENVIRONMENT |
108 |
.TP |
109 |
.B TMPDIR |
110 |
Directory to store temporary files. Default is /usr/tmp. |
111 |
.SH FILES |
112 |
.TP |
113 |
.B $TMPDIR/m-prts-$USER/ |
114 |
Directory used to store partial messages awaiting reassembly. |