How to use unix_md5_crypt from Perl in Python?

Paul Rubin http
Thu Mar 22 10:17:09 CET 2007


Nico Grubert <nicogrubert at gmail.com> writes:
> Example:
>    username = 'root at localhost'
>    password = 'root'
> 
> The crypted password is: 'roK20XGbWEsSM'

that looks like you want crypt(3), not md5.  See:

   http://docs.python.org/lib/module-crypt.html

Sample session:

    >>> import crypt
    >>> print crypt.crypt('root','ro')
    roK20XGbWEsSM
    >>> 



More information about the Python-list mailing list