Skip to content

Commit 210c002

Browse files
committed
improving formatting
1 parent 4a45f3a commit 210c002

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

main.py

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2615,10 +2615,23 @@ def case18_fail_pairing_check():
26152615
"Name": "bls_pairing_extra_data"
26162616
},
26172617
{
2618-
"Input": "10" + int_to_hex(int(G1[0]), 63) + (int_to_hex(int(G1[1]), 64)) + int_to_hex(int(G2[0].coeffs[0]), 64) + int_to_hex(
2619-
int(G2[0].coeffs[1]), 64) + int_to_hex(int(G2[1].coeffs[0]), 64) + int_to_hex(int(G2[1].coeffs[1]), 64) + int_to_hex(
2620-
int(G1[0]), 64) + (int_to_hex(int(G1[1]), 64)) + int_to_hex(int(neg(G2)[0].coeffs[0]), 64) + int_to_hex(
2621-
int(neg(G2)[0].coeffs[1]), 64) + int_to_hex(int(neg(G2)[1].coeffs[0]), 64) + int_to_hex(int(neg(G2)[1].coeffs[1]), 64),
2618+
# G1 point (wrong element top bytes)
2619+
"Input": "10"
2620+
+ int_to_hex(int(G1[0]), 63)
2621+
+ int_to_hex(int(G1[1]), 64)
2622+
# G2 point 1
2623+
+ int_to_hex(int(G2[0].coeffs[0]), 64)
2624+
+ int_to_hex(int(G2[0].coeffs[1]), 64)
2625+
+ int_to_hex(int(G2[1].coeffs[0]), 64)
2626+
+ int_to_hex(int(G2[1].coeffs[1]), 64)
2627+
# G1 point 2
2628+
+ int_to_hex(int(G1[0]), 64)
2629+
+ int_to_hex(int(G1[1]), 64)
2630+
# G2 point 2
2631+
+ int_to_hex(int(neg(G2)[0].coeffs[0]), 64)
2632+
+ int_to_hex(int(neg(G2)[0].coeffs[1]), 64)
2633+
+ int_to_hex(int(neg(G2)[1].coeffs[0]), 64)
2634+
+ int_to_hex(int(neg(G2)[1].coeffs[1]), 64),
26222635
"ExpectedError": "invalid field element top bytes",
26232636
"Name": "bls_pairing_top_bytes"
26242637
},

0 commit comments

Comments
 (0)