Add RSA3072 algorithm

This commit is contained in:
Sosthène Guédon
2025-03-06 09:55:34 +01:00
committed by sosthene-nitrokey
parent f869f4f741
commit 9bde6956ef
6 changed files with 94 additions and 10 deletions
+7 -1
View File
@@ -458,8 +458,14 @@ impl IoCmd {
.into_iter()
.flatten()
.collect();
let algo = match p.len() {
128 => 0x07,
192 => 0x05,
256 => 0x16,
_ => panic!("Invalid RSA key size"),
};
Self::run_bytes(
&build_command(0x00, 0xFE, 0x07, 0x9A, &data, 0),
&build_command(0x00, 0xFE, algo, 0x9A, &data, 0),
&MATCH_EMPTY,
expected_status,
card,