update BLS test generator and format to reflect spec change in BLS

This commit is contained in:
protolambda 2019-06-30 22:18:52 +02:00
parent e53063c08d
commit d45b73389e
No known key found for this signature in database
GPG Key ID: EC89FDBB2B4C7623
4 changed files with 7 additions and 7 deletions

View File

@ -6,8 +6,8 @@ A BLS compressed-hash to G2.
```yaml
input:
message: bytes32,
domain: uint64 -- the BLS domain
message: bytes32
domain: bytes8 -- the BLS domain
output: List[bytes48] -- length of two
```

View File

@ -7,7 +7,7 @@ A BLS uncompressed-hash to G2.
```yaml
input:
message: bytes32
domain: uint64 -- the BLS domain
domain: bytes8 -- the BLS domain
output: List[List[bytes48]] -- 3 lists, each a length of two
```

View File

@ -8,7 +8,7 @@ Message signing with BLS should produce a signature.
input:
privkey: bytes32 -- the private key used for signing
message: bytes32 -- input message to sign (a hash)
domain: uint64 -- the BLS domain
domain: bytes8 -- the BLS domain
output: bytes96 -- expected signature
```

View File

@ -89,7 +89,7 @@ def case01_message_hash_G2_uncompressed():
yield {
'input': {
'message': '0x' + msg.hex(),
'domain': domain
'domain': int_to_hex(domain, byte_length=8)
},
'output': hash_message(msg, domain)
}
@ -101,7 +101,7 @@ def case02_message_hash_G2_compressed():
yield {
'input': {
'message': '0x' + msg.hex(),
'domain': domain
'domain': int_to_hex(domain, byte_length=8)
},
'output': hash_message_compressed(msg, domain)
}
@ -126,7 +126,7 @@ def case04_sign_messages():
'input': {
'privkey': int_to_hex(privkey),
'message': '0x' + message.hex(),
'domain': domain
'domain': int_to_hex(domain, byte_length=8)
},
'output': '0x' + sig.hex()
}