public final class DefaultCsrfToken extends java.lang.Object implements CsrfToken
Constructor and Description |
---|
DefaultCsrfToken(java.lang.String headerName,
java.lang.String parameterName,
java.lang.String token)
Creates a new instance
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getHeaderName()
Gets the HTTP header that the CSRF is populated on the response and can be placed
on requests instead of the parameter.
|
java.lang.String |
getParameterName()
Gets the HTTP parameter name that should contain the token.
|
java.lang.String |
getToken()
Gets the token value.
|
public DefaultCsrfToken(java.lang.String headerName, java.lang.String parameterName, java.lang.String token)
headerName
- the HTTP header name to useparameterName
- the HTTP parameter name to usetoken
- the value of the token (i.e. expected value of the HTTP parameter of
parametername).public java.lang.String getHeaderName()
CsrfToken
getHeaderName
in interface CsrfToken
public java.lang.String getParameterName()
CsrfToken
getParameterName
in interface CsrfToken