SSMTP(8)
π SSMTP(8) π β the send-only sendmail emulator, explained by your bestie
okay so this whole page comes from the System Manager's Manual (section 8, the sysadmin one, iykyk) and it covers two names living one life: ssmtp and sendmail. same energy, one manual. let's get into it. π«Ά
π NAME π
ssmtp, sendmail β send a message using smtp. that's the whole job, and honestly? it eats. π
πΈ SYNOPSIS πΈ
ssmtp [ flags ] [ address ... ]
/usr/lib/sendmail [ flags ] [ address ... ]
β¨ DESCRIPTION β¨
okay so ssmtp is a send-only sendmail emulator β it sends, it never receives, and it's built for machines that normally go pick their mail up from a centralized mailhub (via pop, imap, nfs mounts, or whatever other means you've got going on). it gives you exactly the functionality that humans and programs need in order to send mail through the standard user agents or through /usr/bin/mail. chef's kiss. π
how it actually works: it takes a mail stream on standard input, you pass the recipients on the command line, and it synchronously forwards the message to the mail transfer agent of a mailhub, which then processes it. and if a message fails? it lands in dead.letter in the sender's home directory. π tuck that knowledge in your pocket.
the config files let you set: the address that receives mail from root, daemon, etc.; a default mailhub; a default domain to be used in From: lines; and per-user From: addresses and mailhub names. so much control, so little drama.
now for the real talk, bestie: it does not attempt to provide all the functionality of sendmail. it's intended for use where other programs are the primary means of mail delivery. it's useful with pop/imap, or to simulate the Sun shared mail spool option for non-Sun machines, for machines whose sendmails are too difficult (or too various) to configure, for machines with known disfeatures in their sendmails, or for ones where there are ``mysterious problems''. π we've all met that machine.
it does not do aliasing β that has to happen either in the user agent or on the mailhub. it also does not honor .forwards, because those have to be done on the receiving host. and it especially does not deliver to pipelines. not now, not ever. periodt. π
π OPTIONS π
most sendmail options are just... irrelevant to sSMTP, bestie. here's the decoder ring:
- marked
ignored'' ordefault'' β no effect on mail transfer - marked ``unsupported'' β fatal errors π
- marked ``simulated'' β not errors, but the result is that the program exits with an informative message. a sort of fatal non-error. make it make sense, but that's canon.
-4β forces ssmtp to use IPv4 addresses only.-6β forces ssmtp to use IPv6 addresses only.-Bbody_typeβ (ignored) the message body MIME type:7BITor8BITMIME.-auusernameβ specifies the username for SMTP authentication.-appasswordβ specifies the password for SMTP authentication.-ammechanismβ specifies the mechanism for SMTP authentication. onlyLOGINandCRAM-MD5, bestie, don't get creative.-baβ (unsupported) ARPANET mode. all input lines must end with a LINEFEED, and all messages will be generated with a CR-LF at the end. also, theFrom:'' andSender:'' fields are examined for the name of the sender.-bdβ (unsupported) run as a daemon.-biβ (ignored) initialise the alias database.-bmβ (default) deliver mail in the usual way.-bpβ (simulated) print a summary of the mail queue.-bsβ (unsupported) read SMTP commands from stdin.-btβ (unsupported) run in address test mode.-bvβ (unsupported) verify names only.-bzβ (unsupported) create the configuration freeze file.-Cfileβ use alternate configuration file.-dXβ set debugging value toX.-Eβ (ignored) don't trust the userid of the sender.-Ffullnameβ set the full name of the sender.-fnameβ sets the name of the ``from'' person. this option is valid only if noFrom:line is specified within the header of the email.-hNβ (ignored) set the hop count toN.-mβ (ignored) ignore originator in alias.-Midβ (ignored) attempt to deliver the queued message with message-idid.-Ndsnβ (ignored) set delivery status notification conditions todsn.-nβ (default) do not do aliasing.-oAfileβ (ignored) use alternate alias file.-ocβ (ignored) delay ``expensive'' connections.-odxβ (ignored) set the delivery mode to interactive/synchronous, background or queue (always interactive).-oDβ (ignored) runnewaliasesif required.-oexβ (ignored) set error processing to mail, write, print or quit (always print).-oFmodeβ (ignored) the mode to use when creating temporary files.-ofβ (ignored) save UNIX-system-style ``From'' lines at the front of messages.-ogNβ (ignored) set group ID to use when calling mailers.-oHfileβ (ignored) set SMTP help file.-oiβ (default) do not take dots on a line by themselves as a message terminator.-oLnβ (ignored) the log level.-omβ (default) send to ``me'' (the sender) also if in an alias.-ooβ (unsupported) if set, this message may have old style headers.-oQqueuedirβ (ignored) select the directory in which to queue messages.-ortimeoutβ (ignored) the timeout on reads.-oSfileβ (ignored) save statistics in the named file.-osβ (ignored) always instantiate the queue.-oTtimeβ (ignored) set timeout on messages.-otstz,dtzβ (ignored) set the name of the time zone.-ouNβ (ignored) set the default user id for mailers.-q[time]β (simulated) process the queue.-rnameβ same as-f.-Rstringβ (ignored) process queue for recipient.-Rreturnβ (ignored) set the amount of the message to be returned if the message bounces.-tβ read message, searching for recipients.To:'', `Cc:'', andBcc:'' lines will be scanned for people to send to. any addresses in the argument list will be suppressed (not supported).-vβ go into verbose mode.-Vβ say version and quit.
π¦ REVERSE ALIASES π¦
a reverse alias gives you the From: address that gets placed on a user's outgoing messages, and (optionally) the mailhub those messages will be sent through. example:
root:jdoe@isp.com:mail.isp.com
so, messages that root sends will be identified as from jdoe@isp.com and sent through mail.isp.com. clean, simple, iconic. β¨
π FILES π
/etc/ssmtp/ssmtp.confβ configuration file/etc/ssmtp/revaliasesβ reverse aliases file
π SEE ALSO π
RFC821, RFC822, ssmtp.conf(5). go read those too, bestie, for the full lore. π
π AUTHORS π
- Matt Ryan (
mryan@debian.org) - Hugo Haas (
hugo@debian.org) - Christoph Lameter (
clameter@debian.org) - Dave Collier-Brown (
davecb@hobbes.ss.org)
absolute legends, every single one. π«Ά
π BUGS π
- sSMTP does not support exception lists to the
-toption (never seen it used). - sSMTP will fail if the mailhub is unreachable. π yes, really, that's the whole bug.
ngl, this page was last changed on 4 February 2005, and it ships as part of the System Manager's Manual for SSMTP(8). vintage, but make it fashion. π
π¦ where this page comes from
- ubuntu stonking: ssmtp 2.66-1build1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms