Skip to content

Commit

Permalink
Compare emails lowerstring
Browse files Browse the repository at this point in the history
  • Loading branch information
ccorsin committed Sep 9, 2024
1 parent e96de12 commit 635b66c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crate/server/src/routes/google_cse/jwt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ pub(crate) async fn validate_tokens(

// The emails should match (case insensitive)
kms_ensure!(
authorization_email == authentication_email,
authorization_email.to_lowercase() == authentication_email.to_lowercase(),
KmsError::Unauthorized(
"Authentication and authorization emails in tokens do not match".to_string()
)
Expand Down

0 comments on commit 635b66c

Please sign in to comment.