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 >>>