1 |
lefcha |
1.6 |
.TH IMAPFILTER 1 "26 August 2001" "CVS" Commands |
2 |
lefcha |
1.1 |
.SH NAME |
3 |
|
|
imapfilter - mail filter |
4 |
|
|
.SH SYNOPSIS |
5 |
|
|
.B imapfilter |
6 |
lefcha |
1.3 |
.RB [ -hqstv ] |
7 |
lefcha |
1.1 |
.RB [ -c |
8 |
|
|
.IR configfile ] |
9 |
|
|
.RB [ -l |
10 |
|
|
.IR logfile ] |
11 |
|
|
.SH DESCRIPTION |
12 |
|
|
.B imapfilter |
13 |
|
|
is a mail filtering utility. It connects to remote mail servers using the |
14 |
|
|
Internet Message Access Protocol (IMAP) and deletes messages according to |
15 |
|
|
defined filter rules. It is purposed as a preconnect utility before user |
16 |
|
|
accesses his/her mailbox (eg. fetch mail). In that way it "clears" user's |
17 |
|
|
mailbox from any unwanted messages, without having to download even a single |
18 |
|
|
header line of them. |
19 |
|
|
.SH OPTIONS |
20 |
|
|
.TP |
21 |
|
|
.B -c configfile |
22 |
|
|
Configuration file to read settings and filters from. The default is |
23 |
|
|
.IR $HOME/.imapfilterrc . |
24 |
|
|
.TP |
25 |
lefcha |
1.2 |
.B -h |
26 |
lefcha |
1.3 |
Prints a summary of program's options. |
27 |
lefcha |
1.2 |
.TP |
28 |
lefcha |
1.1 |
.B -l logfile |
29 |
lefcha |
1.3 |
File that contains logs of error messages |
30 |
lefcha |
1.1 |
.B imapfilter |
31 |
lefcha |
1.3 |
produces and optionally, if the |
32 |
|
|
.B -s |
33 |
|
|
option is given, information about the deleted messages. |
34 |
lefcha |
1.1 |
.TP |
35 |
|
|
.B -q |
36 |
|
|
Be quite; don't print any information at all. |
37 |
|
|
.TP |
38 |
lefcha |
1.3 |
.B -s |
39 |
|
|
Show some of the headers (specifically Date, From and Subject) of the deleted |
40 |
|
|
messages. |
41 |
|
|
.TP |
42 |
lefcha |
1.1 |
.B -t |
43 |
|
|
Enables test mode, in which the program works as before, but just doesn't |
44 |
|
|
delete any messages on remote mailbox. |
45 |
|
|
.TP |
46 |
|
|
.B -v |
47 |
|
|
Be verbose; print detailed information about the program's actions. |
48 |
|
|
.SH CONFIGURATION FILE |
49 |
lefcha |
1.3 |
.PP |
50 |
lefcha |
1.1 |
The configuration file has the following format: |
51 |
|
|
.PP |
52 |
|
|
Empty lines and lines beginning with '#' are considered comments. |
53 |
|
|
.PP |
54 |
lefcha |
1.4 |
Otherwise a line is in the format "KEYWORD = ARGUMENT" for account settings, |
55 |
lefcha |
1.6 |
"FILTER = HEADER" for the filters entries, "LIMIT = SIZE" for the message |
56 |
|
|
limits and "OPTION = ARGUMENT" for any other settings. |
57 |
lefcha |
1.1 |
.PP |
58 |
lefcha |
1.6 |
The available keywords for account settings are: |
59 |
lefcha |
1.1 |
.TP |
60 |
|
|
.B SERVER |
61 |
|
|
Hostname of the mailserver on which to connect. |
62 |
|
|
.TP |
63 |
|
|
.B PORT |
64 |
|
|
TCP/IP port to connect on to remote server. If not provided the default IMAP |
65 |
|
|
protocol port (ie. port 143) will be used. |
66 |
|
|
.TP |
67 |
|
|
.B USERNAME |
68 |
|
|
User's name to be used while logging in to server. |
69 |
|
|
.TP |
70 |
|
|
.B PASSWORD |
71 |
|
|
Password of the user. |
72 |
lefcha |
1.6 |
.PP |
73 |
|
|
More than one accounts can be declared. The SERVER keyword is used to seperate |
74 |
|
|
the accounts and denote the definition of a new account. Whenever a PORT, |
75 |
|
|
USERNAME or PASSWORD keyword is found, it associates with the last preceding |
76 |
|
|
SERVER argument. |
77 |
lefcha |
1.2 |
.PP |
78 |
|
|
Filter entries are: |
79 |
lefcha |
1.1 |
.TP |
80 |
|
|
.B DENY |
81 |
lefcha |
1.2 |
Remove all messages that match the defined HEADER. |
82 |
|
|
.TP |
83 |
|
|
.B ALLOW |
84 |
|
|
Override all DENY filters and define exceptions, according to which |
85 |
lefcha |
1.4 |
messages will not be deleted. If no DENY filters where defined, then |
86 |
|
|
.B everything |
87 |
|
|
is deleted except the ALLOW filters. |
88 |
lefcha |
1.2 |
.PP |
89 |
lefcha |
1.1 |
The HEADER is comprised by FIELD-NAME and FIELD-BODY, with the two seperated |
90 |
|
|
with an optional ':' character and |
91 |
|
|
.B only |
92 |
|
|
one space. |
93 |
|
|
|
94 |
|
|
The FIELD-NAME should be one of FROM, TO, CC, BCC, SUBJECT or a user specified |
95 |
|
|
header field-name. The FIELD-BODY is a string. Messages that have a header |
96 |
|
|
with the defined FIELD-NAME and contain the FIELD-BODY match the DENY filter |
97 |
|
|
and are being deleted. The matching is case-insensitive. |
98 |
lefcha |
1.5 |
.PP |
99 |
|
|
Message limits are: |
100 |
|
|
.TP |
101 |
|
|
.B DENY_LIMIT |
102 |
|
|
All messages, except those that match the ALLOW filters, with size in octets |
103 |
|
|
(bytes) greater than the supplied, are deleted. |
104 |
|
|
.TP |
105 |
|
|
.B ALLOW_LIMIT |
106 |
|
|
Size limit for messages that match the ALLOW filters, in other words, messages |
107 |
|
|
that the DENY_LIMIT cannot filter. |
108 |
lefcha |
1.6 |
.PP |
109 |
|
|
Other options are: |
110 |
|
|
.TP |
111 |
|
|
.B LOGFILE |
112 |
|
|
Log file to save filtering information and error messages. |
113 |
lefcha |
1.1 |
.SH CONFIGURATION EXAMPLES |
114 |
|
|
See |
115 |
|
|
.IR sample.imapfilterrc . |
116 |
|
|
.SH FILES |
117 |
|
|
.TP |
118 |
|
|
.I $HOME/.imapfilterrc |
119 |
|
|
Default configuration file. |
120 |
lefcha |
1.3 |
.SH ENVIROMENT |
121 |
lefcha |
1.1 |
.TP |
122 |
lefcha |
1.3 |
.B HOME |
123 |
|
|
User's home directory. |
124 |
lefcha |
1.1 |
.SH CONFORMING TO |
125 |
|
|
.TP |
126 |
|
|
IMAP4rev1: |
127 |
|
|
RFC 2060 |
128 |
|
|
.SH AUTHOR |
129 |
lefcha |
1.2 |
Lefteris Chatzibarbas <lefcha@users.sourceforge.net> |