X-Git-Url: https://the.earth.li/gitweb/?p=onak.git;a=blobdiff_plain;f=sigcheck.c;h=31932bc02f63d7c78d0bfe57bb7f220640977a01;hp=ff806046b3d9866b657bb8afc3fd39cb6e54ee36;hb=8e4c1600cae6c6d71ec0c8843d11354842a4feba;hpb=a000448ed7ca6932cf1a7936fa43e56395b16f77 diff --git a/sigcheck.c b/sigcheck.c index ff80604..31932bc 100644 --- a/sigcheck.c +++ b/sigcheck.c @@ -49,13 +49,13 @@ #include #include "rsa.h" -#ifndef nettle_get_secp_256r1 +#ifndef HAVE_NETTLE_GET_SECP_256R1 #define nettle_get_secp_256r1() &nettle_secp_256r1 #endif -#ifndef nettle_get_secp_384r1 +#ifndef HAVE_NETTLE_GET_SECP_384R1 #define nettle_get_secp_384r1() &nettle_secp_384r1 #endif -#ifndef nettle_get_secp_521r1 +#ifndef HAVE_NETTLE_GET_SECP_521R1 #define nettle_get_secp_521r1() &nettle_secp_521r1 #endif @@ -409,6 +409,7 @@ onak_status_t onak_check_hash_sig(struct openpgp_publickey *sigkey, ret = ecdsa_verify(&pubkey.ecc, SHA1_DIGEST_SIZE, hash, &dsasig) ? ONAK_E_OK : ONAK_E_BAD_SIGNATURE; + break; case KEYHASH(OPENPGP_PKALGO_ECDSA, OPENPGP_HASH_SHA256): ret = ecdsa_verify(&pubkey.ecc, SHA256_DIGEST_SIZE, hash, &dsasig) ?