Mail client machines can also be greatly simplified using the mail hub model.
For example, you might determine that it is not necessary to run the SMTP daemon on client machines.
A simple cron job to check the queue periodically and process pending requests by sending them to the mail server for delivery may be all the client support your site requires.
For slightly more complicated scenarios, you may still need to build an SMTP daemon configuration file to control this process, and/or find a way to make the mail spool (on the server) available to the MUAs on mail clients.
confEIGHT_BIT_HANDLING : Enable 8-bit data handling.
confMAX_MESSAGE_SIZE : Maximum size of messages accepted (in bytes).
confMIME_FORMAT_ERRORS : Send error messages as MIME-encapsulated messages per RFC 1344.
confFORWARD_PATH : Colon-separated list of places to search for .forward files.
confLOG_LEVEL : Log level.
confPRIVACY_FLAGS : Privacy flags.
confTIME_ZONE : Zone info. Can be USE_SYSTEM to use the system’s idea, USE_TZ to use the user’s TZ environment variable, or something else to force that value.
confUNSAFE_GROUP_WRITES : If set, group-writable, :include: and .forward files are considered “unsafe.” That is, programs and files cannot be directly referenced from such files. World-writable files are always considered unsafe.
confDONT_BLAME_SENDMAIL : Override Sendmail’s file safety checks. This will definitely compromise system security and should not be used unless absolutely necessary.
confAUTH_MECHANISMS : List of authentication mechanisms for AUTH (separated by spaces). The advertised list of authentication mechanisms will be the intersection of this list and the list of available mechanisms as determined by the CYRUS SASL library.
use_cw_file : Reads the /etc/mail/sendmail.cw file to get a list of hosts the server will accept messages for.
use_ct_file : Reads the /etc/mail/trusted-users file to get the names of users that will be “trusted.”
stickyhost : This feature is sometimes used with LOCAL_RELAY , although it can be used for a different effect with MAIL_HUB .
When used with without MAIL_HUB , e-mail sent to [email_address] is marked as “sticky” and is not forwarded to LOCAL_RELAY . With MAIL_HUB , mail addressed to [email_address] is forwarded to the mail hub, with the envelope address remaining [email_address] . Without stickyhost , the envelope would be changed to [email_address] , in order to protect against mailing loops.
always_add_domain : Includes the local host domain even on locally delivered mail.
ldap_routing : Implements LDAP-based e-mail recipient routing according to the Internet Draft draft-lachman-laser-ldap-mail-routing-01 .
Nullclient : A special case. Creates a configuration file containing nothing but support for forwarding all mail to a central hub via a local SMTP-based network.
promiscuous_relay : By default, the Sendmail configuration files do not permit mail relaying (that is, accepting mail from outside your local host and sending it to a host other than your local hosts).
relay_entire_domain : By default, only hosts listed as RELAY in the access db will be allowed to relay.
relay_hosts_only : By default, names listed as RELAY in the access db are domain names, not host names.
relay_mail_from : Allows relaying if the mail sender is listed as RELAY in the access map.
relay_local_from : Allows relaying if the domain portion of the mail sender is a local host.
accept_unqualified_senders : Normally, MAIL FROM: commands in the SMTP session will be refused if the connection is a network connection and the sender address does not include a domain name.
accept_unresolvable_domains : Normally, MAIL FROM: commands in the SMTP session will be refused if the host part of the argument to MAIL FROM: cannot be located in the host name service (e.g., an A or MX record in DNS).
access_db : Turns on the access database feature.
blacklist_recipients : Turns on the ability to block incoming mail for certain recipient user names, host names, or addresses.
delay_checks : The rule sets check_mail and check_relay will not be called when, respectively, a client connects or issues a MAIL command.
dnsbl : Turns on rejection of hosts found in an DNS-based rejection list.
Rewrite rules read “tokens” and make decisions based on contents of the token stream. The left hand side of rewriting rules contains a pattern. Normal words are simply matched directly. Metasyntax is introduced using a dollar sign. The metasymbols are:
When the left hand side of a rewriting rule matches, the input is deleted and replaced by the right hand side. Tokens are copied directly from the RHS unless they begin with a dollar sign. Metasymbols are:
$n Substitute indefinite token n from LHS
$[name$] Canonicalize name
$(map key $@arguments $:default $)
Generalized keyed mapping function
$>n "Call" ruleset n
$#mailer Resolve to mailer
$@host Specify host
$:user Specify user
The $n syntax substitutes the corresponding value from a $+, $-, $*, $=, or $~ match on the LHS
Hosts that run an MTA daemon may be susceptible to another security problem.
An improperly configured mail server will allow anyone to connect to it, and send mail using the mail server as the “From:” address. Such servers are referred to as open (mail) relays.
People that generate and send spam mail messages often make use of open relays. The spammer finds a host that allows open relaying, creates the message to be sent, and uses the third-party mail server to send the message.
When people that received the spam start complaining, they send mail to the owner of the improperly configured mail server.
The owner of the mail server did not create the spam message, nor can he track where it came from, but he will certainly get a lot of fan mail from people that received the spam message!
Open relaying has been disabled in recent versions of the Sendmail MTA software, but the administrator has the ability to reenable this mode of operation.
Reenabling open relaying is strongly discouraged! Instead, look into building a version of Sendmail that authenticates users, and allows authorized users to relay mail via the mail server. This combats the spam problem in two ways.
First, the authentication step logs the name of the user that authenticated. This allows the administrator to track who generated any spam mail that does get relayed through the site.
The authentication step also combats spam by requiring the user to authenticate in order to use the MTA to relay messages. This prevents users that do not have a valid log-in/password on the mail server from accessing the mail system.
On personal computers, content-based attacks (in the form of viruses and other malicious software) is a security issue.
A mail client can help or hinder efforts to defend against these problems.
Like other Internet software mail clients, MUAs need to be robust in the face of malformed input data.
Mail clients that have tightly integrated scripting functions have been used to launch attacks from infected personal computers.
Mail clients should be configurable to prevent the execution of embedded scripts, viewing of HTML attachments, and execution of attachments found in incoming messages.
WARNING: Microsoft’s Outlook and Outlook Express have a long history of poor security and have been the vectors of infection for a large number of viruses and other malware. The tight integration of scripting in Outlook is frequently exploited to reach beyond the individual PC and spread the infection to other systems.
System administrators of mail servers should be aware of a few ancillary e-mail tools that may be of help in their environment.
procmail : The procmail filter is the default delivery agent on some UNIX variants, such as Red Hat Linux. It reads a rule set that can filter mail messages in a variety of ways. procmail is often used to pass e-mail through other filtering programs.
spamassassin : One of the best tools for identifying those annoying and unwanted commercial e-mails or SPAM. spamassissin uses several methods to attempt to identify a message as SPAM. It can be run several ways, including via procmail .
fetchmail : fetchmail is a batch-oriented, command line POP and IMAP client. It is useful for situations in which noninteractive access to a mail server is needed.