Poster of Linux kernelThe best gift for a Linux geek
masqmail

masqmail

Section: Maintenance Commands (8) Updated: 2010-07-14
Local index Up

 

NAME

masqmail - An offline Mail Transfer Agent

 

SYNOPSIS

/usr/sbin/masqmail [-C file] [-odq] [-bd] [-qinterval]

/usr/sbin/masqmail [-odq] [-bs]

/usr/sbin/masqmail [-bp]

/usr/sbin/masqmail [-q]

/usr/sbin/masqmail [-qo [name]]

/usr/sbin/masqmail [-odq] [-g [name]]

/usr/sbin/masqmail [-odq] [-go [name]]

/usr/sbin/masqmail [-t] [-oi] [-f address] [--] address...

/usr/sbin/mailq

 

DESCRIPTION

Masqmail is a mail server designed for hosts that do not have a permanent internet connection e.g. a home network or a single host at home. It has special support for connections to different ISPs. It replaces sendmail or other MTAs such as qmail or exim. It can also act as a POP3 client (if this functionality has not been disabled at build configuration time).

 

OPTIONS

Since masqmail is intended to replace sendmail, it uses the same command line options, but not all are implemented. There are also two additional options, which are unique to masqmail (-qo connection and -g)

--

Not a `real' option, it means that all following arguments are to be understood as arguments and not as options even if they begin with a leading dash `-'. Mutt is known to call sendmail with this option.

-bd

Run as daemon, accepting connections, usually on port 25 if not configured differently. This is usually used in the startup script at system boot and together with the -q option (see below).

-bi

Old sendmail rebuilds its alias database when invoked with this option. Masqmail ignores it. Masqmail reads directly from the file given with `alias_file' in the config file.

-bp

Show the messages in the queue. Same as calling masqmail as `mailq'.

-bs

Accept SMTP commands from stdin. Some mailers (e.g. pine) use this option as an interface. It can also be used to call masqmail from inetd.

-B arg

arg is usually 8BITMIME. Some mailers use this to indicate that the message contains characters > 127. Masqmail is 8-bit clean and ignores this, so you do not have to recompile elm, which is very painful ;-). Note though that this violates some conventions: masqmail does not convert 8 bit messages to any MIME format if it encounters a mail server which does not advertise its 8BITMIME capability, masqmail does not advertise this itself. This is the same practice as that of exim (but different to sendmail).

-bV

Show version information.

-C filename

Use another configuration than /etc/masqmail/masqmail.conf. Useful for debugging purposes. If not invoked by a privileged user, masqmail will drop all privileges.

-d number

Set the debug level. This takes precedence before the value of `debug_level' in the configuration file. Read the warning in the description of the latter.

-f [address]

Set the return path address to address. Only root, the user mail and anyone in group mail is allowed to do that.

-F [string]

Set the full sender name (in the From: header) to string.

-g [name]

Get mail (using pop3 or apop), using the configurations given with get.name in the main configuration. Without name, all get configurations will be used. See also masqmail.get(5)

-go [interval] [name]

Can be followed by a connection name. Use this option in your script which starts as soon as a link to the internet has been set up (usually ip-up). When masqmail is called with this option, the specified get configuration(s) is(are) read and mail will be retrieved from servers on the internet. The name is defined in the configuration (see online_gets.name).

If called with an interval option (recognized by a digit as the first characater), masqmail starts as a daemon and tries to get mail in these intervals. It checks for the online status first. Example: `masqmail -go 5m' will retrieve mail every five minutes.

If called without name, the online status is determined with the configured method (see online_detect in masqmail.conf(5)).

-i

Same as -oi, see below.

-Mrm list

Remove given messages from the queue. Only allowed for privileged users. The identifiers of messages are listed in the output of masqmail -bp (mailq).

-oem

If the -oi ist not also given, always return with a non zero return code. Maybe someone tells me what this is good for...

-odb

Deliver in background. Masqmail always does this, which makes this option pretty much useless.

-odq

Do not attempt to deliver immediately. Any messages will be queued until the next queue running process picks them up and delivers them. You get the same effect by setting the do_queue option in /etc/masqmail/masqmail.conf.

-oi

A dot as a single character in a line does not terminate the message.

-q [interval]

If not given with an argument, run a queue process, i.e. try to deliver all messages in the queue. Masqmail sends only to those addresses that are on the local net, not to those that are outside. Use -qo for those.

If you have configured inetd to start masqmail, you can use this option in a cron job which starts in regular time intervals, to mimic the same effect as starting masqmail with -bd -q30m.

An argument may be a time interval i.e. a numerical value followed by one of the letters. s,m,h,d,w which are interpreted as seconds, minutes, hours, days or weeks respectively. Example: -q30m. Masqmail starts as a daemon and a queue runner process will be started automatically once in this time interval. This is usually used together with -bd (see above).

-qo [name]

Can be followed by a connection name. Use this option in your script which starts as soon as a link to the internet has been set up (usually ip-up). When masqmail is called with this option, the specified route configuration is read and the queued mail with destinations on the internet will be sent. The name is defined in the configuration (see online_routes.name).

If called without name the online status is determined with the configured method (see online_detect in masqmail.conf(5))

-t

Read recipients from headers. Delete `Bcc:' headers. (Since 0.2.25, masqmail deletes Bcc: headers in all cases.) If any arguments are given, these are interpreted as recipient addresses and the message will not be sent to these, although they might appear in To:, Cc:, or Bcc: headers. I.e. the set of argument recipients is ``substracted'' from the set of header recipients.

This behavior is similar to exim's and smail's. Postfix, in contrast, adds the arguments to the set of header recipients. Sendmail seems to behave differently, depending on the version. See exim(8) for further information.

-v

Log also to stdout. Currently, some log messages are marked as `write to stdout' and additionally, all messages with priority `LOG_ALERT' and `LOG_WARNING' will be written to stdout if this option is given. It is disabled in daemon mode.

 

ENVIRONMENT FOR PIPES AND MDAS

For security reasons, before any pipe command from an alias expansion or an mda is called, the environment variables will be completely discarded and newly set up. These are:

SENDER, RETURN_PATH - the return path.

SENDER_DOMAIN - the domain part of the return path.

SENDER_LOCAL - the local part of the return path.

RECEIVED_HOST - the host the message was received from (unless local).

LOCAL_PART, USER, LOGNAME - the local part of the (original) recipient.

MESSAGE_ID - the unique message id. This is not necessarily identical with the Message ID as given in the Message ID: header.

QUALIFY_DOMAIN - the domain which will be appended to unqualified addresses.

 

FILES

/etc/masqmail/masqmail.conf is the main configuration for masqmail. Depending on the settings in this file, you will also have other configuration files in /etc/masqmail/.

/var/spool/masqmail/ is the spool directory where masqmail stores its spooled messages and the uniq pop ids.

/var/spool/mail/ is the directory where locally delivered mail will be put, if not configured differently in masqmail.conf.

/var/log/masqmail/ is the directory where masqmail stores its log mesages. This can also be somewhere else if configured differently by your sysadmin or the package mantainer.

 

CONFORMING TO

RFC 821, 822, 1869, 1870, 2197, 2554 (SMTP)

RFC 1725, 1939 (POP3)

RFC 1321 (MD5)

RFC 2195 (CRAM-MD5)

 

AUTHOR

Masqmail was written by Oliver Kurth. It is now maintained by Markus Schnalke <meillo@marmaro.de>.

You will find the newest version of masqmail at http://marmaro.de/prog/masqmail/. There is also a mailing list, you will find information about it at masqmail's main site.

 

BUGS

Please report them to the mailing list.

 

SEE ALSO

masqmail.conf(5), masqmail.route(5), masqmail.get(5), masqmail.aliases(5)


 

Index

NAME
SYNOPSIS
DESCRIPTION
OPTIONS
ENVIRONMENT FOR PIPES AND MDAS
FILES
CONFORMING TO
AUTHOR
BUGS
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 22:01:57 GMT, April 16, 2011