diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2021-06-17 16:46:13 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2021-06-17 16:46:13 +0300 |
commit | 6fa210d16195ba4448648e171bb053d3b49fa095 (patch) | |
tree | 0700b62bfd5e5716ebf6e1313ec01b4cfb0c1d3b /mockmta.1 | |
parent | c3a3d811d674b7fac0355253a5bd4c481e687a83 (diff) | |
download | mockmta-6fa210d16195ba4448648e171bb053d3b49fa095.tar.gz mockmta-6fa210d16195ba4448648e171bb053d3b49fa095.tar.bz2 |
* README: Update.
* configure.ac: New option --with-tcp-wrappers
* mockmta.1: Document changes.
* mockmta.c (port): Replace with portstr.
(sockaddr_str, address_parse): New functions.
(tcpwrap_access): New function.
(mta_open): Take struct addrinfo * as argument.
(thr_mta_listener): Verify connection using TCP wrappers and
log the peer's IP address.
(main): Likewise (for inetd mode).
New option -s. Use syslog if it is given.
(version): Report whether libwrap is used.
Diffstat (limited to 'mockmta.1')
-rw-r--r-- | mockmta.1 | 33 |
1 files changed, 25 insertions, 8 deletions
@@ -1,21 +1,21 @@ -.TH MOCKMTA 1 "June 16, 2021" "MOCKMTA" "General Commands Manual" +.TH MOCKMTA 1 "June 17, 2021" "MOCKMTA" "General Commands Manual" .SH NAME mockmta \- mock MTA server for experimental purposes .SH SYNOPSIS \fBmockmta\fR\ - [\fB\-dv?\fR]\ + [\fB\-dsv?\fR]\ [\fB\-c \fICERT\fR]\ [\fB\-a \fICA\fR]\ [\fB\-k \fIKEY\fR]\ [\fB\-l \fILEVEL\fR]\ [\fB\-P \fIFILE\fR]\ - [\fB\-p \fIPORT\fR]\ + [\fB\-p [\fIIP\fB:\fR]\fIPORT\fR]\ [\fB\-t \fISEC\fR]\ \fIMAILBOX\fR .SH DESCRIPTION Starts a mock MTA, which behaves almost identically to the real one, -except that it listens on localhost only and delivers all messages, no -matter their actual recipients, to the given MAILBOX file. +except that it delivers all messages, no matter their actual +recipients, to the given MAILBOX file. .PP No attempts are made to interpret the data supplied during the STMP transaction, such as domain names, email addresses, etc, neither is @@ -35,7 +35,16 @@ daemon. The inetd mode can be used with \fBGNU pies\fR as follows: .EE .PP When run as a daemon, \fBmockmta\fR starts listening on localhost port -\fIPORT\fR (default 25). +25 by default. Alternative port and/or IP address can be requested +using the \fB\-p\fR option. +.PP +Each incoming connection is verified using +.B /etc/hosts.allow +and +.B /etc/hosts.deny +files (daemon name \fBmockmta\fR). See +.BR hosts_access (5), +for a detailed description of these. .PP To support TLS, the program must be compiled with the \fBGnuTLS\fR library. .PP @@ -75,8 +84,14 @@ Default is \fBinfo\fR. \fB\-P \fIFILE\fR Write PID of the daemon process to \fIFILE\fR (with \fB\-d\fR or \fB\-f\fR). .TP -\fB\-p \fIPORT\fR -Listen on this port. +\fB\-p [\fIIP\fB:\fR]\fIPORT\fR +Listen on this IP address and port. If \fIIP\fR is not given, listen +on localhost. To listen on all available interfaces, use +\fB\-p :\fIPORT\fR. +.TP +.B \-s +Use syslog (facility \fBmail\fR) for logging. This is the default if +\fB\-d\fR or \fB\-f\fR option is given. .TP \fB\-t \fISEC\fR Set SMTP timeout. @@ -101,6 +116,8 @@ Timed out waiting for I/O. Command line usage error. .SH BUGS At most 32 \fBRCPT\fR commands are allowed. +.SH SEE ALSO +.BR hosts_access (5). .SH AUTHOR Sergey Poznyakoff <gray@gnu.org> .SH LICENSE |