Skip to content

Commit

Permalink
fix typo
Browse files Browse the repository at this point in the history
Signed-off-by: Marc Schoolderman <[email protected]>
  • Loading branch information
tweedegolf-marc committed Jun 25, 2024
1 parent 57528e3 commit 11b392a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions tsp/src/crypto/nonconfidential.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ pub fn verify<'a>(
let view = crate::cesr::decode_envelope_mut(tsp_message)?;

// verify outer signature
let verification_challange = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challange.signature);
let verification_challenge = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challenge.signature);
let verifying_key = ed25519_dalek::VerifyingKey::from_bytes(sender.verifying_key())?;
verifying_key.verify_strict(verification_challange.signed_data, &signature)?;
verifying_key.verify_strict(verification_challenge.signed_data, &signature)?;

// decode envelope
let DecodedEnvelope {
Expand Down
6 changes: 3 additions & 3 deletions tsp/src/crypto/tsp_hpke.rs
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,10 @@ where
let view = crate::cesr::decode_envelope_mut(tsp_message)?;

// verify outer signature
let verification_challange = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challange.signature);
let verification_challenge = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challenge.signature);
let verifying_key = ed25519_dalek::VerifyingKey::from_bytes(sender.verifying_key())?;
verifying_key.verify_strict(verification_challange.signed_data, &signature)?;
verifying_key.verify_strict(verification_challenge.signed_data, &signature)?;

// decode envelope
let DecodedEnvelope {
Expand Down
6 changes: 3 additions & 3 deletions tsp/src/crypto/tsp_nacl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ pub(crate) fn open<'a>(
let view = crate::cesr::decode_envelope_mut(tsp_message)?;

// verify outer signature
let verification_challange = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challange.signature);
let verification_challenge = view.as_challenge();
let signature = ed25519_dalek::Signature::from(verification_challenge.signature);
let verifying_key = ed25519_dalek::VerifyingKey::from_bytes(sender.verifying_key())?;
verifying_key.verify_strict(verification_challange.signed_data, &signature)?;
verifying_key.verify_strict(verification_challenge.signed_data, &signature)?;

// decode envelope
let DecodedEnvelope {
Expand Down

0 comments on commit 11b392a

Please sign in to comment.