2
.\" Copyright (c) 2004, Nate Nielsen
3
.\" All rights reserved.
5
.\" Redistribution and use in source and binary forms, with or without
6
.\" modification, are permitted provided that the following conditions
9
.\" * Redistributions of source code must retain the above
10
.\" copyright notice, this list of conditions and the
11
.\" following disclaimer.
12
.\" * Redistributions in binary form must reproduce the
13
.\" above copyright notice, this list of conditions and
14
.\" the following disclaimer in the documentation and/or
15
.\" other materials provided with the distribution.
16
.\" * The names of contributors to this software may not be
17
.\" used to endorse or promote products derived from this
18
.\" software without specific prior written permission.
20
.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21
.\" "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22
.\" LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
23
.\" FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
24
.\" COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
25
.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
26
.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
27
.\" OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
28
.\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29
.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
30
.\" THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
35
.\" Nate Nielsen <nielsen@memberwebs.com>
42
.Nd the configuration file for
46
reads a configuration file when starting up. The location of the file is dependent
47
on how you compiled clamsmtp but it should usually be in either the
53
does not find its configuration file it'll print a warning when it starts up along
54
with the location it's expecting to find it in. You can also specify a different
55
location for a config file by passing the
60
The settings are specified one per line. The setting names come first, followed
61
by a colon and then the value. Comments start with the '#' character on a line
62
of their own. Whitespace is ignored at the beginning of line, end of line and
65
A sample configuration file can be found in the
67
directory of the clamsmtp distribution.
69
The various settings are as follows:
74
actively rejects messages with viruses. This may cause the sender to receive
75
a message back notifying them of the virus. In most cases this is not a good
76
idea since many viruses spoof sender addresses.
79
Specifies the address to connect to
81
on. See syntax of addresses below.
83
.Pa /var/run/clamav/clamd
86
On slow connections the server will sometimes timeout before
88
is finished scanning the file. This option sends NOOP's to the server
89
to keep the connection alive. Specify the number of seconds, or 0
93
The address and port to listen for SMTP connections on. See syntax of
95
[ Default: port 10025 on all local IP addresses ]
97
Specifies a location for the a process id file to be written to. This file
98
contains the process id of
100
and can be used to stop the daemon. If the
102
argument is passed on the command line, then this setting will be ignored.
105
Quarantine files that contain viruses by leaving them in the
107
directory. The file names look like this (where X is a random
108
character or number):
111
.It Ar MaxConnections
112
Specifies the maximum number of connections to accept at once.
114
also needs to be setup to accept at least this number of connections.
117
A header to add to scanned messages. Put an empty value to suppress adding
119
[ Default: 'X-Virus-Scanned: ClamAV using ClamSMTP' ]
121
The address of the SMTP server to send email to once it's been scanned. See
122
syntax of addreses below.
125
The directory to write temp files to. This directory needs to be
134
The number of seconds to wait while reading data from network connections.
135
[ Default: 180 seconds ]
136
.It Ar TransparentProxy
137
This option enables transparent proxy support, which allows you to route all
138
SMTP traffic that's going through a gateway through clamsmtp which will then
139
send it on to its final destination. This setup usually involves firewall
140
rules which redirect traffic to clamsmtp, and the setup varies from OS to OS.
142
The user to run as. If this option is specified then
144
must be started as root. It will then drop root privileges and run as the
145
specified user. The user can either be a name or a numerical user id.
147
This is a command to run when a virus is found. See the VIRUS ACTION section
150
for a discussion of this option.
153
Send an XCLIENT command to the receiving server. This is useful for forwarding
154
client addresses and connection info to servers that support this feature.
158
Addresses can be specified in multiple formats:
161
Unix local addresses can be specified by specifying their full path.
162
(ie: '/var/run/clamav/clamd').
164
IP addresses can be specified using dotted notation with a colon before
165
the port number (ie: '127.0.0.1:3310').
167
IPv6 addresses are implemented but disabled. The code needs testing.
172
.An Nate Nielsen Aq nielsen@memberwebs.com