Skip to content

Commit

Permalink
encoder: Fix printing Ed448 keys
Browse files Browse the repository at this point in the history
Signed-off-by: Jakub Jelen <[email protected]>
  • Loading branch information
Jakuje authored and simo5 committed Jan 13, 2025
1 parent c9e5fcb commit a68e1bd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/encoder.c
Original file line number Diff line number Diff line change
Expand Up @@ -970,7 +970,7 @@ static int p11prov_ec_edwards_encoder_encode_text(
P11PROV_OBJ *key = (P11PROV_OBJ *)inkey;
CK_KEY_TYPE type;
CK_ULONG keysize;
const char *type_name = "ED25519";
const char *type_name = ED25519;
char *uri = NULL;
BIO *out;
int ret;
Expand All @@ -990,8 +990,8 @@ static int p11prov_ec_edwards_encoder_encode_text(
}

keysize = p11prov_obj_get_key_bit_size(key);
if (keysize == 448) {
type_name = "ED448";
if (keysize == ED448_BIT_SIZE) {
type_name = ED448;
}
if (selection & OSSL_KEYMGMT_SELECT_PRIVATE_KEY) {
CK_OBJECT_CLASS class = p11prov_obj_get_class(key);
Expand Down

0 comments on commit a68e1bd

Please sign in to comment.