Package jakarta.mvc.security
Class CsrfValidationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- jakarta.mvc.security.CsrfValidationException
-
- All Implemented Interfaces:
Serializable
public class CsrfValidationException extends RuntimeException
This exception is thrown by the MVC implementation if the CSRF token validation fails. By default, this will result in a 403 status code sent to the client. The application can provide a custom exception mapper for this exception type to customize this default behavior.- Since:
- 1.0
- Author:
- Christian Kaltepoth
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CsrfValidationException(String message)
Create a new CsrfValidationException
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
CsrfValidationException
public CsrfValidationException(String message)
Create a new CsrfValidationException- Parameters:
message
- the detail message
-
-