mirror of
https://github.com/google/nomulus
synced 2026-01-05 13:07:04 +00:00
Reduce log level to info when no email is found from the OIDC token (#2694)
This can happen on public endpoints (in pubapi) where the service is behind IAP but all users (including not-logged-in ones) are allowed. IAP will add an OIDC token with no email field in the request header.
This commit is contained in:
@@ -106,7 +106,7 @@ public abstract class OidcTokenAuthenticationMechanism implements Authentication
|
||||
|
||||
String email = (String) token.getPayload().get("email");
|
||||
if (email == null) {
|
||||
logger.atWarning().log("No email address from the OIDC token:\n%s", token.getPayload());
|
||||
logger.atInfo().log("No email address from the OIDC token:\n%s", token.getPayload());
|
||||
return AuthResult.NOT_AUTHENTICATED;
|
||||
}
|
||||
Optional<User> maybeUser =
|
||||
|
||||
Reference in New Issue
Block a user