You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Think about the correctness of ressol tests.
In some of them p - isn't primary number. Add check of this to tommath::mp_sqrtmod_prime default function and Shanks-Tonnelli gmp implementation or change tests.
Ressol implementation seems to have a bug. Incorrect Shanks-Tonnelli algorithm implementation could be a reason.
Test data:
modulus = 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F
a = 0x6650aa44bf64a7e4a62402a88eed89b9c269af6839db7142cb40bb0b6f558063
expected_a_sqrt = 0xbb53444d14f93d9305e2e4d3e3a76639c20aa9f2a87483c6aba0ffb9bf31e48
produced_a_sqrt = 0xf44acbbb2eb06c26cfa1d1b2c1c5899c63df5560d578b7c39545f003640cdde7
The text was updated successfully, but these errors were encountered: