Esempio n. 1
0
 def testHashPassword(self):
     cryptic = Cryptic()
     hash_text = cryptic.hashify ('abcd1234')
     self.assertEqual(True, cryptic.authenticate_hash('abcd1234', hash_text))
     hash_text = cryptic.hashify ('Juniper123')
     self.assertEqual(True, cryptic.authenticate_hash('Juniper123', hash_text))
     hash_text = cryptic.hashify ('abcd1234')
     self.assertEqual(False, cryptic.authenticate_hash('Juniper123', hash_text))
Esempio n. 2
0
 def testHashPassword(self):
     cryptic = Cryptic()
     hash_text = cryptic.hashify('abcd1234')
     self.assertEqual(True,
                      cryptic.authenticate_hash('abcd1234', hash_text))
     hash_text = cryptic.hashify('Juniper123')
     self.assertEqual(True,
                      cryptic.authenticate_hash('Juniper123', hash_text))
     hash_text = cryptic.hashify('abcd1234')
     self.assertEqual(False,
                      cryptic.authenticate_hash('Juniper123', hash_text))