Skip to content

Commit

Permalink
Fixed some errors during build that was not caught during tests
Browse files Browse the repository at this point in the history
Signed-off-by: Fredrik Skogman <kommendorkapten@github.com>
  • Loading branch information
kommendorkapten committed Mar 14, 2024
1 parent ecc8cbf commit 2388793
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions tough/src/schema/key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,11 +157,8 @@ impl Key {
scheme: EcdsaScheme::EcdsaSha2Nistp256,
keyval,
..
} => (
&ring::signature::ECDSA_P256_SHA256_ASN1,
untrusted::Input::from(&keyval.public),
),
Key::EcdsaOld {
}
| Key::EcdsaOld {
scheme: EcdsaScheme::EcdsaSha2Nistp256,
keyval,
..
Expand Down Expand Up @@ -231,15 +228,6 @@ impl FromStr for Key {
scheme: EcdsaScheme::EcdsaSha2Nistp256,
_extra: HashMap::new(),
})
} else if let Ok(public) = serde_plain::from_str::<Decoded<EcdsaFlex>>(s) {
Ok(Key::EcdsaOld {
keyval: EcdsaKey {
public,
_extra: HashMap::new(),
},
scheme: EcdsaScheme::EcdsaSha2Nistp256,
_extra: HashMap::new(),
})
} else {
Err(KeyParseError(()))
}
Expand Down

0 comments on commit 2388793

Please sign in to comment.