Skip to content

Commit

Permalink
fuzz_pkcs15init.c formating
Browse files Browse the repository at this point in the history
 Changes to be committed:
	modified:   tests/fuzzing/fuzz_pkcs15init.c
  • Loading branch information
dengert committed Jan 6, 2025
1 parent 0637be0 commit 8d210f1
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/tests/fuzzing/fuzz_pkcs15init.c
Original file line number Diff line number Diff line change
Expand Up @@ -243,16 +243,16 @@ void do_store_secret_key(struct sc_profile *profile, struct sc_pkcs15_card *p15c
sc_pkcs15_format_id("02", &(args.auth_id));

for (int i = 0; i < 3; i++) {
size_t keybytes = BYTES4BITS(keybits[i]);
args.key.data = malloc(keybytes);
memcpy(args.key.data, buf, keybytes);
args.key.data_len = keybytes;
args.algorithm = algorithms[i];
args.value_len = keybits[i];

sc_pkcs15init_store_secret_key(p15card, profile, &args, NULL);
if (args.key.data)
free(args.key.data);
size_t keybytes = BYTES4BITS(keybits[i]);
args.key.data = malloc(keybytes);
memcpy(args.key.data, buf, keybytes);
args.key.data_len = keybytes;
args.algorithm = algorithms[i];
args.value_len = keybits[i];

sc_pkcs15init_store_secret_key(p15card, profile, &args, NULL);
if (args.key.data)
free(args.key.data);
}
}

Expand Down

0 comments on commit 8d210f1

Please sign in to comment.