[Mailman-Users] Password Authentication Problem (2)
Torjus Jensen
tjensen at edudex.com
Thu Nov 30 18:27:58 CET 2000
In an earlier e-mail we had asked for help with a problem where the site
admin password would not authenticate. SInce we did not get any response, we
began looking into the code.
We have determined that the problem is either that writing to the adm.pw
file fails, or reading from it fails:
>From Utils.py:
def SetSiteAdminPassword(pw):
fp = open_ex(mm_cfg.SITE_PW_FILE, 'w', perms=0640)
fp.write(Crypt.crypt(pw, GetRandomSeed()))
fp.close()
def CheckSiteAdminPassword(pw1):
try:
f = open(mm_cfg.SITE_PW_FILE)
pw2 = f.read()
f.close()
return Crypt.crypt(pw1, pw2[:2]) == pw2
# There probably is no site admin password if there was an exception
except IOError:
return 0
If we substitute def CheckSiteAdminPassword with:
#def CheckSiteAdminPassword(pw1):
#return 1
we are able to log in (obviously).
We have checked permissions on the adm.pw, and noted that it is indeed
written to when calling mmsitepass. Our guess is therefore that the problem
is either in reading from the file, or in the Crypt.crypt function.
Since we are not at all familiar with Python, we would appreciate some help.
Thanks.
--------------------------
Torjus Jensen
http://www.edudex.com <http://www.edudex.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/mailman-users/attachments/20001130/a6604323/attachment.html
More information about the Mailman-Users
mailing list