Skip to content

Commit

Permalink
Fix wrong public key deletion
Browse files Browse the repository at this point in the history
This was introduced by rebasing on top of the rsa-backend migration
This should not be done since public keys are expected to be stored in persistent
storage since they can't be lazily derived from the private part that is encrypted
  • Loading branch information
sosthene-nitrokey committed Mar 30, 2023
1 parent 0199012 commit bd0dae6
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/command/gen.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,6 @@ fn read_rsa_key<const R: usize, T: trussed::Client + AuthClient>(
let parsed_pubkey_data: RsaPublicParts =
trussed::postcard_deserialize(&pubkey_data).map_err(|_err| {
error!("Failed to deserialize public key");
syscall!(client.delete(public_key));
Status::UnspecifiedNonpersistentExecutionError
})?;
ctx.reply.expand(&[0x81])?;
Expand Down

0 comments on commit bd0dae6

Please sign in to comment.