Commit 65b595d1 65b595d1b4e0303c29baffcf04e3771ee98d15f7 by Sergey Poznyakoff

Update docs

1 parent 88dea10c
...@@ -294,7 +294,6 @@ Configuring @command{comsatd} ...@@ -294,7 +294,6 @@ Configuring @command{comsatd}
294 294
295 * General Settings:: 295 * General Settings::
296 * Security Settings:: 296 * Security Settings::
297 * Access Control Lists::
298 297
299 @acronym{MH} --- The MH Message Handling System 298 @acronym{MH} --- The MH Message Handling System
300 299
......
...@@ -6097,13 +6097,22 @@ either from @file{inetd.conf} or as a standalone daemon. ...@@ -6097,13 +6097,22 @@ either from @file{inetd.conf} or as a standalone daemon.
6097 @FIXME-xref{daemon}, @FIXME-xref{logging}. 6097 @FIXME-xref{daemon}, @FIXME-xref{logging}.
6098 6098
6099 @table @option 6099 @table @option
6100 @item -c @var{file} 6100 @item -C @var{file}
6101 @itemx --config @var{file} 6101 @itemx --convert-config=@var{file}
6102 Read configuration from given @var{file}. For more information about 6102 Convert the configuration file @var{file} to the new
6103 comsatd configuration files, see @ref{Configuring comsatd}. 6103 format. @var{File} must be a @command{comsatd} configuration file in
6104 Mailutils v. 1.x format. The converted file is printed on the standard
6105 output. For example, the following command can be used to convert old
6106 @command{comsatd} configuration file to new format:
6107
6108 @smallexample
6109 $ comsatd --convert-config=/etc/comsatd.conf > /etc/mailutils.d/comsatd
6110 @end smallexample
6111
6104 @item -d 6112 @item -d
6105 @itemx --daemon 6113 @itemx --daemon
6106 Run as a standalone daemon. 6114 Run as a standalone daemon.
6115
6107 @item -i 6116 @item -i
6108 @itemx --inetd 6117 @itemx --inetd
6109 The server is started from @file{/etc/inetd.conf} file: 6118 The server is started from @file{/etc/inetd.conf} file:
...@@ -6114,129 +6123,79 @@ comsatd -c /etc/comsat.conf ...@@ -6114,129 +6123,79 @@ comsatd -c /etc/comsat.conf
6114 @end smallexample 6123 @end smallexample
6115 6124
6116 This is the default operation mode. 6125 This is the default operation mode.
6117 @item -m @var{path} 6126
6118 @itemx --mail-spool=@var{path} 6127 @item -t
6119 Set path to the mailspool directory 6128 @itemx --test
6120 @item -p @var{number} 6129 Test mode. In this mode, @command{comsatd} takes two arguments:
6121 @itemx --port @var{number} 6130 @acronym{URL} of a mailbox and @acronym{QID} of the message from that
6122 Specify the port number to listen on. Default is 512. 6131 mailbox, e.g.:
6123 @item -v 6132
6124 @itemx --version 6133 @smallexample
6125 Output version and exit successfully. 6134 $ comsatd --test /var/mail/root 34589
6126 @item -h 6135 @end smallexample
6127 @itemx --help 6136
6128 Display short help message and exit.
6129 @end table 6137 @end table
6130 6138
6131 @node Configuring comsatd 6139 @node Configuring comsatd
6132 @subsection Configuring @command{comsatd} 6140 @subsection Configuring @command{comsatd}
6133 6141
6134 The configuration parameters for @command{comsatd} are kept in a single 6142 Following configuration statements affect the behavior of
6135 configuration file. The file uses line-oriented format: each line 6143 @command{comsatd}:
6136 contains a single statement. Comments are introduced with the @samp{#}
6137 sign and empty lines are ignored. You can specify the configuration
6138 file to use by using @option{-c} or @option{--config} command line switch.
6139 6144
6140 The configuration file statements can logically be subdivided into 6145 @multitable @columnfractions 0.3 0.6
6141 @dfn{General Settings}, @dfn{Security Settings} and @dfn{Access Control 6146 @headitem Statement @tab Reference
6142 Lists}. The following sections address each of these statement group in 6147 @item debug @tab @xref{Debug Statement}.
6143 detail. 6148 @item logging @tab @xref{Logging Statement}.
6149 @item mailbox @tab @xref{Mailbox Statement}.
6150 @item locking @tab @xref{Locking Statement}.
6151 @item acl @tab @xref{ACL Statement}.
6152 @end multitable
6144 6153
6145 @menu 6154 @menu
6146 * General Settings:: 6155 * General Settings::
6147 * Security Settings:: 6156 * Security Settings::
6148 * Access Control Lists::
6149 @end menu 6157 @end menu
6150 6158
6151 @node General Settings 6159 @node General Settings
6152 @subsubheading General Settings 6160 @subsubsection General Settings
6153 6161
6154 These statements control the general behavior of the comsat daemon: 6162 These statements control the general behavior of the comsat daemon:
6155 6163
6156 @table @asis 6164 @deffn {Comsatd Conf} max-lines @var{number}
6157 @item max-lines @var{number}
6158 Set maximum number of message body lines to be output. 6165 Set maximum number of message body lines to be output.
6159 @item allow-biffrc ( yes | no ) 6166 @end deffn
6167
6168 @deffn {Comsatd Conf} allow-biffrc @var{bool}
6160 Enable or disable processing of user's @file{.biffrc} file. By default, 6169 Enable or disable processing of user's @file{.biffrc} file. By default,
6161 it is enabled. 6170 it is enabled.
6162 @end table 6171 @end deffn
6163 6172
6164 @node Security Settings 6173 @node Security Settings
6165 @subsubheading Security Settings 6174 @subsubsection Security Settings
6166 6175
6167 These statements control the way @command{comsatd} fights possible 6176 These statements control the way @command{comsatd} fights possible
6168 flooding attacks. 6177 flooding attacks.
6169 6178
6170 @table @asis 6179 @deffn {Comsatd Conf} max-requests @var{number}
6171 @item max-requests @var{number} 6180 Set maximum number of incoming requests per
6172 Set maximum number of incoming requests per @samp{request-control-interval}. 6181 @samp{request-control-interval}.
6173 @item request-control-interval @var{number} 6182 @end deffn
6174 Set the request control interval (seconds).
6175 @item overflow-delay-time @var{number}
6176 Set the initial amount of time to sleep, after the first overflow occurs.
6177 @item overflow-control-interval @var{number}
6178 Set the overflow control interval. If two consecutive overflows happen
6179 within @var{number} seconds, the overflow-delay-time is doubled.
6180 @end table
6181
6182 @node Access Control Lists
6183 @subsubheading Access Control Lists
6184
6185 Access control lists determine from which addresses @command{comsatd}
6186 will receive mail notification messages.
6187
6188 The access control lists are introduced in configuration file using
6189 keyword @samp{acl}. General format for an ACL rule is
6190
6191 @smallexample
6192 acl @var{action} @var{netlist}
6193 @end smallexample
6194
6195 @noindent
6196 Here, @var{action} specifies the action to be taken when a request
6197 arrives from one of the networks, listed in @var{netlist}. There are
6198 two possible actions: @samp{allow} and @samp{deny}.
6199
6200 The @var{netlist} is a whitespace-separated list of network numbers.
6201 Each network number may be specified in one of the following forms:
6202
6203 @table @asis
6204 @item @var{netnum}
6205 Means a single host with IP address @var{netnum}.
6206 @item @var{netnum}/@var{netmask}
6207 @item @var{netnum}/@var{masklen}
6208 @item @samp{any}
6209 Denotes any IP address. It is equivalent to @samp{0.0.0.0/0}.
6210 @end table
6211
6212 Upon receiving a notification message, @command{comsatd} compares its
6213 source address against each ACL rule in the order of their appearance
6214 in the configuration file. The first rule that matches the packet
6215 determines whether the message will be processed or rejected. If
6216 no matching rule was found, the default rule applies. Currently, default
6217 rule is
6218
6219 @smallexample
6220 acl allow any
6221 @end smallexample
6222 6183
6223 @noindent 6184 @deffn {Comsatd Conf} request-control-interval @var{duration}
6224 If you don't need such behavior, specify the default rule explicitly. 6185 Set the request control interval.
6225 For example, the common use would be: 6186 @end deffn
6226 6187
6227 @smallexample 6188 @deffn {Comsatd Conf} overflow-delay-time @var{duration}
6228 @group 6189 Set initial amount of time to sleep, after the first overflow occurs.
6229 acl allow 127.0.0.1 6190 @end deffn
6230 acl deny any
6231 @end group
6232 @end smallexample
6233 6191
6234 @noindent 6192 @deffn {Comsatd Conf} overflow-control-interval @var{duration}
6235 which makes @command{comsatd} receive the notification messages from 6193 Set overflow control interval. If two consecutive overflows happen
6236 localhost only. 6194 within that interval, the overflow-delay-time is doubled.
6195 @end deffn
6237 6196
6238 @node dot.biffrc 6197 @node dot.biffrc
6239 @subheading A per-user Configuration File 6198 @subsection A per-user Configuration File
6240 6199
6241 By default, when a notification arrives, @command{comsatd} prints subject, 6200 By default, when a notification arrives, @command{comsatd} prints subject,
6242 from headers and the first five lines from the new message to the user's 6201 from headers and the first five lines from the new message to the user's
...@@ -6289,7 +6248,7 @@ Expands to message body. @var{c} and @var{l} give maximum number of ...@@ -6289,7 +6248,7 @@ Expands to message body. @var{c} and @var{l} give maximum number of
6289 characters and lines in the expansion. When omitted, they default to 400, 5. 6248 characters and lines in the expansion. When omitted, they default to 400, 5.
6290 @end table 6249 @end table
6291 6250
6292 @subheading Example I 6251 @subsubheading Example I
6293 6252
6294 Dump to the user's terminal the contents of @samp{From} and 6253 Dump to the user's terminal the contents of @samp{From} and
6295 @samp{Subject} headers followed by at most 5 lines of message body. 6254 @samp{Subject} headers followed by at most 5 lines of message body.
...@@ -6437,7 +6396,11 @@ build flags, e.g.: ...@@ -6437,7 +6396,11 @@ build flags, e.g.:
6437 6396
6438 @smallexample 6397 @smallexample
6439 $ mailutils-config --info 6398 $ mailutils-config --info
6440 VERSION=0.4.1 6399 VERSION=@value{VERSION}
6400 SYSCONFDIR=/usr/local/etc
6401 MAILSPOOLDIR=/var/mail/
6402 SCHEME=mbox
6403 LOG_FACILITY=mail
6441 USE_LIBPAM 6404 USE_LIBPAM
6442 HAVE_LIBLTDL 6405 HAVE_LIBLTDL
6443 WITH_GDBM 6406 WITH_GDBM
...@@ -6456,6 +6419,23 @@ ENABLE_SMTP ...@@ -6456,6 +6419,23 @@ ENABLE_SMTP
6456 ENABLE_SENDMAIL 6419 ENABLE_SENDMAIL
6457 @end smallexample 6420 @end smallexample
6458 6421
6422 When this option is used in conjunction with the @option{--verbose}
6423 option, a short description is printed to the right of each keyword,
6424 e.g.:
6425
6426 @smallexample
6427 $ mailutils-config --info --verbose
6428 VERSION=1.9.93 - Version of this package
6429 SYSCONFDIR=/usr/local/etc - System configuration directory
6430 MAILSPOOLDIR=/var/mail/ - Default mail spool directory
6431 SCHEME=mbox - Default mailbox type
6432 LOG_FACILITY=mail - Default syslog facility
6433 USE_LIBPAM - PAM support
6434 HAVE_LIBLTDL - a portable `dlopen' wrapper library
6435 WITH_GDBM - GNU DBM
6436 @dots{}
6437 @end smallexample
6438
6459 This option also accepts any number of arguments. When these are 6439 This option also accepts any number of arguments. When these are
6460 given, each argument is treated as a name of a build flag. 6440 given, each argument is treated as a name of a build flag.
6461 @command{Mailutils-config} checks if such a flag was defined and 6441 @command{Mailutils-config} checks if such a flag was defined and
......