mirror of
https://github.com/jedisct1/libsodium.git
synced 2026-08-25 08:37:13 +09:00
Remove S<l check.
Plan is to add is_standard()/is_canonical() instead of changing the current behavior of the verification function. Suggested by CodesInChaos.
This commit is contained in:
@@ -1096,17 +1096,10 @@ int main(void)
|
||||
continue;
|
||||
}
|
||||
add_l(sm + 32);
|
||||
#ifdef ED25519_PREVENT_MALLEABILITY
|
||||
if (crypto_sign_open(m, &mlen, sm, smlen, test_data[i].pk) != -1) {
|
||||
printf("crypto_sign_open(): signature [%u] is malleable\n", i);
|
||||
continue;
|
||||
}
|
||||
#else
|
||||
if (crypto_sign_open(m, &mlen, sm, smlen, test_data[i].pk) != 0) {
|
||||
printf("crypto_sign_open(): signature [%u] is not malleable\n", i);
|
||||
continue;
|
||||
}
|
||||
#endif
|
||||
if (memcmp(test_data[i].m, m, (size_t)mlen) != 0) {
|
||||
printf("message verification failure: [%u]\n", i);
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user