Commit 6ac1b641 authored by IKEDA Soji's avatar IKEDA Soji
Browse files

[change] Documentation in smtpc.1.md instead of smtpc.1 man page.

parent d538c6c9
......@@ -9,9 +9,9 @@ smtpc_SOURCES = \
sockstr.h \
utf8.c \
utf8.h
man1_MANS = smtpc.1
dist_doc_DATA = smtpc.1.md
EXTRA_DIST = configure.gnu smtpc.1.in
EXTRA_DIST = configure.gnu
CLEANFILES = $(bin_PROGRAMS) *~ *.bak core.*
smtpc.o: sockstr.h utf8.h
......
......@@ -46,5 +46,5 @@ AC_CHECK_FUNC([getaddrinfo], [],
fi
AC_CONFIG_FILES([Makefile smtpc.1])
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
.TH SMTPC 1 "" "@VERSION@" "@PACKAGE_STRING@"
.SH NAME
smtpc \- SMTP / LMTP client
.SH SYNOPSIS
smtpc --esmtp \fIhost\fR:\fIport\fR -f \fIenvelope@sen.der\fR
[ \fIoptions\fR... ] [ -- ] \fIrecipient@add.ress\fR ...
smtpc --lmtp \fIhost\fR:\fIport\fR -f \fIenvelope@sen.der\fR
[ \fIoptions\fR... ] [ -- ] \fIrecipient@add.ress\fR ...
smtpc --lmtp \fIpath\fR -f \fIenvelope@sen.der\fR
[ \fIoptions\fR... ] [ -- ] \fIrecipient@add.ress\fR ...
.SH DESCRIPTION
\fBsmtpc\fP is an email client.
It reads a message from standard input and submits it to email server through
socket.
.SS Options
Any options not listed here are silently ignored.
.TP
\fB--dump\fP
Show dialog in the session.
.TP
\fB--esmtp\fP \fIhost\fR[:\fIport\fR]
Uses TCP socket and ESMTP protocol to submit message.
Either this option or \fB--lmtp\fP option is required.
If \fIhost\fR is the IPv6 address, it must be enclosed in [...]
to avoid confusion with colon separating \fIhost\fR and \fIport\fR,
e.g. "[::1]", "[::1]:587".
If \fIport\fR is omitted, "25" is used.
.TP
\fB-f\fP \fIenvelope@sen.der\fR, \fB-f\fP\fIenvelope@sen.der\fR
Specifys envelope sender.
This option is required.
To specify "null envelope sender", use a separate empty argument or "<>".
.TP
\fB--iam\fP \fIhost.name\fR
Specifys host name or IP address literal used in EHLO or LHLO request.
Default is "localhost".
.TP
\fB--lmtp\fP \fIhost\fR[:\fIport\fR], \fB--lmtp\fP \fIpath\fR
Uses TCP or Unix domain socket and LMTP protocol to submit message.
Either this option or \fB--esmtp\fP option is required.
If \fIport\fR is omitted, "24" is used.
\fIpath\fR must be full path to socket file.
.TP
\fB-N\fP \fIdsn\fR, \fB-N\fP\fIdsn\fR
Controls delivery status notification.
\fIdsn\fR may be single word "NEVER" or one or more of words "SUCCESS",
"FAILURE" and "DELAY" separated by comma.
If this option is not given, delivery status notification will be controlled
by server.
.TP
\fB--smtputf8\fP
Enables support for SMTPUTF8 extension.
\fBsmtpc\fR detects valid UTF-8 sequence in envelope and message header,
then requests this extension as neccessity.
.TP
\fB-V\fP \fIenvid\fR, \fB-V\fP\fIenvid\fR
Specifys envelope ID.
.TP
\fB--verbose\fP
Output the last response from the server to standard output.
.TP
\fB--\fP
Terminates options.
Remainder of command line arguments are considered to be recipient addresses,
even if any of them begin with "-".
.TP
\fIrecipent@add.ress\fR ...
Recipients to whom the message would be delivered.
At least one recipient is required.
.SS Exit status
.TP
\fB0\fR
Message was successfully submitted.
.TP
\fB253\fR
Message was rejected by server.
.TP
\fB254\fR
The server returns malformed or illegal response.
.TP
\fB255\fR
Network error occurred.
.SS "SMTP extensions"
\fBsmtpc\fR supports following extensions.
.TP
\fB8-bit MIME Transport\fR (RFC 6152)
\fBsmtpc\fR requests this extension if message contains octets with high bit.
.TP
\fBDelivery Status Notification\fR (RFC 3461)
\fBsmtpc\fR issues ORCPT parameters.
See also \fB-N\fR and \fB-V\fR options.
.TP
\fBInternationalized Email\fR (RFC 6531)
Experimentally supported.
See \fB--smtputf8\fR option.
.TP
\fBMessage Size Declaration\fR (RFC 1870)
Estimated size of the message is informed to the server.
.SH LIMITATIONS
\fBsmtpc\fR provides the feature of SMTP / LMTP client submitting messages
to particular server.
It will never provide extensive features such as message queuing, retry after
temporary failure, routing using MX DNS record and so on.
Once the server rejects delivery, \fBsmtpc\fR exits and message is discarded.
.SH KNOWN BUGS
.TP 2
*
If NUL octets (\\0) are included in messages, they are transmitted to the
server.
.SH "SEE ALSO"
sendmail(1)
.SH HISTORY
\fBsmtpc\fP was initially written for Sympa project by
IKEDA Soji <ikeda@conversion.co.jp>.
%SMTPC(1)
# NAME
smtpc - SMTP / LMTP client
# SYNOPSIS
`smtpc` `--esmtp` _host_`:`_port_ `-f` _envelope_@_sen.der_
[ _options_... ] [ `--` ] _recipient_@_add.ress_ ...
`smtpc` `--lmtp` _host_`:`_port_ `-f` _envelope_@_sen.der_
[ _options_... ] [ `--` ] _recipient_@_add.ress_ ...
`smtpc` `--lmtp` _path_ `-f` _envelope_@_sen.der_
[ _options_... ] [ `--` ] _recipient_@_add.ress_ ...
# DESCRIPTION
**smtpc** is an email client.
It reads a message from standard input and submits it to email server through
socket.
## Options
Any options not listed here are silently ignored.
* `--dump`
Show dialog in the session.
* `--esmtp` _host_[:_port_]
Uses TCP socket and ESMTP protocol to submit message.
Either this option or `--lmtp` option is required.
If _host_ is the IPv6 address, it must be enclosed in [...]
to avoid confusion with colon separating _host_ and _port_,
e.g. "`[::1]`", "`[::1]:587`".
If _port_ is omitted, "25" is used.
* `-f` _envelope_@_sen.der_, `-f`_envelope_@_sen.der_
Specifys envelope sender.
This option is required.
To specify "null envelope sender", use a separate empty argument or "`<>`".
* `--iam` _host.name_
Specifys host name or IP address literal used in EHLO or LHLO request.
Default is "`localhost`".
* `--lmtp` _host_[:_port_], `--lmtp` _path_
Uses TCP or Unix domain socket and LMTP protocol to submit message.
Either this option or `--esmtp` option is required.
If _port_ is omitted, "24" is used.
_path_ must be full path to socket file.
* `-N` _dsn_, `-N`_dsn_
Controls delivery status notification.
_dsn_ may be single word "`NEVER`" or one or more of words "`SUCCESS`",
"`FAILURE`" and "`DELAY`" separated by comma.
If this option is not given, delivery status notification will be controlled
by server.
* `--smtputf8`
Enables support for SMTPUTF8 extension.
**smtpc** detects valid UTF-8 sequence in envelope and message header,
then requests this extension as neccessity.
* `-V` _envid_, `-V`_envid_
Specifys envelope ID.
* `--verbose`
Output the last response from the server to standard output.
* `--`
Terminates options.
Remainder of command line arguments are considered to be recipient
addresses, even if any of them begin with "`-`".
* _recipent_@_add.ress_ ...
Recipients to whom the message would be delivered.
At least one recipient is required.
## Exit status
* `0`
Message was successfully submitted.
* `253`
Message was rejected by server.
* `254`
The server returns malformed or illegal response.
* `255`
Network error occurred.
## SMTP extensions
**smtpc** supports following extensions.
* **8-bit MIME Transport** (RFC 6152)
**smtpc** requests this extension if message contains octets with high bit.
* **Delivery Status Notification** (RFC 3461)
**smtpc** issues ORCPT parameters.
See also `-N` and `-V` options.
* **Internationalized Email** (RFC 6531)
Experimentally supported.
See `--smtputf8` option.
* **Message Size Declaration** (RFC 1870)
Estimated size of the message is informed to the server.
# LIMITATIONS
**smtpc** provides the feature of SMTP / LMTP client submitting messages
to particular server.
It will never provide extensive features such as message queuing, retry after
temporary failure, routing using MX DNS record and so on.
Once the server rejects delivery, **smtpc** exits and message is discarded.
# KNOWN BUGS
* If NUL octets (\\0) are included in messages, they are transmitted to the
server.
# SEE ALSO
sendmail(1)
# HISTORY
**smtpc** was initially written for Sympa project by
IKEDA Soji <ikeda@conversion.co.jp>.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment