[Zope3-Users] possible bug in
zope\app\authentication\principalfolder.py
Shailesh Kumar
shaileshk at gmail.com
Tue Aug 7 11:28:02 EDT 2007
Hi,
I was using InternalPrincipal object and specified a password with
non-ascii characters. Since Password is derived from TextLine, hence
its supposed to be acceptable. But I found that if I use MD5 or SHA1
password managers, it leads to problems. The following exception is
thrown.
I guess the password needs to be encoded in UTF8 before being hashed
by md5 or sha1.
File "C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py",
line 124, in __init__ self.password = password
File "C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py",
line 144, in setPassword self._password =
passwordManager.encodePassword(password)
File "C:\Python24\Lib\site-packages\zope\app\authentication\password.py",
line 76, in encodePassword return md5.new(password).hexdigest()
With regards,
-Shailesh
More information about the Zope3-users
mailing list