server/sources/native.py
branchstable
changeset 4185 ed99de8f93f2
parent 4113 986fc01be83c
child 4195 86dcaf6bb92f
--- a/server/sources/native.py	Tue Dec 22 14:18:48 2009 +0100
+++ b/server/sources/native.py	Tue Dec 22 18:25:53 2009 +0100
@@ -289,8 +289,9 @@
                 raise AuthenticationError('bad login')
             # passwords are stored using the Bytes type, so we get a StringIO
             if pwd is not None:
-                args['pwd'] = crypt_password(password, pwd.getvalue()[:2])
+                args['pwd'] = Binary(crypt_password(password, pwd.getvalue()[:2]))
         # get eid from login and (crypted) password
+        # XXX why not simply compare password?
         rset = self.syntax_tree_search(session, self._auth_rqlst, args)
         try:
             return rset[0][0]