Support Serialization in Exceptions
Issue gh-16276
This commit is contained in:
@@ -16,6 +16,8 @@
|
||||
|
||||
package org.springframework.security.oauth2.server.resource;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
import org.springframework.security.oauth2.core.OAuth2AuthenticationException;
|
||||
|
||||
/**
|
||||
@@ -26,6 +28,9 @@ import org.springframework.security.oauth2.core.OAuth2AuthenticationException;
|
||||
*/
|
||||
public class InvalidBearerTokenException extends OAuth2AuthenticationException {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 6904689954809100280L;
|
||||
|
||||
/**
|
||||
* Construct an instance of {@link InvalidBearerTokenException} given the provided
|
||||
* description.
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
|
||||
package org.springframework.security.oauth2.server.resource.introspection;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* An exception similar to
|
||||
* {@link org.springframework.security.authentication.BadCredentialsException} that
|
||||
@@ -26,6 +28,9 @@ package org.springframework.security.oauth2.server.resource.introspection;
|
||||
*/
|
||||
public class BadOpaqueTokenException extends OAuth2IntrospectionException {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = -6937847463454551076L;
|
||||
|
||||
public BadOpaqueTokenException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
|
||||
package org.springframework.security.oauth2.server.resource.introspection;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* Base exception for all OAuth 2.0 Introspection related errors
|
||||
*
|
||||
@@ -24,6 +26,9 @@ package org.springframework.security.oauth2.server.resource.introspection;
|
||||
*/
|
||||
public class OAuth2IntrospectionException extends RuntimeException {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = -7327790383594166793L;
|
||||
|
||||
public OAuth2IntrospectionException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user