We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 31278ee commit 584ded1Copy full SHA for 584ded1
1 file changed
wolfcrypt/src/falcon.c
@@ -700,6 +700,14 @@ int wc_falcon_check_key(falcon_key* key)
700
return BAD_FUNC_ARG;
701
}
702
703
+ if ((key->level != 1) && (key->level != 5)) {
704
+ return BAD_FUNC_ARG;
705
+ }
706
+
707
+ if (!key->pubKeySet || !key->prvKeySet) {
708
+ return PUBLIC_KEY_E;
709
710
711
/* The public key is also decoded and stored within the private key buffer
712
* behind the private key. Hence, we can compare both stored public keys. */
713
if (key->level == 1) {
0 commit comments