clean up awk syntax
[unix-history] / usr / src / old / crypt / crypt.1
CommitLineData
f93aeb97 1.\" @(#)crypt.1 6.1 (Berkeley) %G%
c38495d9 2.\"
f93aeb97 3.TH CRYPT 1 ""
c38495d9
KM
4.AT 3
5.SH NAME
6crypt \- encode/decode
7.SH SYNOPSIS
8.B crypt
9[ password ]
10.SH DESCRIPTION
11.I Crypt
12reads from the standard input and writes
13on the standard output.
14The
15.I password
16is a key that selects a particular transformation.
17If no
18.I password
19is given,
20.I crypt
21demands a key from the terminal and turns
22off printing while the key is being typed in.
23.I Crypt
24encrypts and decrypts with the same key:
25.PP
26 crypt key <clear >cypher
27.br
28 crypt key <cypher | pr
29.PP
30will print the clear.
31.PP
32Files encrypted by
33.I crypt
34are compatible with those treated by the editor
35.I ed
36in encryption mode.
37.PP
38The security of encrypted files depends on three factors:
39the fundamental method must be hard to solve;
40direct search of the key space must be infeasible;
41`sneak paths' by which keys or cleartext can become
42visible must be minimized.
43.PP
44.I Crypt
45implements a one-rotor machine designed along the lines
46of the German Enigma, but with a 256-element rotor.
47Methods of attack on such machines are known, but not widely;
48moreover the amount of work required is likely to be large.
49.PP
50The transformation of a key into the internal
51settings of the machine is deliberately designed to
52be expensive, i.e. to take a substantial fraction of
53a second to compute.
54However,
55if keys are restricted to (say)
56three lower-case letters,
57then encrypted files can be read by expending only
58a substantial fraction of
59five minutes of machine time.
60.PP
61Since the key is an argument to the
62.I crypt
63command,
64it is potentially visible to users executing
65.IR ps (1)
66or a derivative.
67To minimize this possibility,
68.I crypt
69takes care to destroy any record of the key
70immediately upon entry.
71No doubt the choice of keys and key security
72are the most vulnerable aspect of
73.I crypt.
74.SH FILES
75/dev/tty for typed key
76.SH "SEE ALSO"
77ed(1),
78makekey(8)
79.SH BUGS
80There is no warranty of merchantability nor any warranty
81of fitness for a particular purpose nor any other warranty,
82either express or implied, as to the accuracy of the
83enclosed materials or as to their suitability for any
84particular purpose. Accordingly, Bell Telephone
85Laboratories assumes no responsibility for their use by the
86recipient. Further, Bell Laboratories assumes no obligation
87to furnish any assistance of any kind whatsoever, or to
88furnish any additional information or documentation.