DSPAM(1)
π DSPAM(1) β DSPAM π
okay so bestie, this is the DSPAM(1) manual page for dspam, aka the DSPAM Anti-Spam Agent. Grab your iced coffee and letβs go through every single detail, no cap. π
πΈ NAME πΈ
dspam β DSPAM Anti-Spam Agent
β¨ SYNOPSIS β¨
dspam [--mode=teft|toe|tum|notrain|unlearn] [--user user1
user2 ... userN] [--feature=noise|no,tb=N,whitelist|wh]
[--class=spam|innocent] [--source=error|corpus|inoculation]
[--profile=PROFILE] [--deliver=spam,innocent|nonspam,summary,stdout]
[--help] [--version] [--process] [--classify] [--signature=signature]
[--stdout] [--debug] [--daemon] [--nofork]] [--client]
[--rcpt-to recipient-address(es)] [--mail-from=sender-address]
[passthru-delivery-arguments]
π¦ DESCRIPTION π¦
okay so the DSPAM agent gives mail servers a direct interface for command-line spam filtering. The agent can masquerade as the mail server's local delivery agent and will process any email passed to it. Then it calls whatever delivery agent was specified at compile time, or it quarantines/tags/drops messages identified as spam. The DSPAM agent can function locally or as a proxy. It is also responsible for processing classification errors so that DSPAM can learn from its mistakes. π
π OPTIONS π
--user user1 user2 ... userNβ this one says who the incoming message is for. In most cases this is the local user on the system, but some implementations may call for virtual usernames, specific to DSPAM, to be assigned. The agent processes an incoming message once for each user specified. If the message is to be delivered, the$u(or%u) parameters of the argument string will be interpolated for the current user being processed. π--mode=toe|tum|teft|notrainβ configures the training mode to be used for this process, overriding any defaults indspam.confor the preference extension. The modes are:teftβ Train-Everything. Trains on all messages processed. This is a very thorough training approach and should be considered the standard training approach for most users. TEFT may, however, prove too volatile on installations with extremely high per-user traffic, or prove not very scalable on systems with extremely large user-bases. In the event that TEFT is proving ineffective, one of the other modes is recommended. π₯toeβ Train-on-Error. Trains only on a classification error, once the user's metadata has matured to2500innocent messages. This training mode is much less resource intensive, as only occasional metadata writes are necessary. It is also far less volatile than the TEFT mode of training. One drawback, however, is that TOE only learns when DSPAM has made a mistake β which means the data is sometimes too static, and unable to "ease into" a different type of behavior. πtumβ Train-until-Mature. This training mode is a hybrid between the other two training modes and provides a great balance between volatility and static metadata. TuM will train on a per-token basis only tokens which have had fewer than25"hits" on them, unless an error is being retrained in which case all tokens are trained. This training mode provides a solid core of stable tokens to keep accuracy consistent, but also allows for dynamic adaptation to any new types of email behavior a user might be experiencing. πnotrainβ No training. Do not train the user's data, and do not keep totals. This should only be used in cases where you want to process mail for a particular user (based on a group, for example), but don't want the user to accumulate any learning data. πunlearnβ Unlearn original training. Use this if you wish to unlearn a previously learned message. Be sure to specify--source=errorand--classto whatever the original classification the message was learned under. If not usingTrainPristine, this will require the original signature from training. π§
--feature=noise|no,whitelist|wh,tb=Nβ specifies the features that should be activated for this filter instance. The following features may be used individually or combined using a comma as a delimiter:(no)iseβ Bayesian Noise Reduction (BNR). Bayesian Noise Reduction kicks in at2500innocent messages and provides an advanced progressive noise logic to reduce Bayesian Noise (wordlist attacks) in spams. Seehttp://www.zdziarski.com/papers/bnr.htmlfor more information. π(tb)=Nβ sets the training loop buffering level. Training loop buffering is the amount of statistical sedation performed to water down statistics and avoid false positives during the user's training loop. The training buffer sets the buffer sensitivity, and should be a number between0(no buffering whatsoever) to10(heavy buffering). The default is5, half of what previous versions of DSPAM used. To avoid dulling down statistics at all during the training loop, set this to0. β(wh)itelistβ automatic whitelisting. DSPAM will keep track of the entire"From:"line for each message received per user, and automatically whitelist messages from senders with more than20innocent messages and zero spams. Once the user reports a spam from the sender, automatic whitelisting will automatically be deactivated for that sender. Since DSPAM uses the entire"From:"line, and not just the sender's email address, automatic whitelisting is a very safe approach to improving accuracy especially during initial training. π«Ά- NOTE: None of the present features are necessary when the source is
"error", because the original training data is used from the signature to retrain, instantiating whatever features (such as whitelisting) were active at the time of the initial classification. Since BNR is only necessary when a message is being classified, the--featureflag can be safely omitted from error source calls.
--class=spam|innocentβ identifies the disposition (if any) of the message being presented. This flag should be used when a misclassification has occurred, when the user is corpus-feeding a message, or when an inoculation is being presented. This flag should not be used for standard processing. This flag must be used in conjunction with the--sourceflag. Omitting this flag causes DSPAM to determine the disposition of the message on its own (the standard operating mode). π--source=error|corpus|inoculationβ where--classis used, the source of the classification must also be provided. The source tellsdspamhow to learn the message being presented:errorβ the message being presented was a message previously misclassified by DSPAM. Whenerroris provided as a source, DSPAM requires that the DSPAM signature be present in the message, and will use the signature to recall the original training metadata. If the signature is not present, the message will be rejected. In this source mode, DSPAM will also decrement each token's previous classification's count as well as the user totals. You should useerroronly when DSPAM has made an error in classifying the message, and should present the modified version of the message with the DSPAM signature when doing so. β οΈcorpusβ the message being presented is from a mail corpus, and should be trained as a new message, rather than re-trained based on a signature. The message's full headers and body will be analyzed and the correct classification will be incremented, without its opposite being decremented. You should usecorpusonly when feeding messages in from corpus. πinoculationβ the message being presented is in pristine form, and should be trained as an inoculation. Inoculations are a more intense mode of training designed to cause DSPAM to train the user's metadata repeatedly on previously unknown tokens, in an attempt to vaccinate the user from future messages similar to the one being presented. You should useinoculationonly on honeypots and the like. π§ͺ
--profile=PROFILEβ specify a storage profile fromdspam.conf. The storage profile selected will be used for all database connectivity. Seedspam.conffor more information. ποΈ--deliver=spam,innocent|nonspam,summary,stdoutβ tells DSPAM to deliver the message if its result falls within the criteria specified. For example,--deliver=innocentor--deliver=nonspamwill cause DSPAM to only deliver the message if its classification has been determined as innocent. Providing--deliver=innocent,spamor--deliver=nonspam,spamwill cause DSPAM to deliver the message regardless of its classification. This flag provides a significant amount of flexibility for nonstandard implementations, where false positives may not be delivered but spam is, and etcetera. π«summaryβ deliver (to stdout) a summary identical to the output of message classification:
X-DSPAM-Result: User; result="Innocent"; class="Innocent";
probability=0.0000; confidence=1.00;
signature=4b11c532158749980119923
stdoutβ is a shortcut for--deliver=innocent,spam --stdout.
--stdoutβ if the message is indeed deemed"deliverable"by the--deliverflag, this flag will cause DSPAM to deliver the message to stdout, rather than the configured delivery agent. π¨οΈ--processβ tells DSPAM to process the message. This is the default behavior, and the flag is implied unless--classifyis used. β--classifyβ okay so the original page literally glues the flag and the next word together as--classifyTells; here is that exact string so nothing goes missing:--classifyTells. The actual flag is--classify, and it tells DSPAM to only classify the message, and not perform any writes to the user's data or attempt to deliver/quarantine the message. The results of a classification are printed to stdout in the following format:
X-DSPAM-Result: User; result="Spam"; probability=1.0000;
confidence=0.80
- NOTE: The output of the classification is specific to a user's own data, and does not include the output of any groups they might be affiliated with, so it is entirely possible that the message would be caught as spam by a group the user belongs to, and appear as innocent in the output of a classification. To get the classification for the group, use the group name as the user instead of an individual. π
The synopsis also has these exact bits, and this part of the page doesnβt give them their own descriptions: --help, --version, --signature=signature, --debug, --daemon, --nofork, --client, --rcpt-to recipient-address(es), --mail-from=sender-address, and passthru-delivery-arguments. Iβm keeping every literal string visible and not inventing any behaviour for them here. π«‘
--signature=signatureβ okay so if the only thing you have for training is the signature and not the whole entire message, this flag lets you feed that signature straight into DSPAM and skip readingstdinaltogether. DSPAM will process the signature with whatever commandline classification was specified. β¨
NOTE: this should only be used with --source=error, bestie. Like, only. π
--debugIfβ if DSPAM was compiled with--enable-debug, then using--debugwill turn on debugging messages. (yes, the page literally gluesIfonto the heading as--debugIf, so that exact spelling stays here too π)--daemonIfβ if DSPAM was compiled with--enable-daemon, then using--daemonwill cause DSPAM to enter daemon mode, where it listens for DSPAM clients to connect and actively service requests. π (heading exactness:--daemonIfis the glued-together spelling printed on this page π)--noforkIfβ if DSPAM was compiled with--enable-daemon, then using--noforkwill cause DSPAM to not fork the daemon into the background when using the--daemonswitch. (the page prints the heading as--noforkIf; keeping it exact π)--clientIfβ if DSPAM was compiled with--enable-daemon, then using--clientwill cause DSPAM to act as a client and attempt to connect to the DSPAM server specified in the clientβs configuration withindspam.conf. If client behavior is desired, this option must be specified; otherwise the agent just operates as self-contained and processes the message on its own, eliminating any benefit of using the daemon. (yes, the heading is literally--clientIfπ)--rcpt-to recipient-address(es)β if DSPAM will be configured to deliver via LMTP or SMTP, this flag may be used to define the RCPT TOs used for delivery of each user specified with--user. If no recipients are provided, the RCPT TOs will match the username. (the pageβs heading gluesIfon the end too:--rcpt-to recipient-address(es)Ifπ)
NOTE: the recipient list should always be balanced with the user list, or empty. Specifying an unbalanced number of recipients to users will result in undefined behavior. π
--mail-from=sender-addressβ if DSPAM will be configured to deliver via LMTP or SMTP, this flag will set the MAIL FROM sent on delivery of the message. The default MAIL FROM depends on how the message was originally relayed to DSPAM. If it was relayed via the commandline, an empty MAIL FROM will be used. If it was relayed via LMTP, the original MAIL FROM will be used. (heading on the page:--mail-from=sender-addressIfπ)
π EXIT VALUE π
DSPAM keeps this part cute and simple:
0β operation was successful. slay. β¨otherβ operation resulted in an error. If the error involved an error in calling the delivery agent, the exit value of the delivery agent will be returned. π
Β© COPYRIGHT Β©
Copyright Β© 2002-2012 DSPAM Project
All rights reserved.
For more information, see http://dspam.sourceforge.net. π«Ά
π SEE ALSO π
dspam_admin(1)dspam_clean(1)dspam_crc(1)dspam_dump(1)dspam_logrotate(1)dspam_merge(1)dspam_stats(1)dspam_train(1)
mwah π this lil pageβs source/version is DSPAM, its date is Aug 14, 2010, and it lives in section DSPAM(1) β kbye bestie π«Άπ
π¦ where this page comes from
- nixos 26.05: dspam 3.10.2
- nixpkgs unstable: dspam 3.10.2
- Copyright (C) 2002-2012 DSPAM Project
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms