a51a895141
Error: "TypeError: Descriptors cannot not be created directly" Use pycryptodome ripemd160 implementation else it must be manually enabled in hashlib/openssl.
14 lines
332 B
Python
14 lines
332 B
Python
# -*- coding: utf-8 -*-
|
|
|
|
# Copyright (c) 2022 tecnovert
|
|
# Distributed under the MIT software license, see the accompanying
|
|
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
|
|
|
|
from Crypto.Hash import RIPEMD160 # pycryptodome
|
|
|
|
|
|
def ripemd160(data):
|
|
h = RIPEMD160.new()
|
|
h.update(data)
|
|
return h.digest()
|