MCPcopy Index your code
hub / github.com/petertodd/python-bitcoinlib / bech32_verify_checksum

Function bech32_verify_checksum

bitcoin/segwit_addr.py:43–45  ·  view source on GitHub ↗

Verify a checksum given HRP and converted data characters.

(hrp, data)

Source from the content-addressed store, hash-verified

41
42
43def bech32_verify_checksum(hrp, data):
44 """Verify a checksum given HRP and converted data characters."""
45 return bech32_polymod(bech32_hrp_expand(hrp) + data) == 1
46
47
48def bech32_create_checksum(hrp, data):

Callers 1

bech32_decodeFunction · 0.85

Calls 2

bech32_polymodFunction · 0.85
bech32_hrp_expandFunction · 0.85

Tested by

no test coverage detected