home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
HAM Radio 1
/
HamRadio.cdr
/
packet
/
g0bsx
/
servers.doc
< prev
next >
Wrap
Text File
|
1989-11-30
|
13KB
|
318 lines
Part 1: The G0BSX SMTP <-> Mailbox Interface: SYSOP Documentation.
=================================================================
1. Introduction.
---------------
The G0BSX SMTP <-> Mailbox interface is a general purpose message and bulletin
import/export system that allows export of mail and bulletins to and from SMTP
messages for the W0RLI server system.
The EXPORT system to SMTP allows specific selection of messages on
the To, From and At fields addressed to specific and, if desired, different
and complex addresses.
The IMPORT system from SMTP allows the sending of private mail and bulletins
using the same simple syntax. See the file: SMTPMBX.DOC for the use
documentation on how this is achieved.
RFC 822 Header compatibility is assumed and all EXPORT and IMPORT commands
must specify this. Also read the file: DIRS.DOC for info on how I have
organised my mailbox directory structure - this may be useful to ease the
workings of your mailbox maintenance.
2. Installation Procedure.
-------------------------
i) Copy the following files to your \MB Directory:
SMTPX.COM
SMTPI.COM
SMTPBULL.LST
SMTPMAIL.LST
DOS.BAT
TIMER.EXE
TIMER.DAT
ROUND.COM
Copy the following file to your \BBS directory:
SERVER.MB
Copy the following files to your \MB\FWD directory:
TCPMAIL.FWD
TCPBULL.FWD
ii) Edit the file DOS.BAT to reflect YOUR choice of filenames and
Callsigns. See the file provided for the syntax and explanation for each
field. (Or you could leave it as is if you like!)
iii) Edit the file SMTPMAIL.LST to reflect the desires of your users as to what
Mail they would like delivered to them. See the file provided for syntax
and explanations.
iv) Edit the file SMTPBULL.LST to reflect the desires of your users as to what
Bulletins they would like delivered to them. Beware of sending them
EVERYTHING, it occupies a LOT of channel time!!
v) Copy the file: SERVER.MB into your \BBS directory.
This is the file that controls what Mailbox messages are exported into
text files used for input for the SMTPI.COM program. Edit it to alter the
callsigns to suit your clients. I use Norton Commander to Edit it since
I can control whether or not the last line (the ! DOS.BAT command) is
terminated by a carriage return (see below under NOTES for explanation)
I would recommend you leave it unchanged and put all the servers into a
\MB directory and create and maintain files called \MB\FWD\TCPMAIL.FWD
and \MB\FWD\TCPBULL.FWD which will contain all the callsigns and identifiers
that you wish to forward.
vi) Edit your distribution lists to add an identifier for bulletin export. I
use TCPIP and have that identifier in all my .DIS lists (or, at least, only
the ones where I want the bulletins to be exported!) The flexibility of
selection at both the Mailbox AND server level makes the system very
versatile. You can run the SMTPI server as many times as you like with
different sets of exported and selection files. Simply alter the file
DOS.BAT and generate export files for each time you call it!
vii) Alter your AUTOEXEC.NET file so that you have:
smtp mode queue
somewhere in it and NOT smtp mode route.
viii) Run SERVER.EXE in an appropriately sized window (110k). It should run all
the time in parallel with your mailbox windows.
3. Notes:
--------
It is possible to have a single export file and .LST file if desired by simply
forwarding ALL mail and bulletins to the said file and combining the two files
SMTPBULL.LST and SMTPMAIL.LST into one. However, I like to partition the work
and therefore have separate calls for each task. Furthermore, I like to limit
bulletin export to the early hours by using the TIMER function (provided with
this software) and this can only be done if the functions are seperated.
There is a QUIRK in the version 10.01 W0RLI server in that only a SINGLE DOS
batch file is allowed, it MUST be the last item, and it must not be followed
by a carriage return! (Actually, there are 2 quirks. The other is a failure of
the Server to IMPORT subject texts from valid RFC822 headers.) These have been
fixed in versions after 10.03.
There is also a quirk in the SMTP mailer. If a user sends files with line
lengths of MORE than 128 characters, these lines are summarily truncated.
I cater for this on OUTGOING mail by using the ROUND.COM program, to trap
and word wrap any such long lines at 80 characters. However, you will have
to educate your users to limit their INCOMING mail line lengths to 128 chars
since, once it has been through SMTP (as it does on the way in) there is no
way of retrieving the excess characters.
4. System Operation.
-------------------
The SMTPX program simply looks at the \SPOOL\RQUEUE directory and imports ALL
messages found there. Be careful, therefore, that you do not export messages
to YOURSELF to SMTP since these may loop endlessly!!
The SMTPI program reads the specified import and host preferences files and,
for each entry of the preferences file, scans the export file for a match. If
a match is found, it puts a message in the \SPOOL\MQUEUE directory to the
specified address at the specified host. Message number conflicts are correctly
handled by manipulation of the SEQUENCE.SEQ file. All messages are also locked
by the program until they are complete using a .LCK file so that SMTP does
not attempt to access incomplete files should it be scanning the directory at
the same time as the SMTPI program.
Please observe the syntax of the .LST files carefully, I have not yet made
the program foolproof for errors in this file, though it will not fatally
crash, it will simply not deliver the mail properly!
The export file is DELETED after SMTPI has successfully been run. Therefore,
be sure to allow for all mail sent to the export file to have a corresponding
entry in the .LST file, since if it does not, that mail will be lost.
Limitations:
-----------
* The code is not yet "mil spec" so if you do encounter problems, PLEASE let
me know! I have not had it crash for some 18 months now but, then, I did
write the code and use it as I decided it to be used!
* The System will also not cope with SMTP message numbers greater than
32767 (yet). Mailbox message numbers greater than 32000 are no problem.
if you get to this number, the best thing to do is simply erase the file
SEQUENCE.SEQ in the \SPOOL\MQUEUE directory to let it start at 1 again!
Or you can igmore it; the SMTP mailer will otherwise simply wrap around on
32767 anyway!!
* NET.EXE also imposes some limitations on the number of files you can, at
any one time, have queued for SMTP. Each file in the \SPOOL\MQUEUE directory
requires about 50 bytes of heap memory in NET.EXE - a good practical upper
limit is about 200 queued messages at any time if it is run in a desqview
window. If you get more than this on bulletin exports, it may be wise to
insist on all bulletin receiving TCP/IP stations to be on 24hrs a day and
send them bulletins as they arrive by removing the TIMER control in the
DOS.BAT file.
Part 2: REQFIL and REQDIR Servers.
=================================
Introduction:
------------
These drivers allow remote stations to retrieve files and directories from
your system by sending it a message of the form:
SP REQDIR @ BBS or SP REQFIL @ BBS
Pathspec PathSpec
/EX /EX
The contents of any message are ignored, ONLY the title is used.
PathSpec is either the name of a file or the name of a directory and must
use MSDOS conventions. For example:
SP REQDIR @ GB7PLY
. (OR nothing OR *.*)
Will return the base directory of my texts section (defined in the REQxxx.DAT
file (qv)). This will produce a file like:
Directory of .
amsat\ date time amtor\ date time
index size date time
etc...
all names followed by a \ character is a directory. to read this directory,
the user sends:
SP REQDIR @ GB7PLY
amsat
and so on.....
To read a FILE, the path spec must include directory and filename, for example:
SP REQFIL @ GB7PLY
amsat\dce.doc NOTE: NO preceding "\" character.
will return the file "dce.doc" in the amsat directory. Directories can be
nested as deeply as desired. NOTE: This does not corespond with the W0RLI
flat directory system but then, I run TCP/IP as well and I do have a
\PUBLIC\TEXTS\ directory which contain all my texts files directories.
Subdirectories and requests can be nested as deep as you like within the
limitation of 128 characters for the whole pathspec (IF your DOS environment
will cope with that!) I also run the FILES server (qv) which emulates the
W0RLI directory and file system.
Installation:
------------
i) Make sure the supplied SERVER.MB file is in your \BBS directory. The
important bits are the two lines:
s reqdir \mb\reqdir.exe reqdir.out H8 reqdir.in H8
s reqfil \mb\reqfil.exe reqfil.out H8 reqfil.in H8
ii) Copy the files: REQDIR.EXE and REQFIL.EXE to your \MB directory.
iii) Copy the file REQxxx.DAT into your ROOT (\) directory. If it ain't there,
NOTHING will happen! Edit this file to reflect the directory where you
keep all the texts you will want your users to have access to. This
file will be expanded for later REQ drivers to contain other data as
required by these later versions.
iv) Now test the system by sending a message to REQDIR or REQFIL and give
the server a nudge to process it.
Notes:
------
There is a BUG in the W0RLI SERVER 10.01 that does not read the Subject: field
of the RFC822 header and this is not properly handled although it will be when
hank fixes the server - as he has done in later releases.
If you have ever used a MBL REQxxx system, you will know that MBL requires
a "@ ReturnBBS" field after the filename or directory name. THIS IS NOT
NECESSARY with this system and is, in fact, not desirable though the system
does cope with it (by ignoring it!)
LIMITATIONS:
-----------
There are a few minor bugs in the syntax handling of the REQDIR server....
It does not like NOT having a field to work on if the receiving station
inserts a return address as per WA7MBL format. If the return address in the
subject field is omitted OR a search field is specified, e.g. *.* @ bbscall
all seems to be o.k..... I will get round to fixing these somtime, i guess!
Part 3: FILES Server.
====================
The FILES.EXE server is used in a similar fashion to the REQxxx servers above
but with some distinct differences.
i - A W0RLI style directory listing is given by reading the CONFIG.MB file.
ii - The SAME server gives both files and directories
Installation:
-------------
1. Copy the file: FILES.EXE into your \MB directory.
2. Make sure your SERVER.MB file contains the line:
s files \mb\files.exe files.out H8 files.in H8
The FWD.MB file supplied with this software is O.K.
3. Run SERVER.EXE in an appropriate window. (110k)
Usage:
-----
Any message addressed TO FILES will be processed. If the title or the message
contents contain valid W0RLI style directory or download commands, these are
processed. The W0RLI D command has also been extended to allow selective
downloading by specifying a range of line numbers.
For Example:
SP FILES @ GB7PLY
FILES QUERY
W
/EX
will return the main directory of the GB7PLY W0RLI mailbox.
SP FILES @ GB7PLY
WA
WB
WC
/EX
will return the directories of areas A, B and C in 3 messages.
SP FILES @ GB7PLY
Anything you like for the title, but it MAY be a command if you wish!
DA BBSLIST.HF
DC BSX1DRVR.BAS
WZ
/EX
will return 3 messages to you conatinging the file "BBSLIST.HF" in area A,
the file BSX1DRVR.BAS from area C and the directory listing of area Z.
SP FILES @ GB7PLY
FILES Query
DA BBSLIST 10
DA BBSLIST 10 20
/EX
will return 2 messages, the first containing the FIRST 10 lines of the file
BBSLIST, the second containing lines 10 to 20 of the file BBSLIST. To Get
"all lines after line 20" use the syntax DA BBSLIST 20 99999 or some other
huge number....
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Thats all Folks (phew!)
Good Luck. Any problems, please let me know:
Peter Meiring, G0BSX @ GB7PLY, Bsc(Hons), MB, ChB, MRCR.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
P.S.
---
A version of the SMTP interface also exists for MBL mailboxes that does the
same work as this one. (a little slower, though!)