Browse Source

Polish Exception Message

This error message provides more context around which credentials failed.

Issue gh-16494
pull/15853/head
Josh Cummings 10 months ago
parent
commit
43ddf73ddb
No known key found for this signature in database
GPG Key ID: 869B37A20E876129
  1. 2
      core/src/main/java/org/springframework/security/authentication/ott/OneTimeTokenAuthenticationProvider.java

2
core/src/main/java/org/springframework/security/authentication/ott/OneTimeTokenAuthenticationProvider.java

@ -62,7 +62,7 @@ public final class OneTimeTokenAuthenticationProvider implements AuthenticationP @@ -62,7 +62,7 @@ public final class OneTimeTokenAuthenticationProvider implements AuthenticationP
return authenticated;
}
catch (UsernameNotFoundException ex) {
throw new BadCredentialsException("Authentication failed.");
throw new BadCredentialsException("Failed to authenticate the one-time token");
}
}

Loading…
Cancel
Save