Some years ago, I wrote netkey for UNIX for those who cannot get DES
source code. (ftp://plan9.aichi-u.ac.jp/netkey/netkey.c)
This approach was useful because it was difficult for some people
to get DES source code because of US export regulation.

I used `encrypt' function of UNIX in netkey.c.
However the function is not compatible between Linux and other UNIX systems.
The problem may be resolved if I could get manual of `encrypt' for Linux.

Fortunately I found DES source code in the Web Page of Boyd Roberts.
So I added netkey support to his code so that we have netkey for
Linux and DOS.
The change to his code is:
1. Makefile
	now we have:
	make netkey
	Makefile.dos is also presented for WinXX.
2. 9des.c
	I renamed two functions:
	encrypt	to encrypt9
	decrypt to decrypt9
	because the original names make some problem
	(UNIX already have functions of the same name in the library.)
	and I replaced sprint with sprintf because we compile the file on UNIX.
3. netkey.c
	I discarded many functions of the original my netkey.c
	Because they were written to make interface to `encrypt' function of UNIX.

-Kenar-


------------ ReadMe by Boyd Roberts ---------
There are two parts to this; a UNIX DES implementation and some Plan 9
support for UNIX which uses the DES implementaton.  The Plan 9 support
gives you encrypt(2) and netkey(2).

The only significant difference between my DES and the Plan 9 DES
is that Plan 9 packs a DES key into 7 bytes, while I use 8.  In the
Plan 9 support there's a function (des9key) which does the key
conversion (Plan 9 -> 8 bytes).  The versions of encrypt and decrypt
should call des9key() before invoking deskey(), so it's transparent.

The DES implementation has a Makefile, manual entry and test program.
The Plan 9 support comes with no Makefile support, that's up to you.

