keystream.py 文件源码

python
阅读 36 收藏 0 点赞 0 评论 0

项目:whatsapp-rest-webservice 作者: svub 项目源码 文件源码
def generateKeys(password, nonce):
        resultBytes = []

        for i in range(1, 5):
            currNonce = nonce + bytearray([i])
            resultBytes.append(KeyStream.pbkdf2(password, currNonce, 2, 20))

        return resultBytes

    #@staticmethod  ##use if drop python-2.6 support
    #def pbkdf2( password, salt, itercount, keylen):
    #    return bytearray(hashlib.pbkdf2_hmac('sha1', password, salt, itercount, keylen))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号