1SPAMASSASSIN(1) User Contributed Perl Documentation SPAMASSASSIN(1)
2
3
4
6 spamassassin - extensible email filter used to identify spam
7
9 SpamAssassin is an intelligent email filter which uses a diverse range
10 of tests to identify unsolicited bulk email, more commonly known as
11 "spam". These tests are applied to email headers and content to
12 classify email using advanced statistical methods. In addition,
13 SpamAssassin has a modular architecture that allows other technologies
14 to be quickly wielded against spam and is designed for easy integration
15 into virtually any email system.
16
18 For ease of access, the SpamAssassin manual has been split up into
19 several sections. If you're intending to read these straight through
20 for the first time, the suggested order will tend to reduce the number
21 of forward references.
22
23 Extensive additional documentation for SpamAssassin is available,
24 primarily on the SpamAssassin web site and wiki.
25
26 You should be able to view SpamAssassin's documentation with your
27 man(1) program or perldoc(1).
28
29 OVERVIEW
30 spamassassin SpamAssassin overview (this section)
31
32 CONFIGURATION
33 Mail::SpamAssassin::Conf SpamAssassin configuration files
34
35 USAGE
36 spamassassin-run "spamassassin" front-end filtering script
37 sa-learn train SpamAssassin's Bayesian classifier
38 spamc client for spamd (faster than spamassassin)
39 spamd spamassassin server (needed by spamc)
40
41 DEFAULT PLUGINS
42 Mail::SpamAssassin::Plugin::AskDNS
43 Mail::SpamAssassin::Plugin::AutoLearnThreshold
44 Mail::SpamAssassin::Plugin::Bayes
45 Mail::SpamAssassin::Plugin::BodyEval
46 Mail::SpamAssassin::Plugin::Check
47 Mail::SpamAssassin::Plugin::DKIM
48 Mail::SpamAssassin::Plugin::DNSEval
49 Mail::SpamAssassin::Plugin::FreeMail
50 Mail::SpamAssassin::Plugin::HTMLEval
51 Mail::SpamAssassin::Plugin::HTTPSMismatch
52 Mail::SpamAssassin::Plugin::Hashcash
53 Mail::SpamAssassin::Plugin::HeaderEval
54 Mail::SpamAssassin::Plugin::ImageInfo
55 Mail::SpamAssassin::Plugin::MIMEEval
56 Mail::SpamAssassin::Plugin::MIMEHeader
57 Mail::SpamAssassin::Plugin::Pyzor
58 Mail::SpamAssassin::Plugin::Razor2
59 Mail::SpamAssassin::Plugin::RelayEval
60 Mail::SpamAssassin::Plugin::ReplaceTags
61 Mail::SpamAssassin::Plugin::SPF
62 Mail::SpamAssassin::Plugin::SpamCop
63 Mail::SpamAssassin::Plugin::URIDNSBL
64 Mail::SpamAssassin::Plugin::URIDetail
65 Mail::SpamAssassin::Plugin::URIEval
66 Mail::SpamAssassin::Plugin::VBounce
67 Mail::SpamAssassin::Plugin::WLBLEval
68 Mail::SpamAssassin::Plugin::WhiteListSubject
69
71 SpamAssassin web site: http://spamassassin.apache.org/
72 Wiki-based documentation: http://wiki.apache.org/spamassassin/
73
75 A users mailing list exists where other experienced users are often
76 able to help and provide tips and advice. Subscription instructions
77 are located on the SpamAssassin web site.
78
80 The SpamAssassin rule base, text templates, and rule description text
81 are loaded from configuration files.
82
83 Default configuration data is loaded from the first existing directory
84 in:
85
86 /var/lib/spamassassin/3.004002
87 /usr/share/spamassassin
88 /usr/share/spamassassin
89 /usr/local/share/spamassassin
90 /usr/share/spamassassin
91
92 Site-specific configuration data is used to override any values which
93 had already been set. This is loaded from the first existing directory
94 in:
95
96 /etc/mail/spamassassin
97 /usr/etc/mail/spamassassin
98 /usr/etc/spamassassin
99 /usr/local/etc/spamassassin
100 /usr/pkg/etc/spamassassin
101 /usr/etc/spamassassin
102 /etc/mail/spamassassin
103 /etc/spamassassin
104
105 From those three directories, SpamAssassin will first read files ending
106 in ".pre" in lexical order and then it will read files ending in ".cf"
107 in lexical order (most files begin with two numbers to make the sorting
108 order obvious).
109
110 In other words, it will read init.pre first, then 10_default_prefs.cf
111 before 50_scores.cf and 20_body_tests.cf before 20_head_tests.cf.
112 Options in later files will override earlier files.
113
114 Individual user preferences are loaded from the location specified on
115 the "spamassassin", "sa-learn", or "spamd" command line (see respective
116 manual page for details). If the location is not specified,
117 ~/.spamassassin/user_prefs is used if it exists. SpamAssassin will
118 create that file if it does not already exist, using
119 user_prefs.template as a template. That file will be looked for in:
120
121 /etc/mail/spamassassin
122 /usr/etc/mail/spamassassin
123 /usr/share/spamassassin
124 /etc/spamassassin
125 /etc/mail/spamassassin
126 /usr/local/share/spamassassin
127 /usr/share/spamassassin
128
130 The following two sections detail the default tagging and markup that
131 takes place for messages when running "spamassassin" or "spamc" with
132 "spamd" in the default configuration.
133
134 Note: before header modification and addition, all headers beginning
135 with "X-Spam-" are removed to prevent spammer mischief and also to
136 avoid potential problems caused by prior invocations of SpamAssassin.
137
138 TAGGING FOR SPAM MAILS
139 By default, all messages with a calculated score of 5.0 or higher are
140 tagged as spam.
141
142 If an incoming message is tagged as spam, instead of modifying the
143 original message, SpamAssassin will create a new report message and
144 attach the original message as a message/rfc822 MIME part (ensuring the
145 original message is completely preserved and easier to recover).
146
147 The new report message inherits the following headers (if they are
148 present) from the original spam message:
149
150 From: header
151 To: header
152 Cc: header
153 Subject: header
154 Date: header
155 Message-ID: header
156
157 The above headers can be modified if the relevant "rewrite_header"
158 option is given (see "Mail::SpamAssassin::Conf" for more information).
159
160 By default these message headers are added to spam:
161
162 X-Spam-Flag: header
163 Set to "YES".
164
165 The headers that added are fully configurable via the "add_header"
166 option (see "Mail::SpamAssassin::Conf" for more information).
167
168 spam mail body text
169 The SpamAssassin report is added to top of the mail message body,
170 if the message is marked as spam.
171
172 DEFAULT TAGGING FOR ALL MAILS
173 These headers are added to all messages, both spam and ham (non-spam).
174
175 X-Spam-Checker-Version: header
176 The version and subversion of SpamAssassin and the host where
177 SpamAssassin was run.
178
179 X-Spam-Level: header
180 A series of "*" charactes where each one represents a full score
181 point.
182
183 X-Spam-Status: header
184 A string, "(Yes|No), score=nn required=nn tests=xxx,xxx
185 autolearn=(ham|spam|no|unavailable|failed)" is set in this header
186 to reflect the filter status. For the first word, "Yes" means spam
187 and "No" means ham (non-spam).
188
189 The headers that added are fully configurable via the "add_header"
190 option (see "Mail::SpamAssassin::Conf" for more information).
191
193 The spamassassin command is part of the Mail::SpamAssassin Perl module.
194 Install this as a normal Perl module, using "perl -MCPAN -e shell", or
195 by hand.
196
197 Note that it is not possible to use the "PERL5LIB" environment variable
198 to affect where SpamAssassin finds its perl modules, due to limitations
199 imposed by perl's "taint" security checks.
200
201 For further details on how to install, please read the "INSTALL" file
202 from the SpamAssassin distribution.
203
205 Mail::SpamAssassin
206 Spam detector and markup engine
207
208 Mail::SpamAssassin::ArchiveIterator
209 find and process messages one at a time
210
211 Mail::SpamAssassin::AutoWhitelist
212 auto-whitelist handler for SpamAssassin
213
214 Mail::SpamAssassin::Bayes
215 determine spammishness using a Bayesian classifier
216
217 Mail::SpamAssassin::BayesStore
218 Bayesian Storage Module
219
220 Mail::SpamAssassin::BayesStore::SQL
221 SQL Bayesian Storage Module Implementation
222
223 Mail::SpamAssassin::Conf::LDAP
224 load SpamAssassin scores from LDAP database
225
226 Mail::SpamAssassin::Conf::Parser
227 parse SpamAssassin configuration
228
229 Mail::SpamAssassin::Conf::SQL
230 load SpamAssassin scores from SQL database
231
232 Mail::SpamAssassin::Message
233 decode, render, and hold an RFC-2822 message
234
235 Mail::SpamAssassin::Message::Metadata
236 extract metadata from a message
237
238 Mail::SpamAssassin::Message::Node
239 decode, render, and make available MIME message parts
240
241 Mail::SpamAssassin::PerMsgLearner
242 per-message status (spam or not-spam)
243
244 Mail::SpamAssassin::PerMsgStatus
245 per-message status (spam or not-spam)
246
247 Mail::SpamAssassin::PersistentAddrList
248 persistent address list base class
249
250 Mail::SpamAssassin::Plugin
251 SpamAssassin plugin base class
252
253 Mail::SpamAssassin::Plugin::Hashcash
254 perform hashcash verification tests
255
256 Mail::SpamAssassin::Plugin::RelayCountry
257 add message metadata indicating the country code of each relay
258
259 Mail::SpamAssassin::Plugin::SPF
260 perform SPF verification tests
261
262 Mail::SpamAssassin::Plugin::URIDNSBL
263 look up URLs against DNS blocklists
264
265 Mail::SpamAssassin::SQLBasedAddrList
266 SpamAssassin SQL Based Auto Whitelist
267
269 See <http://issues.apache.org/SpamAssassin/>
270
272 The SpamAssassin(tm) Project <http://spamassassin.apache.org/>
273
275 SpamAssassin is distributed under the Apache License, Version 2.0, as
276 described in the file "LICENSE" included with the distribution.
277
278 Copyright (C) 2015 The Apache Software Foundation
279
280
281
282perl v5.28.1 2019-02-03 SPAMASSASSIN(1)