Import ezmlm-idx 0.40
[ezmlm] / ezmlm-reject.1
CommitLineData
5b62e993
MW
1.TH ezmlm-reject 1
2.SH NAME
3ezmlm-reject \- reject messages unsuitable for distribution
4.SH SYNOPSIS
5.B ezmlm-reject
6[
f8beb284
MW
7.B \-bBcChHqQsStT
8][
9.I dir
5b62e993
MW
10]
11.SH DESCRIPTION
12.B ezmlm-reject
13reads a mail message from its standard input.
14It rejects the message if it sees something it doesn't like.
f8beb284
MW
15
16If the message has a ``Precedence: junk'' header,
17.B ezmlm-reject
18exits 99 causing the message to be ignored. This causes replies from (some)
19vacation programs to be ignored.
20
21If
22.I dir
23is specified,
24.B ezmlm-reject
25reads
26.I dir\fB/msgsize
27for a maximum:minimum message body size in bytes. Either number will be ignored
28if 0 or omitted.
29.B ezmlm-reject
30will also look for
31.I dir\fB/mimereject
32and
33.IR dir\fB/mimeremove .
34if
35.IR dir\fB/mimereject
36exists,
37Messages of the Content-Types specified or with MIME parts of these
38types will be rejected.
39If
40.I dir\fB/mimeremove
41exists,
42.B ezmlm-reject
43will reject messages of the Content-Types specified. These content-types will
44be accepted as parts of a composite MIME message. They will be
45stripped out later by
46.BR ezmlm-send(1) .
47
48.B ezmlm-reject
49will exit 100 (permanent error) for rejections. If the list address is not in
50the message ``To:'' or ``Cc:'' headers and the
51.B \-t
52switch is active, the exit code is 100 or 99, depending on the
53.B \-q
54switch (see below).
55If you would like to forward messages instead of rejecting them, you can
56into the appropriate .qmail file put:
57
58.EX
59 |condredirect newaddress except /path/ezmlm-reject DIR
60.EE
61
62Now rejected posts will
63go to this address, and the recipient can take appropriate action.
5b62e993
MW
64.SH OPTIONS
65.TP
f8beb284
MW
66.B \-b
67Reject the message if the message body starts ``subscribe''
68or ``unsubscribe''. If the
69.B \-c
70switch is specified, messages will also be rejected if the subject starts
71with these words.
72.B \-B
73(Default.)
74Do not reject messages starting ``subscribe'' or ``unsubscribe''.
75.TP
5b62e993
MW
76.B \-c
77(Default.)
78Commands are not permitted in the Subject line.
f8beb284 79A Subject line consisting solely of HELP, REMOVE, SUBSCRIBE, or UNSUBSCRIBE
5b62e993
MW
80is rejected.
81.TP
82.B \-C
83Commands are permitted in the subject line.
84.TP
f8beb284
MW
85.B \-h
86Reject message if any of the headers in
87.I dir\fB/headerreject
88occur in the header. Mailing-List headers of other mailing list managers
89can be put into this file, one per line, to prevent processing of messages
90from other mailing lists.
91.I dir
92must be specified.
93
94A reasonable set of headers would be: ``Mailing-List'', ``X-ml-name'',
95\``ml-name'',``X-loop'',``X-listprocessor-version'',``X-mailing-list''. Case
96is not important.
97.TP
98.B \-H
99(Default.)
100Ignore
101.IR dir\fB/headerreject .
102.B \-q
103Quiet. If the message due to the lack of the list address (see
104.BR \-t )
105is not accepted, this is logged but no error message is sent to the sender.
106.TP
107.B \-q
108Quiet. If a message due to the lack of the list address (see
109.BR \-t )
110is not accepted,
111the message is silently ignored.
112.TP
113.B \-Q
114(Default.)
115Not quiet. If a message due to the lack of the list address (see
116.BR \-t )
117is not accepted,
118the sender is notified by an error message.
119.TP
5b62e993
MW
120.B \-s
121(Default.)
122A nonempty Subject line is required.
123.TP
124.B \-S
125A Subject line is not required.
f8beb284
MW
126.TP
127.B \-t
128(Default.)
129Reject messages that do not have the list address in the ``To:'' or ``Cc:''
130header(s).
131.B ezmlm-reject
132needs access to
133.I dir\fB/outhost
134and
135.I dir\fB/outlocal
136to check this. This check is silently omitted if
137.I dir
138is not specified, to assure backwards compatibility with existing ezmlm lists.
139.TP
140.B \-T
141Do not require the list address in the ``To:'' or ``Cc:'' header(s).
142.SH BUGS
143.B ezmlm-reject
144does not handle rfc822 comments in ``Content-Type:'' lines if present
145before the type or boundary.
146This could be used to defeat the
147MIME rejection function.
148OTOH, this function is intended to reduce garbage, not guarantee
149its elimination.
5b62e993
MW
150.SH "SEE ALSO"
151ezmlm-send(1),
152qmail-command(8)