Oops -- Lib/Test should be Lib/test, of course!
[python/dscho.git] / Doc / lib / libcrypt.tex
blob8e9a7d31317a794951b650f900be3bf2b7293737
1 \section{Built-in Module \module{crypt}}
2 \label{module-crypt}
3 \bimodindex{crypt}
5 This module implements an interface to the \manpage{crypt}{3} routine,
6 which is a one-way hash function based upon a modified DES algorithm;
7 see the \UNIX{} man page for further details. Possible uses include
8 allowing Python scripts to accept typed passwords from the user, or
9 attempting to crack \UNIX{} passwords with a dictionary.
10 \index{crypt(3)}
12 \begin{funcdesc}{crypt}{word, salt}
13 \var{word} will usually be a user's password. \var{salt} is a
14 2-character string which will be used to select one of 4096 variations
15 of DES\indexii{cipher}{DES}. The characters in \var{salt} must be
16 either \code{.}, \code{/}, or an alphanumeric character. Returns the
17 hashed password as a string, which will be composed of characters from
18 the same alphabet as the salt.
19 \end{funcdesc}
21 The module and documentation were written by Steve Majewski.
22 \index{Majewski, Steve}