Merge pull request #54 from zcash-hackworks/nu5-testnet-update
Updates for new NU5 testnet consensus rules
This commit is contained in:
commit
d1f5723d8b
|
@ -24,7 +24,7 @@ def rcv_trapdoor(rand):
|
||||||
# https://zips.z.cash/protocol/nu5.pdf#concretesinsemillacommit
|
# https://zips.z.cash/protocol/nu5.pdf#concretesinsemillacommit
|
||||||
def sinsemilla_commit(r: Scalar, D, M):
|
def sinsemilla_commit(r: Scalar, D, M):
|
||||||
assert isinstance(r, Scalar)
|
assert isinstance(r, Scalar)
|
||||||
return sinsemilla_hash_to_point(D + b"-M", M).checked_incomplete_add(
|
return sinsemilla_hash_to_point(D + b"-M", M) + (
|
||||||
group_hash(D + b"-r", b"") * r
|
group_hash(D + b"-r", b"") * r
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -309,7 +309,7 @@ def main():
|
||||||
return bytes(ret)
|
return bytes(ret)
|
||||||
rand = Rand(randbytes)
|
rand = Rand(randbytes)
|
||||||
|
|
||||||
consensusBranchId = 0xF919A198 # NU5
|
consensusBranchId = 0x37519621 # NU5
|
||||||
|
|
||||||
test_vectors = []
|
test_vectors = []
|
||||||
for _ in range(10):
|
for _ in range(10):
|
||||||
|
|
Loading…
Reference in New Issue