home *** CD-ROM | disk | FTP | other *** search
- THE UNIX SIDE OF THE CONNECTION
-
- The pc-mail programs will need a UNIX host to exchange messages
- with. This automatically gives access to other networks. I sug-
- gest the following strategy:
-
- - Get a uucp login, say, uuxyz on a UNIX system. This will also
- become the uucp-node name of the pc. The file /usr/lib/uucp/L.sys
- should be extended with an entry, e.g.
-
- uuxyz Passive
-
- (on some systems one has to use `Never' instead of `Passive'). It
- may also be necessary to update the /usr/lib/uucp/USERFILE.
-
- - Have all mail for user uuxyz forwarded to uuxyz!somebody. On
- BSD UNIX systems, this is achieved by placing the address
- `uuxyz!somebody' in a file ~uuxyz/.forward; on System-V one
- should put the text `Forward to uuxyz!somebody' in the file
- /usr/mail/uuxyz, which should be read/writeable by group mail.
-
- In the above examples, somebody is a name that can be freely
- chosen; it will not be used by the pc. Of course, mail can be
- forwarded to uuxyz!somebody from other accounts as well.
-
- The result of all this is that you can send mail to any user on
- the UNIX host by just specifying her login name; the host name of
- your pc will not appear in mail headers. People can send mail to
- you by specifying an address on the UNIX host. There is no need
- to register the pc in the uucp maps.
-
- If the above strategy is not what you like, you will have to
- operate as a "real" uucp node and should #define UUCP_HOST in
- sendwork.c. You should also be registered as a uucp node. There
- is more discussion about this in sendwork.c
-
- As a minimum, the UNIX host should support the standard uucp `g'
- protocol. This protocol was developed for eight-bit data paths.
- Unfortunately, modern networks often eat up XON/XOFF and other
- control characters.
-
- To handle non-transparent networks I have written a protocol
- called `k'. It has been used with the Eindhoven University Sytek
- network for over two years and is part of the pc-mail distribu-
- tion. If you're really desperate (and have UNIX source) build
- this protocol into the uucico program by adding the following
- line to struct Proto Ptbl[] in cntrl.c:
-
- 'k', kturnon, krdmsg, kwrmsg, krddata, kwrdata, kturnoff,
-
- and linking the uucico objects with kio.c kp.h kphys.c kpres.c
- and ktrans.c.
-
- THE PC SIDE OF THE CONNECTION
-
- To bring pc-mail up, edit the makefile to reflect the system you
- are using (there are separate makefiles for UNIX and MS-DOS).
- The MS-DOS makefile is for a UNIX-compatible make utility posted
- to usenet near the end of 1986. There is a batch command file
- (buidall.bat) for those who do not have a unix-compatible make
- utility. For testing purposes it is convenient to run this stuff
- on a UNIX host.
-
- Saying `make' should produce five programs:
-
- - mail, the menu-driven user interface
- - cmail, a program that checks if there is new mail
- - smail, a program that queues messages for transmission after
- doing alias substitution on mail addresses
- - cico, the program that performs dialups and file transfers
- - rmail, extracts "From" info from mail received by cico
-
- The programs access a common data base in the form of a spool
- directory with setup file, logfile and message files. There
- should be no other files in the spool directory, to avoid
- confusion. You will have to create the spool directory; the
- programs will not do that.
-
- You will have to set some environment variables before running
- the mail program.
-
- - MAILDIR, the absolute path to your spool directory
- - EDITOR, the name of your favourite editor program
- - PATH, in order locate the executables
-
- The editor command may be an MS-DOS batch file; in that case you
- should include the '.bat' suffix in the command name.
-
- The following two environment variables are optional.
-
- - MAILPRN, if printer output should not go to PRN
- - MAILCMD, command that is executed when the mail program exits
-
- Also, make sure that the limit on the number of open files is
- large enough (20 or so). On MS-DOS, this is handled by a line
- `files=20' in the CONFIG.SYS file.
-
- Run the interactive mail program and choose the setup command. On
- MS-DOS systems only the com1 port is supported (see file
- comport.s). Here is my setup (some names changed) for getting
- through the TUE port selector:
-
- communications_port: com1
- baud_rate: 1200
- remote_host_name: eutwc1
- login_name: uutest
- dialup_sequence: atm\r OK atdt455215\r CONNECT \0 ease: xyz\r ease:
- xyz\r choice: 1\r called: b076\r CLOSED \r
- disconnect_sequence: \0
-
- All entries must be filled or the cico program will complain.
- The MS-DOS version supports the com1 port only.
-
- The dial-up sequence requires some explanation. Basically it is a
- list of words separated by whitespace. The first word is sent to
- the comm. port. The program will wait until it receives the
- second word. And so on. Unlike real uucp (or kermit), there is no
- retry facility. The backslash escape sequences are stolen from
- the c programming language, with some extensions:
-
- \b backspace
- \f formfeed
- \n linefeed
- \r carriage return
- \s blank
- \t tab
- \\ backslash
- \nnn octal code for a character
-
- In order to send or expect an empty string, use the \0 sequence.
-
- It is not possible to send null characters. The dial-up sequence
- should terminate when the UNIX host displays its "login:" prompt;
- the remainder of the dialup sequence is built into the software.
- This, and having (pc node name) == (uucp login name) are to
- prevent fraud. Thus, assuming a Hayes-compatible modem, your
- dialup sequence could be as simple as:
-
- atm\r OK atdt455215\r CONNECT \0
-
- When this dialup sequence succeeds, the program continues with
- its built-in sequence:
-
- ogin: login_name\r ssword: your_password\r
-
- The disconnect sequence uses the same escape sequences as the
- dial-up sequence, but does not use the send/expect protocol. In
- the above sequence, the disconnect sequence is an empty string.
-
- If the cico program has problems communicating with the UNIX host
- you can run it by hand, for example:
-
- cico -d 9 -p your_password
-
- which will produce a lot of debugging output. Setting the
- debugging level to less than 9 produces less output. Level 4 is
- sufficient to monitor the dial-up and login sequence.
-
- ALIAS DATABASE
-
- The user can define aliases for (groups of) mail addresses. The
- format of the alias data base is simple: it is a text file with
- on each line:
-
- alias replacement part
-
- The replacement part may be one or more words; words are
- separated by blanks, tabs or commas. Whenever the smail (mail
- spooler) program recognizes an alias, it is replaced by the
- `replacement' part. Aliases may be defined in terms of other
- aliases; also the order in which they appear in the alias data
- base is not important (except when an alias is defined more than
- once; the program remembers only the last definition of an
- alias). The alias expansion software is smart enough to detect
- infinite loops and to suppress multiple occurrances of the same
- recipient. Alias substitution is not case-sensitive.
-
- BATCH-MODE OPERATION
-
- The cmail program can be run from a batch file (say each time the
- pc is turned on), contact the UNIX host, and report if there is
- new mail. Also, you may want to auto-execute the cmail command
- when exiting from the interactive mail shell. See the manual page
- in the cmail.c source.
-
-