Class DeviceVerificationRateLimitedException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.springframework.security.core.AuthenticationException
org.springframework.security.oauth2.core.OAuth2AuthenticationException
com.irurueta.authserver.authorization.api.web.implicit.DeviceVerificationRateLimitedException
- All Implemented Interfaces:
Serializable
public class DeviceVerificationRateLimitedException
extends org.springframework.security.oauth2.core.OAuth2AuthenticationException
Raised while a device verification request is converted when its client address or user made too many attempts. The
error handler of the endpoint answers
429 with a Retry-After header instead of the framework's
usual 400.- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDeviceVerificationRateLimitedException(Duration retryAfter) Creates the exception. -
Method Summary
Modifier and TypeMethodDescriptionTells how long until the attempts are accepted again.Methods inherited from class org.springframework.security.oauth2.core.OAuth2AuthenticationException
getErrorMethods inherited from class org.springframework.security.core.AuthenticationException
getAuthenticationRequest, setAuthenticationRequestMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
ERROR_CODE
Error code of the exception.- See Also:
-
serialVersionUID
private static final long serialVersionUIDSerial version.- See Also:
-
retryAfter
How long until the window ends and the attempts are accepted again.
-
-
Constructor Details
-
DeviceVerificationRateLimitedException
Creates the exception.- Parameters:
retryAfter- how long until the attempts are accepted again.
-
-
Method Details
-
retryAfter
Tells how long until the attempts are accepted again.- Returns:
- the time to wait.
-