On 9/1/05, J. Davis <[EMAIL PROTECTED]> wrote:
> To create the password I paste in the output from the following
> command:
> 
> # echo "password" | md5sum
> 
> Can anyone suggest how else I might troubleshoot this?

It appears the md5sum shell command doesn't generate the same output
as Python's md5. Django's md5s are generated like so:

>>> import md5
>>> md5.new('password').hexdigest()

Generate the md5 that way, and you should be good to go. Or spare
yourself the low-level trouble and use this:

>>> from django.models.auth import users
>>> u = users.create_user('username', '[EMAIL PROTECTED]', 'password')
>>> u.is_staff = True
>>> u.save()

Adrian

-- 
Adrian Holovaty
holovaty.com | djangoproject.com | chicagocrime.org

Reply via email to