Skip to content

Commit

Permalink
chore: fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
blckngm committed Aug 21, 2023
1 parent 595697d commit fec3a12
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.58.1
toolchain: 1.71.0
default: true
profile: minimal
components: rustfmt, clippy
Expand Down
14 changes: 7 additions & 7 deletions src/ecdsa.rs
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,8 @@ impl PublicKeyToJwk for EcdsaPrivateKey {
kty: "EC".into(),
use_: Some("sig".into()),
crv: Some(self.algorithm.curve_name().into()),
x: Some(base64::encode_config(&x, url_safe_trailing_bits())),
y: Some(base64::encode_config(&y, url_safe_trailing_bits())),
x: Some(base64::encode_config(x, url_safe_trailing_bits())),
y: Some(base64::encode_config(y, url_safe_trailing_bits())),
..Default::default()
})
}
Expand All @@ -211,9 +211,9 @@ impl PrivateKeyToJwk for EcdsaPrivateKey {
kty: "EC".into(),
use_: Some("sig".into()),
crv: Some(self.algorithm.curve_name().into()),
d: Some(base64::encode_config(&d, url_safe_trailing_bits())),
x: Some(base64::encode_config(&x, url_safe_trailing_bits())),
y: Some(base64::encode_config(&y, url_safe_trailing_bits())),
d: Some(base64::encode_config(d, url_safe_trailing_bits())),
x: Some(base64::encode_config(x, url_safe_trailing_bits())),
y: Some(base64::encode_config(y, url_safe_trailing_bits())),
..Default::default()
})
}
Expand Down Expand Up @@ -307,8 +307,8 @@ impl PublicKeyToJwk for EcdsaPublicKey {
kty: "EC".into(),
use_: Some("sig".into()),
crv: Some(self.algorithm.curve_name().into()),
x: Some(base64::encode_config(&x, url_safe_trailing_bits())),
y: Some(base64::encode_config(&y, url_safe_trailing_bits())),
x: Some(base64::encode_config(x, url_safe_trailing_bits())),
y: Some(base64::encode_config(y, url_safe_trailing_bits())),
..Default::default()
})
}
Expand Down
8 changes: 4 additions & 4 deletions src/eddsa.rs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ impl PublicKeyToJwk for Ed25519PrivateKey {
Ok(Jwk {
kty: "OKP".into(),
crv: Some("Ed25519".into()),
x: Some(base64::encode_config(&bytes, url_safe_trailing_bits())),
x: Some(base64::encode_config(bytes, url_safe_trailing_bits())),
..Jwk::default()
})
}
Expand All @@ -113,8 +113,8 @@ impl PrivateKeyToJwk for Ed25519PrivateKey {
Ok(Jwk {
kty: "OKP".into(),
crv: Some("Ed25519".into()),
d: Some(base64::encode_config(&d, url_safe_trailing_bits())),
x: Some(base64::encode_config(&x, url_safe_trailing_bits())),
d: Some(base64::encode_config(d, url_safe_trailing_bits())),
x: Some(base64::encode_config(x, url_safe_trailing_bits())),
..Jwk::default()
})
}
Expand Down Expand Up @@ -181,7 +181,7 @@ impl PublicKeyToJwk for Ed25519PublicKey {
Ok(Jwk {
kty: "OKP".into(),
crv: Some("Ed25519".into()),
x: Some(base64::encode_config(&bytes, url_safe_trailing_bits())),
x: Some(base64::encode_config(bytes, url_safe_trailing_bits())),
..Jwk::default()
})
}
Expand Down
4 changes: 2 additions & 2 deletions src/jwk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -350,8 +350,8 @@ impl JwkSetVerifier {
} else if !self.require_kid {
if let Some(res) = self
.keys
.iter()
.map(|(_, key)| verifier(token, key))
.values()
.map(|key| verifier(token, key))
.find_map(|res| res.ok())
{
Ok(res)
Expand Down

0 comments on commit fec3a12

Please sign in to comment.