autoupdate
[postfix-master.git] / postfix-master / CONTENT_INSPECTION_README.html
blobd44c54bcc42c962d218c97b05ea2d95247323005
1 <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"
2 "http://www.w3.org/TR/html4/loose.dtd">
4 <html>
6 <head>
8 <title>Postfix Content Inspection </title>
10 <meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
12 </head>
14 <body>
16 <h1><img src="postfix-logo.jpg" width="203" height="98" ALT="">Postfix
17 Content Inspection </h1>
19 <hr>
21 <p> Postfix supports three content inspection methods, ranging from
22 light-weight one-line-at-a-time scanning before mail is queued, to
23 heavy duty machinery that does sophisticated content analysis after
24 mail is queued. Each approach serves a different purpose. </p>
26 <dl>
28 <dt> <b> before queue, built-in, light-weight</b> </dt>
30 <dd> <p> This method inspects mail BEFORE it is stored in the queue,
31 and uses Postfix's built-in message header and message body
32 inspection. Although the main purpose is to stop a specific flood
33 of mail from worms or viruses, it is also useful to block a flood
34 of bounced junk email and email notifications from virus detection
35 systems. The built-in regular expressions are not meant to implement
36 general SPAM and virus detection. For that, you should use one of
37 the content inspection methods described below. Details are described
38 in the <a href="BUILTIN_FILTER_README.html">BUILTIN_FILTER_README</a> and <a href="BACKSCATTER_README.html">BACKSCATTER_README</a> documents.
39 </p>
41 <dt> <b> after queue, external, heavy-weight</b> </dt>
43 <dd> <p> This method inspects mail AFTER it is stored in the queue,
44 and uses standard protocols such as SMTP or "pipe to command and
45 wait for exit status". After-queue inspection allows you to use
46 content filters of arbitrary complexity without causing timeouts
47 while receiving mail, and without running out of memory resources
48 under a peak load. Details of this approach are in the <a href="FILTER_README.html">FILTER_README</a>
49 document. </p>
51 <dt> <b> before queue, external, medium-weight</b> </dt>
53 <dd> <p> The following two methods inspect mail BEFORE it is stored in the
54 queue. </p>
56 <ul>
58 <li> <p> The first method uses the SMTP protocol, and is described
59 in the <a href="SMTPD_PROXY_README.html">SMTPD_PROXY_README</a> document. This approach is available
60 with Postfix version 2.1 and later. </p>
62 <li> <p> The second method uses the Sendmail 8 Milter protocol, and
63 is described in the <a href="MILTER_README.html">MILTER_README</a> document. This approach is
64 available with Postfix version 2.3 and later. </p>
66 </ul>
68 <p> Although these approaches appear to be attractive, they have
69 some serious limitations that you need to be aware of. First,
70 content inspection software must finish in a limited amount of time;
71 if content inspection needs too much time then incoming mail
72 deliveries will time out. Second, content inspection software must
73 run in a limited amount of memory; if content inspection needs too
74 much memory then software will crash under a peak load. Before-queue
75 inspection limits the peak load that your system can handle, and
76 limits the sophistication of the content filter that you can use.
77 </p>
79 </dl>
81 <p> The more sophisticated content filtering software is not built
82 into Postfix for good reasons: writing an MTA requires different
83 skills than writing a SPAM or virus killer. Postfix encourages the
84 use of external filters and standard protocols because this allows
85 you to choose the best MTA and the best content inspection software
86 for your purpose. Information about external content inspection
87 software can be found on the Postfix website at <a href="http://www.postfix.org/">http://www.postfix.org/</a>,
88 and on the postfix-users@postfix.org mailing list. </p>
90 </body>
92 </html>