trol-A for marking the start of a packet. All 'control' characters imbedded in the data are prefixed to convert them to printable characters, the same applying to eight bit characters if required by the characteristics of the line. Since there are many different implementations of Kermit, the protocol provides a mechanism by which the capabilities of two connected Kermits can be negotiated to allow for differences in the level of protocol support. Examples of protocol features that not all Kermits understand include data compression and transfer of file attributes. .s 1 The packet format is .s 1 .lit +------+-----------+-----------+------+------------+-------+ | MARK | char(LEN) | char(SEQ) | TYPE | DATA | CHECK | +------+-----------+-----------+------+------------+-------+ .eli where all fields consist of ASCII characters, and the char function converts a number in the range 0-94 (10) to a printable ASCII character by adding 32 (10). The MARK, LEN, SEQ and TYPE fields are one byte, the DATA field is variable in size, and the CHECK field is one to three bytes in size. .br The MARK (normally control A) signifies the start of a packet. The length field tells how long the rest of the packet is. The SEQ field is used to insure synchronization used to detect lost or duplicate packets. The SEQ number wraps around every 64 packets due to the need to encode it as a printable ascii character in the range 32 (10) to 126 (10). The TYPE field specifies whether the packet is a DATA or CONTROL packet. The DATA section is used for the actual transfer of data or informative messages from a Kermit server, this field can be up to 90 characters in length. Any character whose low seven bits fall in the range of 0 to 37 (8), ie, char and 177 (8) is less than 40 (8), will have the value 100 (8) exclusive or'ed (xor'ed) with itself and be prefixed by a shift character, '_#'. Other shift characters may be use for eight bit characters if the line characteristics require such. Data compression may also occur in the data field, this is done with yet another shift code and byte count sequence. The CHECK field is a checksum, either a one character, two character or three character CRC check; the sender computes it and the receiver must compute it and compare. A checksum mismatch will result in the receiver sending a NAK packet (negative acknowledgment) which directs the sender to resend the NAK'ed packet. The packet may be following by a terminator (likely an ascii 13). This terminator is NOT part of the protocol and is sent only to tell the receiver that a 'line' is present. Not all Kermit implementations require this; all Kermits will discard data outside of a packet in any event. .s 1 Error detection and recovery is by checksum, as noted, and by packet read timeouts. If the packet should be corrupted the checksum will be incorrect, the receiver will NAK the packet. If an expected packet never arrives within the timeout period, or if the received packet is not the expected one (as determined by the SEQ field) the packet will also be NAK'ed. There are limits as to how many times an expected packet will be NAK'ed without aborting the current operation. .s 1 Packet types .s 1 .lit D Data Y Acknowledgement (ACK), text may be in DATA field N Negative Acknowledgement (NAK) S Send initiate (Send-Init) R Receive Initiate B Break (EOT, end of transmission) F File name header Z End of file (EOF, end of current file) E Error packet, text may be present in DATA field G Generic SERVER command. The first character in the data field will be a command to a server, arguments may follow that character. I Login, user and password follow in data field C CWD, change working or default directory. L Bye, Logout server F Finish, Exit server, but do not log out E Erase, delete files on server system D Directory query U Disk space usage query T Type a file onto local kermit R Rename file(s) on server system K K11F85RNO[.050032]K11F85.RNO[.050032]    X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns<|Ŏ |️|ep|u|-@率|<ᄇ2ֻr||ZRM | ntB|xyvZw|J=|R>|J? nnaa|bddf for binary transmission, based on the file organization, filetype and protection code (for RSTS/E). If the sending Kermit-11 is running on RSTS/E, RSX11M/M+ or P/OS it will also send a copy of the RMS/FCS attributes so the received file will be identical (to FCS and/or RMS) to the copy on the sender's system. Since other implementations of Kermit may use this special system attribute packet, Kermit-11 always sends an attribute packet telling the receiver what hardware and operating system it is running on, and thus will only use such data if they are compatible. Of course, there will be times when a file may be binary and Kermit-11 can't tell so, many Kermit's have a SET FILE BINARY and SET FILE ASCII to allow the user to override defaults. Kermit-11 also has a SET FILE AUTO/NOAUTO to disable it from trying to determine a file's binary status. .s 1 The PDP-11 Kermit-11 implementation .s 1 The author's version of Kermit-11 is written in Macro-11 and can run on RSTS/E, RSX11M, RSX11M Plus, P/OS, RT11 and TSX+. This version of Kermit is distinct from the other three PDP-11 Kermits available; the Stevens P/OS menu driven Kermit; the University of Toronto RT11 pascal Kermit and Bob Denny's P/OS Kermit. In Kermit-11, the RSTS and RSX file system interface is via RMS11 version 2, while the RT11 interface attempts to emulate the RMS11 subsystem. The choice of Macro-11 for the implementation language was made for several reasons, one being the availability of the assembler on all systems and another being speed and compactness of the code. .br RMS11 was used for RSTS/E and the RSX11M based systems to provide a common i/o interface to the host file system. Additionally, Bob Denny of Alisa Systems further extended the RMS interface to support remote file access over DECNET with Kermit, allowing commands such as SEND NODENAME::[BRIAN.FUBAR]FILE.TYPE and other remote file accesses over DECNET. RMS11 version 2 also provides a very simple and powerful means of doing wildcard searching, file renames and file deletion via the $PARSE, $SEARCH, $RENAME and $DELETE macros; it also allows the same RMS interface code to be used on all systems without change. Points against RMS basically amount to it's size, RMS is quite large even if overlayed. This is helped by using the segmented RMSRES available on RSTS/E and RSX11M Plus. The one over negative point is that RMS11 version 2 does not function well, if at all, on the older versions of PDP-11 operating systems, specifically, one should be using RSTS/E v8 or later, RSX11M v4.1 or later, and RSX11M Plus version 2.1 or later. .s 1 All versions of Kermit-11 receive eight bit data assuming no parity is used. Where parity is a must, Kermit-11 has to use a prefixing scheme for eight bit binary data. Binary files are created as FIXED no carriage control files such as used for task images. Note that parity generation is done by software in Kermit-11. The P/OS version of Kermit-11 runs under control of DCL. The next release of Kermit-11, which will be 2.37, will include support for the PRO TMS (Telephone Management System) option. Each version of Kermit-11 has it's own source file to deal with the operating system, for RSX it is K11M41.MAC, for RSTS/E they are K11E80.MAC and K1180S.MAC, and for RT11 they are called K11RT*.MAC. Apart from these specific files, all other source files are shared. The RT11 Kermit-11 can use either the version 5.x XL and XC handler for high throughput, or it can use multiple terminal service to do all its terminal i/o. This second option allows the use of any interface supported, including the PDT150 modem port, DL/DLV11's and DZ/DZV11's. TSX+ users can connect to CL: for dialing out, the exact means is documented in the Kermit-11 users guide. .s 1 Future directions .s 1 With the advent of packet switched networks and satellite communications the Kermit protocol will likely be extended to increase efficiency over such links. The main problem is the half duplex nature of Kermit, the packet acknowledgeK11F85RNO[.050032]K11F85.RNO[.050032]    X14|H [4;Ik(&'( k ߫H&P` \RrPP2PPzPP{PPPPP2P~\$\\TD 0D \~ hi) +\ ^( n ^( np\^txY\^ˀ\!kVk<\F˰<˴ˬ\VVkˤ1`@lP ABCDEFGHIJKLMNOPQRSTUVWXYZ$.?0123456789<@<SЬTЬ UQS>?\\\\\\\\\`:#@'="\abcdefghi\\\\\\\jklmnopqr\\\\\\\~stuvwxyz\\\\\\\\\\\\\\\\\\\\\\{ABCDEFGHI\\\\\\}JKLMNOPQR\\\\\\\\STUVWXYZ\\\\\\0123456789\\\\\  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`ABCDEFGHIJKLMNOPQRSTUVWXYZ{|}~@ggh<i|o<m<4p<p<k|Zn<l fr rwx<x<x<x޺<w@]@@fjnr]Ze@@|> | |v<H|  |  |xz|  |zt f r   < &^ @&@'*/V,"?Lh:hmBmz|z{x`y~|fN|@@|@͂|@ ݃ƃ<ns<|Ŏ |️|ep|u|-@率|<ᄇ2ֻr||ZRM | ntB|xyvZw|J=|R>|J? nnaa|bddfments can take up to several seconds in transit thus drastically reducing the throughput. There are several possibilities under discussion and a standard should be appearing shortly. .s 2 Summary .s 1 With the knowledge that there are Kermit implementations for most personal computers in use it becomes apparent that the Kermit standard is well worth looking in to. A list of versions running on Digital hardware follows the article. .lit Kermit: A File-transfer Protocol for Universities Frank da Cruz and Bill Catchings BYTE Magazine, June/July 1984 The Kermit Protocol Manual, version 5 Frank da Cruz April 1984 Columbia University Center for Computing Activities Information on obtaining Kermit: KERMIT Distribution Columbia University Center for Computing Activities 7th Floor, Watson Laboratory 612 West 115th Street New York, N.Y. 10025 Kermit is also usually found on the Decus symposia SIG tapes. Kermit-11 is available from DECUS as number 11-731 Digital hardware that Kermit is currently available for: Operating Program Machine System Language Contributor DEC PDP-11 MUMPS-11 MUMPS-1982 Cornell U DEC PDP-11 RSTS/E Macro-11 U of Toledo DEC PDP-11 RSX-11/M Macro-11 U of Toledo DEC PDP-11 RSX-11/M+ Macro-11 U of Toledo DEC PDP-11 RT-11 Macro-11 U of Toledo DEC PDP-11 RT-11 OMSI Pascal U of Toronto DEC PDP-11 TSX+ Macro-11 U of Toledo DEC PDP-11 Unix 2xBSD C Columbia U DEC PDP-11, ... Unix V7 C Columbia U DEC PDP-8 OS8, RTS8 PAL-8 R. Hippe DEC Pro-3xx P/OS Bliss, Macro Stevens I.T. DEC Pro-3xx P/OS Macro-11 U of Toledo DEC Pro-3xx Pro/RT Macro-11 U of Toledo DEC Pro-3xx Venix V1 C Columbia U DEC Pro-3xx Venix V2 C Columbia U DEC Rainbow CPM86 ASM86 Columbia U DEC Rainbow MS-DOS MASM Columbia U DEC Rainbow QNX 1.x C Merrell-Dow DEC VAX Ultrix-32 C Columbia U DEC VAX VMS Bliss,Macro Stevens I.T. DEC VAX VMS C (VAX-11 C) Columbia U DEC VAX VMS Pascal U of Toronto DEC VAX, ... Unix 4xBSD C Columbia U DEC VT-180 Robin CPM80 Turbo Pascal Jeff Duncan DEC VT-180 Robin CPM80 2.2 M80,LASM ACC DECmate-II,III CPM80 2.2 M80,LASM ACC DECsystem-10 TOPS-10 Bliss, Macro Stevens I.T. DECSYSTEM-20 TOPS-20 MACRO-20 Columbia U .eli