Last update 03-Mar-2002

 

mbcico - The Fidonet mailer.

This is work in progress....

Synopsis.

-a<inetaddr> -l<ttydevice> <node> ...
-n<phone>     forced phone number
-l<ttydevice> forced tty device
-t<tcpmode>   telnet TCP/IP mode, must be one of ifc|itn|ibn, forces TCP/IP
-a<inetaddr>  supply internet hostname if not in nodelist
<node>        should be in domain form, e.g. f11.n22.z3
-h            show this help message

 or: mbcico tsync|yoohoo|**EMSI_INQC816|-t ibn|-t ifc|-t itn (this is answer mode)

 

Description.

mbcico stands for MBse "Internet - Fidonet Copy In /Copy Out", this is a FidoNet(r) compatible transport agent. It is based on ifcico written by Eugene G. Crosser, <crosser@average.org>, 2:5020/230@FidoNet. I changed the name of the program to make the difference between ifcico and mbcico. Nowadays it is quite different then ifcico.

Currently it supports FTS-0001, YooHoo/2U2 and EMSI handshake protocols, Xmodem, Telink, Modem7, Hydra, SEAlink with and without overdrive and crash recovery, Bark file and update requests, WaZoo protocols: DietIFNA, plain Zmodem (aka ZedZip, EMSI flag "ZMO") and ZedZap, WaZoo file and update requests (nodelist flag should be XA). WaZoo file and update requests do also work with FTS-0001 sessions, this is supported by several well known DOS mailers also. Password protected requests and update requests are implemented (but not yet full tested).

There is also a special protocol optimized to use over TCP/IP connections, contributed by Stanislav Voronyi <stas@uanet.kharkov.ua>, it is identiefied by EMSI proto code TCP (not registered) and nodelist flag IFC. The default port is 60179. There is a telnet variant on this, the default port is 23, and nodelist flag is ITN. The telnet variant is written by T. Tanaka.

There is also a Binkp implementation, this is a bi-directional TCP/IP protocol. This protocol is prefferred over the IFC protocol because it is more efficient. Nodelist flag is IBN, the default port is 24554, and the nodelist request flag is XX. This Binkp implementation supports multiple batches, however this is only tested against another mbcico. I don't know if any other mailer supports this option, but it is documented in the spec's. (Irex uses it).

Outbound directory structure is BinkleyTerm compatible, with domains and point subdirectories (full 5d). There are separate "protected" and "unprotected" inbound directories for the incoming sessions with the nodes that are in your setup. Files received during outbound sessions are always stored in the "protected" inbound.

"Magic" file request processors are executable files placed in the "magic" directory. If a request is made for a file with matching name, the executable from the "magic" directory is run, and its stdout output is mailed to the requestor. Full requestor's address, in the form of "John Smith of 1:234/56/7" is passed to the executable in the command line. Non-executable files in the magic directory contain the full names to magic filenames. The magic NODELIST can thus point to the full path and filename of your latest nodelist. These magic names are automatic maintained by the mbfido program when the magic name is set in the .tic file that you receive.

To run mbcico in master mode, you need to make dialout devices read/writeable for mbcico, and do the same for the directory where your uucp locks are created (usually /var/locks).

 

Answer Mode.

To make mbcico work in answer mode, you need mgetty written by Gert Doering. mbcico must be started with one of the following parameters:

FTS-0001 call:       "/opt/mbse/bin/mbcico tsync"
FTS-0006 call:       "/opt/mbse/bin/mbcico yoohoo"
EMSI call:           "/opt/mbse/bin/mbcico **EMSI_....."

In the latter case the received EMSI packet should be passed whitout trailing CR). To make this work mgetty must be compiled with the -DFIDO option. Other getty programs might work.

To answer TCP/IP calls the following lines should be added to /etc/inetd.conf:

binkd   stream  tcp     nowait  mbse    /opt/mbse/bin/mbcico    mbcico -t ibn
tfido   stream  tcp     nowait  mbse    /opt/mbse/bin/mbcico    mbcico -t itn
fido    stream  tcp     nowait  mbse    /opt/mbse/bin/mbcico    mbcico -t ifc

If your system uses xinetd the file /etc/xinetd.d/mbsebbs could be:

#:MBSE BBS services are defined here.

service binkp
{
	socket_type     = stream
	protocol        = tcp
	wait            = no
	user            = mbse
	instances       = 10
	server          = /opt/mbse/bin/mbcico
	server_args     = -t ibn
}

service tfido
{
	socket_type     = stream
	protocol        = tcp
	wait            = no
	user            = mbse
	instances       = 10
	server          = /opt/mbse/bin/mbcico
	server_args     = -t itn
}

service fido
{
	socket_type     = stream
	protocol        = tcp
	wait            = no
	user            = mbse
	instances       = 10
	server          = /opt/mbse/bin/mbcico
	server_args     = -t ifc
}

In the file /etc/services the following lines must be present:

binkd           24554/tcp               # mbcico IBN mode
tfido           60177/tcp               # mbcico ITN mode
fido            60179/tcp               # mbcico IFC mode
mbse            60180/tcp               # MBSE BBS deamon

In this case I installed the ITN mode at port 60177 instead of 23 like most sysops do.

 

Calling Mode.

You never need to call nodes with mbcico by hand, mbtask will start mbcico with the right commandline.
Note: you should not call nodes with mbcico directly, let mbtask do the calling. If you want to call a node make a poll command.

 

Environment.

In order to run the mbcico you need to set one global environment variable $MBSE_ROOT This variable must point to the root of the bbs directoy structure.

 

Return Codes.

0        - No errors
1..32    - OS errors, SIGHUP, SIGKILL, etc.
100      - Commandline error.
101      - Configuration error.
103      - Disk full.
108      - File transfer error.
111      - Node not in nodelist.
112      - Node may not be called (Hold, Down, not ZMH).
113      - Could not make connection.
114      - Cannot open tty port.
115      - Node is locked.
116      - No IP address.
117      - Unknown session type.
118      - Not Zone Mail Hour.
119      - Modem error.
120      - Not port available.
121      - Session error.
122      - EMSI session error.
123      - FTSC session error.
124      - Wazoo session error.
125      - YooHoo session error.
126      - Outbound scan error.
127      - Cannot poll.
These codes are also stored in status files for nodes, with the extension of ".sts". These are small datafiles containing three decimal numbers.
  1. Time retry code, this is the next call attempt time. This is an unsigned long representing the number of seconds since the epoch. Before this time the node may not be called. This is set after a failed call, a random time in the near future is selected.
  2. Retries, this is the number of consequtive call attempts made that returned "call failed" or other errors. This field is zeroed when the call succeeds and when a new "poll" is created. If the value is 30, the node won't be called anymore.
  3. Code, this is the return code of the last attempt.

 

Configuration.

The behaviour of mbcico can be configured with mbsetup, section 1.17 If something doesn't do what you want, set the debug on for that problem. This will produce huge logfiles, but also a lot of information. Important flags are Device IO, EMSI debug, File forward, Locking, Outboundscan and Session.

 

Bugs.

Incoming calls from McMail mailers, McMail is quite hasty to establish an EMSI session, and times out in less than a second. So if your system is heavy loaded, or not too fast, McMail cannot connect with your system. This is a known problem with McMail 1.0 and older, later versions are ok.

 

Authors.

Eugene G. Crosser <crosser@average.org>   Orginal ifcico.
Stanislav Voronyi <stas@uanet.kharkov.ua> TCP/IP code.
T. Tanaka                                 Telnet mode.
Martin Junius                             Rewrite of opentcp().
Omen Technology Inc                       Zmodem protocol.
Arjen G. Lentz, Joaquim H. Homrighausen   Hydra transfer protocol.
Cristof Meerwald                          Implementation of Hydra in ifcico.
P. Saratxaga                              Tty driver code, yoohoo extensions.
Dima Maloff                               Binkp protocol.
Michiel Broek                             Rewrite for MBSE BBS.

IndexBack to index  MainBack to Main index