Added docstring to crypt.crypt() based on the documentation.
authorFred Drake <fdrake@acm.org>
Tue, 1 Feb 2000 20:12:39 +0000 (20:12 +0000)
committerFred Drake <fdrake@acm.org>
Tue, 1 Feb 2000 20:12:39 +0000 (20:12 +0000)
Modules/cryptmodule.c

index 7cc03bed28ffa4ab730c0b4399c90959dd590bc8..746dee15928754a737f184b4441a7372616af72d 100644 (file)
@@ -22,8 +22,17 @@ static PyObject *crypt_crypt(self, args)
 
 }
 
+static char crypt_crypt__doc__[] = "\
+crypt(word, salt) -> string\n\
+word will usually be a user's password. salt is a 2-character string\n\
+which will be used to select one of 4096 variations of DES. The characters\n\
+in salt must be either \".\", \"/\", or an alphanumeric character. Returns\n\
+the hashed password as a string, which will be composed of characters from\n\
+the same alphabet as the salt.";
+
+
 static PyMethodDef crypt_methods[] = {
-       {"crypt",       crypt_crypt},
+       {"crypt",       crypt_crypt, 0, crypt_crypt__doc__},
        {NULL,          NULL}           /* sentinel */
 };