home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 35 Internet
/
35-Internet.zip
/
smtpd20.zip
/
readme.txt
< prev
next >
Wrap
Text File
|
2001-08-05
|
5KB
|
144 lines
SMTPD - a simple SMTP daemon for OS/2
-------------------------------------
This is a very simple and basic SMTP server daemon, which will accept
connections on the usual SMTP port (25) and collect mail for onward
transmission. It is not sophisticated, but it is small and fast.
All companion programs are available from the same place:
http://www.tavi.co.uk/os2pages/mail.html
Installation
------------
Copy the SMTPD.EXE file to any suitable directory which is named in the
system PATH. Copy the NETLIB.DLL file to any directory on the LIBPATH.
Configuration
-------------
First, ensure that you have a line in CONFIG.SYS of the form:
SET TZ=....
This defines your time zone setting, names, and daylight saving rules.
If you don't have one, you need to add it; the actual value can be quite
complex. For the United Kingdom, the line is:
SET TZ=GMT0BST,3,-1,0,7200,10,-1,0,7200,3600
For other areas, download the TZCALC utility from the same place as this
program. This will work out the correct setting for you. It will be
necessary to reboot in order to pick up this setting, but wait until you
have completed the rest of these instructions.
Now edit CONFIG.SYS, adding a new line of the form:
SET SMTP=directoryname
where 'directoryname' is the name of a directory (which must exist)
where outgoing mail is to be stored. No other files should be kept in
this directory. It will be necessary to reboot in order to pick up this
setting, but wait until you have completed the rest of these
instructions.
Locate the directory described by the ETC environment variable. If you
are not sure, type the command:
SET ETC
at a command prompt. In this directory, create a configuration file,
which must be named MAIL.CNF. A sample is provided, as SAMPLE.CNF.
The TRUSTED_HOST line may be included as many times as necessary; if you
are not worried about blocking SMTP calls from anywhere, just use the
line:
TRUSTED_HOST 0.0.0.0 0.0.0.0
If, however, you don't want to become a spam conduit, specify the IP
addresses from which you are prepared to accept mail. You can have
multiple TRUSTED_HOST lines, each specifying a single IP address, or you
can specify a whole group by using the mask effectively. The check is
done by comparing a calling IP address with the one given as the first
value after TRUSTED_ADDRESS; however, before the comparison, both values
are masked with the second address. So, for example, if your local
network was 192.168.55.0, you could use the line:
TRUSTED_HOST 192.168.55.0 255.255.255.0
which would accept calls from anywhere on that network (192.168.55.11,
192.168.55.77, etc...). All TRUSTED_HOST lines are checked on an
incoming call, and if any one of them provides a match, the call is
accepted.
Lastly, edit the file INETD.LST, also found in the ETC directory. Add a
line like this:
smtp tcp smtpd
You can do this via the TCP/IP configuration notebook if you prefer. If
INETD is not already running, edit the file TCPSTART.CMD (normally found
in \TCPIP\BIN) to un-comment the line that starts INETD; again, use the
TCP/IP configuration notebook if you prefer. Reboot to activate INETD,
and also to pick up the SMTP environment setting (and the TZ one if you
added it). INETD will now accept incoming SMTP calls and start SMTPD as
necessary.
Logfile
-------
SMTPD maintains a logfile called SMTPD.LOG in the ETC directory. This
will grow without bound if not pruned regularly! But it is occasionally
useful....
The spool directory
-------------------
Incoming mail is stored in the spool directory specified by the SMTP
environment variable. Don't store anything else in this directory.
Files have a special (but simple) format; the message is stored "as is",
but preceded by lines specifying sender and recipient(s). This format
is understood by the SMTP client program (available separately).
Routing
-------
No special routing of mail is done; it is all placed in the spool
directory. If any more functionality is required, use another program,
such as sendmail (which is roughly ten times the size).
Feedback
--------
SMTPD was written by me, Bob Eager. I can be contacted at the address below.
Please let me know if you actually use this program. Suggestions for
improvements are welcomed.
History
-------
1.0 Initial version.
1.1 First release version.
1.2 Fix drive/directory problem for spool area.
1.3 Further fix for drive/directory problems.
1.4 Use new thread-safe logging module.
Use OS/2 type definitions.
1.5 New, simplified network interface module.
Grouped initialisation code together.
1.6 Diagnostics for occasional logfile open failures.
1.7 Added option security logging.
1.8 Added configuration file, and blocking of non-trusted clients.
1.9 Corrected handling of part line comments in config file.
2.0 Changed name of configuration file to MAIL.CNF.
Added BLDLEVEL string.
Additional error checking in logging module.
Bob Eager
rde@tavi.co.uk
September 2000