compctl -K mhfseq -x 's[+][@]' -K mhcomp -S / -q - 's[-]' \
-k "(file part type list headers noheaders realsize norealsize nolist \
show serialonly noserialonly form pause nopause noshow store auto noauto \
- nostore cache nocache rcache wcache check nocheck ebcdicsafe noebcdicsafe \
+ nostore cache nocache rcache wcache check nocheck \
rfc934mode norfc934mode verbose noverbose help)" - \
'c[-1,-file]' -f - 'c[-1,-form]' -K mhfile - \
'C[-1,-[rw]cache]' -k '(public private never ask)' -- mhn
sendmail/pipe.
- Support for the undocumented and deprecated --enable-nmh-debug configure
flag has been removed.
+- Support for encoding some characters designated as EBCDIC-unsafe
+ via the -ebcdicsafe and -noebcdicsafe switches to mhbuild has
+ been removed.
---------
BUG FIXES
.RB [ \-realsize " | " \-norealsize ]
.RB [ \-headers " | " \-noheaders ]
.RB [ \-directives " | " \-nodirectives ]
-.RB [ \-ebcdicsafe " | " \-noebcdicsafe ]
.RB [ \-rfc934mode " | " \-norfc934mode ]
.RB [ \-contentid " | " \-nocontentid ]
.RB [ \-verbose " | " \-noverbose ]
a transfer encoding, even it the content contains only 7\-bit data. This
is to increase the likelihood that the content is not changed while in
transport.
-.PP
-The switch
-.B \-ebcdicsafe
-will cause
-.B mhbuild
-to slightly change
-the way in which it performs the \*(lqquoted-printable\*(rq transfer
-encoding. Along with encoding 8\-bit characters, it will now also encode
-certain common punctuation characters as well. This slightly reduces the
-readability of the message, but allows the message to pass more reliably
-through mail gateways which involve the EBCDIC character encoding.
.SS "Invoking mhbuild"
Typically,
.B mhbuild
.RB ` \-norfc934mode '
.RB ` \-contentid '
.RB ` \-nocheck '
-.RB ` \-noebcdicsafe '
.RB ` \-noverbose '
.fi
.B mhn
.B \-build
.I file
-.RB [ \-ebcdicsafe " | " \-noebcdicsafe ]
.RB [ \-rfc934mode " | " \-norfc934mode ]
.ad
.SH DESCRIPTION
{ "directives", 0 },
#define NDIRECTIVES 3
{ "nodirectives", 0 },
-#define EBCDICSW 4
- { "ebcdicsafe", 0 },
-#define NEBCDICSW 5
- { "noebcdicsafe", 0 },
-#define HEADSW 6
+#define HEADSW 4
{ "headers", 0 },
-#define NHEADSW 7
+#define NHEADSW 5
{ "noheaders", 0 },
-#define LISTSW 8
+#define LISTSW 6
{ "list", 0 },
-#define NLISTSW 9
+#define NLISTSW 7
{ "nolist", 0 },
-#define SIZESW 10
+#define SIZESW 8
{ "realsize", 0 },
-#define NSIZESW 11
+#define NSIZESW 9
{ "norealsize", 0 },
-#define RFC934SW 12
+#define RFC934SW 10
{ "rfc934mode", 0 },
-#define NRFC934SW 13
+#define NRFC934SW 11
{ "norfc934mode", 0 },
-#define VERBSW 14
+#define VERBSW 12
{ "verbose", 0 },
-#define NVERBSW 15
+#define NVERBSW 13
{ "noverbose", 0 },
-#define RCACHESW 16
+#define RCACHESW 14
{ "rcache policy", 0 },
-#define WCACHESW 17
+#define WCACHESW 15
{ "wcache policy", 0 },
-#define CONTENTIDSW 18
+#define CONTENTIDSW 16
{ "contentid", 0 },
-#define NCONTENTIDSW 19
+#define NCONTENTIDSW 17
{ "nocontentid", 0 },
-#define VERSIONSW 20
+#define VERSIONSW 18
{ "version", 0 },
-#define HELPSW 21
+#define HELPSW 19
{ "help", 0 },
-#define DEBUGSW 22
+#define DEBUGSW 20
{ "debug", -5 },
{ NULL, 0 }
};
int debugsw = 0;
int verbosw = 0;
-int ebcdicsw = 0;
int listsw = 0;
int rfc934sw = 0;
int contentidsw = 1;
checksw = 0;
continue;
- case EBCDICSW:
- ebcdicsw++;
- continue;
- case NEBCDICSW:
- ebcdicsw = 0;
- continue;
-
case HEADSW:
headsw++;
continue;
extern int debugsw;
extern int verbosw;
-extern int ebcdicsw;
extern int listsw;
extern int rfc934sw;
extern int contentidsw;
}
-static char ebcdicsafe[0x100] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
- 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
-};
-
-
/*
* Fill out, or expand the various contents in the composition
* draft. Read-in any necessary files. Parse and execute any
int checklinelen = 0, linelen = 0; /* check for long lines */
int checkboundary = 0, boundaryclash = 0; /* check if clashes with multipart boundary */
int checklinespace = 0, linespace = 0; /* check if any line ends with space */
- int checkebcdic = 0, ebcdicunsafe = 0; /* check if contains ebcdic unsafe characters */
unsigned char *cp = NULL, buffer[BUFSIZ];
struct text *t = NULL;
FILE *in = NULL;
check8bit = 1;
checkboundary = 1;
if (ct->c_subtype == TEXT_PLAIN) {
- checkebcdic = 0;
checklinelen = 0;
checklinespace = 0;
} else {
- checkebcdic = ebcdicsw;
checklinelen = 1;
checklinespace = 1;
}
case CT_APPLICATION:
check8bit = 1;
- checkebcdic = ebcdicsw;
checklinelen = 1;
checklinespace = 1;
checkboundary = 1;
case CT_MESSAGE:
check8bit = 0;
- checkebcdic = 0;
checklinelen = 0;
checklinespace = 0;
* since we are forcing use of base64.
*/
check8bit = 0;
- checkebcdic = 0;
checklinelen = 0;
checklinespace = 0;
checkboundary = 0;
contains8bit = 1;
check8bit = 0; /* no need to keep checking */
}
- /*
- * Check if character is ebcdic-safe. We only check
- * this if also checking for 8bit data.
- */
- if (checkebcdic && !ebcdicsafe[*cp & 0xff]) {
- ebcdicunsafe = 1;
- checkebcdic = 0; /* no need to keep checking */
- }
}
}
*ep = cp;
}
- if (contains8bit || ebcdicunsafe || linelen || linespace || checksw)
+ if (contains8bit || linelen || linespace || checksw)
ct->c_encoding = CE_QUOTED;
else
ct->c_encoding = CE_7BIT;
case CT_APPLICATION:
/* For application type, use base64, except when postscript */
- if (contains8bit || ebcdicunsafe || linelen || linespace || checksw)
+ if (contains8bit || linelen || linespace || checksw)
ct->c_encoding = (ct->c_subtype == APPLICATION_POSTSCRIPT)
? CE_QUOTED : CE_BASE64;
else
{ "build", -5 },
#define NBUILDSW 36
{ "nobuild", -7 },
-#define EBCDICSW 37
- { "ebcdicsafe", -10 },
-#define NEBCDICSW 38
- { "noebcdicsafe", -12 },
-#define RFC934SW 39
+#define RFC934SW 37
{ "rfc934mode", -10 },
-#define NRFC934SW 40
+#define NRFC934SW 38
{ "norfc934mode", -12 },
{ NULL, 0 }
};
* variables for mhbuild (mhn -build)
*/
static int buildsw = 0;
-static int ebcdicsw = 0;
static int rfc934sw = 0;
/*
case NRFC934SW:
rfc934sw = -1;
continue;
- case EBCDICSW:
- ebcdicsw = 1;
- continue;
- case NEBCDICSW:
- ebcdicsw = -1;
- continue;
case VERBSW:
verbosw = 1;
vecp = 0;
vec[vecp++] = "mhbuild";
- if (ebcdicsw == 1)
- vec[vecp++] = "-ebcdicsafe";
- else if (ebcdicsw == -1)
- vec[vecp++] = "-noebcdicsafe";
-
if (rfc934sw == 1)
vec[vecp++] = "-rfc934mode";
else if (rfc934sw == -1)
vecp = 0;
vec[vecp++] = "mhbuild";
- if (ebcdicsw == 1)
- vec[vecp++] = "-ebcdicsafe";
- else if (ebcdicsw == -1)
- vec[vecp++] = "-noebcdicsafe";
-
if (rfc934sw == 1)
vec[vecp++] = "-rfc934mode";
else if (rfc934sw == -1)
#include <h/mhparse.h>
-extern int ebcdicsw;
-
-static char ebcdicsafe[0x100] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
- 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
- 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
-};
-
/*
* prototypes
*/
break;
default:
- if (*cp < '!' || *cp > '~'
- || (ebcdicsw && !ebcdicsafe[*cp & 0xff]))
+ if (*cp < '!' || *cp > '~')
goto three_print;
putc (*cp, out);
n++;
};
-int ebcdicsw = 0; /* hack for linking purposes */
-
/* mhparse.c */
extern char *tmp; /* directory to place temp files */
{ "noauto", 0 },
#define MHNDEBUGSW 2
{ "debug", -5 },
-#define MHNEBCDICSW 3
- { "ebcdicsafe", 0 },
-#define MHNNEBCDICSW 4
- { "noebcdicsafe", 0 },
-#define MHNFORMSW 5
+#define MHNFORMSW 3
{ "form formfile", 4 },
-#define MHNHEADSW 6
+#define MHNHEADSW 4
{ "headers", 0 },
-#define MHNNHEADSW 7
+#define MHNNHEADSW 5
{ "noheaders", 0 },
-#define MHNLISTSW 8
+#define MHNLISTSW 6
{ "list", 0 },
-#define MHNNLISTSW 9
+#define MHNNLISTSW 7
{ "nolist", 0 },
-#define MHNPARTSW 10
+#define MHNPARTSW 8
{ "part number", 0 },
-#define MHNSIZESW 11
+#define MHNSIZESW 9
{ "realsize", 0 },
-#define MHNNSIZESW 12
+#define MHNNSIZESW 10
{ "norealsize", 0 },
-#define MHNRFC934SW 13
+#define MHNRFC934SW 11
{ "rfc934mode", 0 },
-#define MHNNRFC934SW 14
+#define MHNNRFC934SW 12
{ "norfc934mode", 0 },
-#define MHNSERIALSW 15
+#define MHNSERIALSW 13
{ "serialonly", 0 },
-#define MHNNSERIALSW 16
+#define MHNNSERIALSW 14
{ "noserialonly", 0 },
-#define MHNSHOWSW 17
+#define MHNSHOWSW 15
{ "show", 0 },
-#define MHNNSHOWSW 18
+#define MHNNSHOWSW 16
{ "noshow", 0 },
-#define MHNSTORESW 19
+#define MHNSTORESW 17
{ "store", 0 },
-#define MHNNSTORESW 20
+#define MHNNSTORESW 18
{ "nostore", 0 },
-#define MHNTYPESW 21
+#define MHNTYPESW 19
{ "type content", 0 },
-#define MHNVERBSW 22
+#define MHNVERBSW 20
{ "verbose", 0 },
-#define MHNNVERBSW 23
+#define MHNNVERBSW 21
{ "noverbose", 0 },
-#define MHNHELPSW 24
+#define MHNHELPSW 22
{ "help", 0 },
-#define MHNPROGSW 25
+#define MHNPROGSW 23
{ "moreproc program", -4 },
-#define MHNNPROGSW 26
+#define MHNNPROGSW 24
{ "nomoreproc", -3 },
-#define MHNLENSW 27
+#define MHNLENSW 25
{ "length lines", -4 },
-#define MHNWIDSW 28
+#define MHNWIDSW 26
{ "width columns", -4 },
{ NULL, 0 }
};
case MHNAUTOSW:
case MHNNAUTOSW:
case MHNDEBUGSW:
- case MHNEBCDICSW:
- case MHNNEBCDICSW:
case MHNHEADSW:
case MHNNHEADSW:
case MHNLISTSW:
extern int splitsw;
extern int verbsw;
-int ebcdicsw = 0; /* hack for linking purposes */
-
/*
* static prototypes
*/