Managing spam
Unsolicited email, or ``spam'', is an increasing problem on
the Internet. You can use anti-spam rulesets to:
Currently, anti-spam features cannot be enabled with the SCOadmin Sendmail Configuration Manager, mkdev cf, or the Internet Manager's mail configuration options. With the exception of check_rcpt, modifications made to /usr/lib/sendmail.cf to enable anti-spam features are not preserved across successive executions of these configuration utilities. Be sure to save your changes to /usr/lib/sendmail.cf so that you can re-enable the anti-spam features should you run one of the sendmail configuration utilities.
Those sending spam mail often try to use an intermediate system in an attempt to hide the source of electronic mail. The check_rcpt ruleset prevents your site from being used as an intermediate site between a sender and a recipient.
To implement check_rcpt:
The class R, defined by entries in the file /usr/lib/mail/antispam/sendmail.cR, allows additional relays not defined in the relays map. You must also have DD and Cw defined for this ruleset to function properly.
The relays file (/usr/lib/mail/antispam/relays), used by the the check_rcpt ruleset, specifies those sites and IP numbers that are allowed to use this site as an intermediate relay.
Add entries to the file using this <Tab>-separated format:
address OKaddress is either the fully-qualified domain name or the IP number of the site that is allowed to use this one as an intermediate relay. The fields must be <Tab>-separated, and the
OK entry is required.
For example, to allow the site bomb20.pdev.sco.com to use this site as an intermediate relay, add the following line to the file:
bomb20.pdev.sco.com OK
This example shows a specific IP number:
10.0.67.15 OK
After adding or deleting entries from this file, rebuild the relays map:
This ruleset prevents mail from being sent from a pre-defined list of fully qualified domain names and/or IP numbers, regardless of recipient.
To implement this feature:
The spammers file (/usr/lib/mail/antispam/spammers), used by the check_relay or check_mail rulesets, identifies systems from which mail will be rejected.
Add entries to the file using this <Tab>-separated format:
address messageaddress is either the fully qualified domain name or the IP number of the site from which this system will refuse mail. message is the error message to be sent back to the sender. For example, to refuse mail from the machines bomb20.pdev.sco.com and the machine at IP address 10.0.67.15, you might add these entries:
bomb20.pdev.sco.com Mail rejected, contact postmaster@mydomain.com 10.0.67.15 Mail rejected, contact postmaster@mydomain.comNote that the error message is only used by check_mail, not check_relay. However, a string must always exist on the right hand side of this file regardless of which ruleset uses it.
After editing this file, rebuild the spammers map:
This ruleset requires that the domain of the sender specified in the "Mail From:" SMTP command resolves to a valid fully-qualified DNS domain name. Additionally, the client making the connection to the local SMTP server is checked against a pre-defined list of fully qualified domain names.
To implement this feature:
Use check_compat to prevent mail from being sent from a pre-defined list of domain names or email addresses to a specified list of recipients. For example, you may use this ruleset for preventing all mail from any user in domain foobar.com from being sent to any user in domain barfoo.com, but still allow mail from users in foobar.com to be sent to users in other domains. This is useful for combating individual spam attacks from individual sites to a specific set of users or domains.
To implement this feature:
The spammers2 file (/usr/lib/mail/antispam/spammers2), used by the check_compat ruleset, specifies those addresses that are to be considered as potential spammers against those addresses in the protected map.
Add entries to the file using this <Tab>-separated format:
address SPAMMERaddress is the user name, system name, or domain name which is considered a source of spam mail. For example, if mail from all users in isendspam.com are to be considered generators of spam mail, enter:
isendspam.com SPAMMERThis will mark as a potential spam attack all mail from all users in the domain isendspam.com, as well as all of its subdomains such as machine1.isendspam.com and machine1.subdom.isendspam.com are all considered possible spam.
To specify an individual user instead, enter their individual addresses:
chris@sendyouspam.com SPAMMERThis marks chris@sendyouspam.com as a potential spam generator, but does not affect mail from other users in sendyouspam.com.
All entries must contain the string SPAMMER
on the right hand side.
After editing this file, rebuild the spammers2 map:
Because you can block whole domains from access to your protected users, you may also exclude valid e-mail addresses. In this case, it is best to target individual addresses in the spammers2 file.
The protected users file (/usr/lib/mail/antispam/protected), used by the check_compat ruleset, specifies those addresses that are to be considered 'protected' from spam attacks by the addresses in the spammers2 map.
Add entries to the file using this <Tab>-separated format:
address PROTECTEDaddress is the user name, system name, IP address, or domain name which is considered protected. For example, if mail to all users in foobar.com are protected, enter the line:
foobar.com PROTECTEDThis will mark as protected all mail to all users in the domain foobar.com, as well as its subdomains such as machine1.foobar.com, and machine1.subdom.foobar.com.
To protect individual users rather than entire domains, enter their individual addresses:
chris PROTECTED chris@foobar.com PROTECTEDThis marks as protected the local user chris and the address chris@foobar.com, but leaves as unprotected all other local users and all other users in the domain foobar.com.
All entries must contain the string PROTECTED
on the right hand side.
After editing this file, rebuild the protected map: