xref: /freebsd/usr.bin/enigma/enigma.1 (revision b9716d687991faafe9172bd2d6726567034441f4)
15dc67cd7SJoerg Wunsch.\"
25dc67cd7SJoerg Wunsch.\" enigma (aka. crypt) man page written by Joerg Wunsch.
35dc67cd7SJoerg Wunsch.\"
45dc67cd7SJoerg Wunsch.\" Since enigma itself is distributed in the Public Domain, this file
55dc67cd7SJoerg Wunsch.\" is also.
65dc67cd7SJoerg Wunsch.\"
7c3aac50fSPeter Wemm.\" $FreeBSD$
85dc67cd7SJoerg Wunsch.\" "
9482b206bSJoerg Wunsch.Dd May 14, 2004
105dc67cd7SJoerg Wunsch.Os
11a4cab7d3SMike Pritchard.Dt ENIGMA 1
125dc67cd7SJoerg Wunsch.Sh NAME
13a684cccdSMike Pritchard.Nm enigma ,
14a684cccdSMike Pritchard.Nm crypt
155dc67cd7SJoerg Wunsch.Nd very simple file encryption
165dc67cd7SJoerg Wunsch.Sh SYNOPSIS
175dc67cd7SJoerg Wunsch.Nm
185dc67cd7SJoerg Wunsch.Op Fl s
195dc67cd7SJoerg Wunsch.Op Fl k
205dc67cd7SJoerg Wunsch.Op Ar password
215dc67cd7SJoerg Wunsch.Nm crypt
225dc67cd7SJoerg Wunsch.Op Fl s
235dc67cd7SJoerg Wunsch.Op Fl k
245dc67cd7SJoerg Wunsch.Op Ar password
255dc67cd7SJoerg Wunsch.Sh DESCRIPTION
263898680cSPhilippe CharnierThe
273898680cSPhilippe Charnier.Nm
283898680cSPhilippe Charnierutility, also known as
295dc67cd7SJoerg Wunsch.Nm crypt
305dc67cd7SJoerg Wunschis a
315dc67cd7SJoerg Wunsch.Em very
325dc67cd7SJoerg Wunschsimple encryption program, working on a
335dc67cd7SJoerg Wunsch.Dq secret-key
346a3e8b0aSRuslan Ermilovbasis.
356a3e8b0aSRuslan ErmilovIt operates as a filter, i.e.,
366a3e8b0aSRuslan Ermilovit encrypts or decrypts a
375dc67cd7SJoerg Wunschstream of data from standard input, and writes the result to standard
38be06d37cSJoerg Wunschoutput.
39be06d37cSJoerg WunschSince its operation is fully symmetrical, feeding the encrypted data
40be06d37cSJoerg Wunschstream again through the engine (using the same secret key) will
41be06d37cSJoerg Wunschdecrypt it.
425dc67cd7SJoerg Wunsch.Pp
436a3e8b0aSRuslan ErmilovThere are several ways to provide the secret key to the program.
446a3e8b0aSRuslan ErmilovBy
455dc67cd7SJoerg Wunschdefault, the program prompts the user on the controlling terminal for
465dc67cd7SJoerg Wunschthe key, using
475dc67cd7SJoerg Wunsch.Xr getpass 3 .
485dc67cd7SJoerg WunschThis is the only safe way of providing it.
495dc67cd7SJoerg Wunsch.Pp
505dc67cd7SJoerg WunschAlternatively, the key can be provided as the sole command-line
515dc67cd7SJoerg Wunschargument
525dc67cd7SJoerg Wunsch.Ar password
536a3e8b0aSRuslan Ermilovwhen starting the program.
546a3e8b0aSRuslan ErmilovObviously, this way the key can easily be
555dc67cd7SJoerg Wunschspotted by other users running
565dc67cd7SJoerg Wunsch.Xr ps 1 .
575dc67cd7SJoerg WunschAs yet another alternative,
585dc67cd7SJoerg Wunsch.Nm
595dc67cd7SJoerg Wunschcan be given the option
605dc67cd7SJoerg Wunsch.Fl k ,
615dc67cd7SJoerg Wunschand it will take the key from the environment variable
625dc67cd7SJoerg Wunsch.Ev CrYpTkEy .
635dc67cd7SJoerg WunschWhile this at a first glance seems to be more secure than the previous
640227791bSRuslan Ermilovoption, it actually is not since environment variables can also be
655dc67cd7SJoerg Wunschexamined with
665dc67cd7SJoerg Wunsch.Xr ps 1 .
675dc67cd7SJoerg WunschThus this option is mainly provided for compatibility with other
685dc67cd7SJoerg Wunschimplementations of
698fe908efSRuslan Ermilov.Nm .
705dc67cd7SJoerg Wunsch.Pp
715dc67cd7SJoerg WunschWhen specifying the option
725dc67cd7SJoerg Wunsch.Fl s ,
735dc67cd7SJoerg Wunsch.Nm
745dc67cd7SJoerg Wunschmodifies the encryption engine in a way that is supposed to make it a
755dc67cd7SJoerg Wunschlittle more secure, but incompatible with other implementations.
765dc67cd7SJoerg Wunsch.Pp
775dc67cd7SJoerg Wunsch.Ss Warning
785dc67cd7SJoerg WunschThe cryptographic value of
795dc67cd7SJoerg Wunsch.Nm
806a3e8b0aSRuslan Ermilovis rather small.
816a3e8b0aSRuslan ErmilovThis program is only provided here for compatibility
82482b206bSJoerg Wunschwith other operating systems that also provide an implementation
83482b206bSJoerg Wunsch(usually called
84482b206bSJoerg Wunsch.Xr crypt 1
85482b206bSJoerg Wunschthere).
86482b206bSJoerg WunschFor real encryption, refer to
87482b206bSJoerg Wunsch.Xr bdes 1 ,
88482b206bSJoerg Wunsch.Xr openssl 1 ,
89f0ea72a0SChristian Brueffer.Xr pgp 1 Pq Pa ports/security/pgp ,
90482b206bSJoerg Wunschor
91f0ea72a0SChristian Brueffer.Xr gpg 1 Pq Pa ports/security/gnupg .
92482b206bSJoerg WunschHowever, restrictions for exporting,
935dc67cd7SJoerg Wunschimporting or using such tools might exist in some countries, so those
945dc67cd7SJoerg Wunschstronger programs are not being shipped as part of the operating
955dc67cd7SJoerg Wunschsystem by default.
965dc67cd7SJoerg Wunsch.Sh ENVIRONMENT
97b9716d68SRuslan Ermilov.Bl -tag -offset indent -width ".Ev CrYpTkEy"
985dc67cd7SJoerg Wunsch.It Ev CrYpTkEy
995dc67cd7SJoerg Wunschused to obtain the secret key when option
1005dc67cd7SJoerg Wunsch.Fl k
1015dc67cd7SJoerg Wunschhas been given
1025dc67cd7SJoerg Wunsch.El
1035dc67cd7SJoerg Wunsch.Sh EXAMPLES
1045dc67cd7SJoerg Wunsch.Bd -literal -offset indent
1055dc67cd7SJoerg Wunschman enigma | enigma > encrypted
1065dc67cd7SJoerg WunschEnter key: (XXX \(em key not echoed)
1075dc67cd7SJoerg Wunsch.Ed
1085dc67cd7SJoerg Wunsch.Pp
1095dc67cd7SJoerg WunschThis will create an encrypted form of this man page, and store it in
1105dc67cd7SJoerg Wunschthe file
111b9716d68SRuslan Ermilov.Pa encrypted .
1125dc67cd7SJoerg Wunsch.Bd -literal -offset indent
1135dc67cd7SJoerg Wunschenigma XXX < encrypted
1145dc67cd7SJoerg Wunsch.Ed
1155dc67cd7SJoerg Wunsch.Pp
1165dc67cd7SJoerg WunschThis displays the previously created file on the terminal.
1175dc67cd7SJoerg Wunsch.Sh SEE ALSO
1185dc67cd7SJoerg Wunsch.Xr bdes 1 ,
119482b206bSJoerg Wunsch.Xr gpg 1 ,
120482b206bSJoerg Wunsch.Xr openssl 1 ,
1215dc67cd7SJoerg Wunsch.Xr pgp 1 ,
1225dc67cd7SJoerg Wunsch.Xr ps 1 ,
1235dc67cd7SJoerg Wunsch.Xr getpass 3
1245dc67cd7SJoerg Wunsch.Sh HISTORY
1255dc67cd7SJoerg WunschImplementations of
1265dc67cd7SJoerg Wunsch.Nm crypt
1275dc67cd7SJoerg Wunschare very common among
1285dc67cd7SJoerg Wunsch.Ux
1296a3e8b0aSRuslan Ermilovoperating systems.
1306a3e8b0aSRuslan ErmilovThis implementation has been taken from the
1315dc67cd7SJoerg Wunsch.Em Cryptbreakers Workbench
1325dc67cd7SJoerg Wunschwhich is in the public domain.
133