示例#1
0
文件: check.py 项目: KWMalik/codenode
 def getUser(self, user, creds):
     print 'getuser', user
     avatarId, hashedpass = str(user.id), str(user.password)
     if hashpass.check_password_against_hash(creds.password, hashedpass):
         self.cache[(creds.username, creds.password)] = avatarId
         return defer.succeed(avatarId)
     else:
         return defer.fail(error.UnauthorizedLogin())
示例#2
0
 def getUser(self, user, creds):
     print 'getuser', user
     avatarId, hashedpass = str(user.id), str(user.password)
     if hashpass.check_password_against_hash(creds.password, hashedpass):
         self.cache[(creds.username, creds.password)] = avatarId
         return defer.succeed(avatarId)
     else:
         return defer.fail(error.UnauthorizedLogin())
示例#3
0
文件: check.py 项目: KWMalik/codenode
 def getUser(self, user, creds):
     avatarId, hashedpass = str(user.id), str(user.password)
     if hashpass.check_password_against_hash(creds.password, hashedpass):
         return defer.succeed(avatarId)
     else:
         return defer.fail(error.UnauthorizedLogin())
示例#4
0
 def getUser(self, user, creds):
     avatarId, hashedpass = str(user.id), str(user.password)
     if hashpass.check_password_against_hash(creds.password, hashedpass):
         return defer.succeed(avatarId)
     else:
         return defer.fail(error.UnauthorizedLogin())