public final class NullConfigurationProvider extends Object implements ConfigurationProvider
ConfigurationProvider which returns all null or empty values (except for the logger).
Used before initialization has occurred.| Constructor and Description |
|---|
NullConfigurationProvider() |
| Modifier and Type | Method and Description |
|---|---|
List<IAction> |
getActions() |
Set<String> |
getBannedUserAgentProperties() |
String |
getDomainOrigin()
TODO Currently not configurable through the properties!
|
String |
getJavascriptCacheControl() |
String |
getJavascriptDynamicNodeCreationEventName() |
Pattern |
getJavascriptRefererPattern() |
String |
getJavascriptTaggedCacheControl() |
String |
getJavascriptTemplateCode() |
String |
getJavascriptUnprotectedExtensions()
example: "js,css,gif,png,ico,jpg"
|
String |
getJavascriptXrequestedWith()
TODO document
|
LogicalSessionExtractor |
getLogicalSessionExtractor() |
String |
getNewTokenLandingPage() |
Duration |
getPageTokenSynchronizationTolerance() |
SecureRandom |
getPrng() |
Set<String> |
getProtectedMethods() |
Set<String> |
getProtectedPages() |
TokenHolder |
getTokenHolder() |
int |
getTokenLength()
This parameter controls how long a generated token should be.
|
String |
getTokenName() |
Set<String> |
getUnprotectedMethods()
if there are methods here, then all other HTTP methods are protected and these (e.g.
|
Set<String> |
getUnprotectedPages() |
void |
initializeJavaScriptConfiguration()
JavaScript configuration parameters can be set/overwritten via the servlet configuration.
|
boolean |
isAjaxEnabled() |
boolean |
isCacheable() |
boolean |
isEnabled()
if the filter is enabled
|
boolean |
isForceSynchronousAjax() |
boolean |
isJavascriptDomainStrict() |
boolean |
isJavascriptInjectFormAttributes()
if the token should be injected in the action in forms
note, if injectIntoForms is true, then this might not need to be true
|
boolean |
isJavascriptInjectGetForms()
if the token should be injected in GET forms (which will be on the URL)
if the HTTP method GET is unprotected, then this should likely be false
|
boolean |
isJavascriptInjectIntoAttributes() |
boolean |
isJavascriptInjectIntoDynamicallyCreatedNodes() |
boolean |
isJavascriptInjectIntoForms() |
boolean |
isJavascriptRefererMatchDomain()
if the referer to the javascript must match domain
|
boolean |
isJavascriptRefererMatchProtocol()
if the referer to the javascript must match the protocol of the domain
|
boolean |
isPrintConfig() |
boolean |
isProtectEnabled()
The default behavior of CSRFGuard is to protect all pages.
|
boolean |
isRotateEnabled() |
boolean |
isTokenPerPageEnabled() |
boolean |
isTokenPerPagePrecreateEnabled() |
boolean |
isUseNewTokenLandingPage() |
boolean |
isValidateWhenNoSessionExists()
If csrf guard filter should check even if there is no session for the user
Note: this changed around 2014/04, the default behavior used to be to
not check if there is no session.
|
public boolean isCacheable()
isCacheable in interface ConfigurationProviderpublic boolean isPrintConfig()
isPrintConfig in interface ConfigurationProviderpublic String getTokenName()
getTokenName in interface ConfigurationProviderpublic boolean isValidateWhenNoSessionExists()
ConfigurationProviderisValidateWhenNoSessionExists in interface ConfigurationProviderpublic int getTokenLength()
ConfigurationProvidergetTokenLength in interface ConfigurationProviderpublic boolean isRotateEnabled()
isRotateEnabled in interface ConfigurationProviderpublic boolean isTokenPerPageEnabled()
isTokenPerPageEnabled in interface ConfigurationProviderpublic boolean isTokenPerPagePrecreateEnabled()
isTokenPerPagePrecreateEnabled in interface ConfigurationProviderpublic SecureRandom getPrng()
getPrng in interface ConfigurationProviderpublic String getNewTokenLandingPage()
getNewTokenLandingPage in interface ConfigurationProviderpublic boolean isUseNewTokenLandingPage()
isUseNewTokenLandingPage in interface ConfigurationProviderConfigurationProvider.getNewTokenLandingPage()public boolean isAjaxEnabled()
isAjaxEnabled in interface ConfigurationProviderpublic boolean isProtectEnabled()
ConfigurationProviderisProtectEnabled in interface ConfigurationProviderpublic boolean isForceSynchronousAjax()
isForceSynchronousAjax in interface ConfigurationProviderpublic Set<String> getProtectedPages()
getProtectedPages in interface ConfigurationProviderpublic Set<String> getUnprotectedPages()
getUnprotectedPages in interface ConfigurationProviderpublic Set<String> getProtectedMethods()
getProtectedMethods in interface ConfigurationProviderpublic Set<String> getUnprotectedMethods()
ConfigurationProvidergetUnprotectedMethods in interface ConfigurationProviderpublic Set<String> getBannedUserAgentProperties()
getBannedUserAgentProperties in interface ConfigurationProviderpublic boolean isEnabled()
ConfigurationProviderisEnabled in interface ConfigurationProviderpublic List<IAction> getActions()
getActions in interface ConfigurationProviderpublic boolean isJavascriptDomainStrict()
isJavascriptDomainStrict in interface ConfigurationProviderpublic String getDomainOrigin()
ConfigurationProvidergetDomainOrigin in interface ConfigurationProviderpublic String getJavascriptCacheControl()
getJavascriptCacheControl in interface ConfigurationProviderpublic String getJavascriptTaggedCacheControl()
getJavascriptTaggedCacheControl in interface ConfigurationProviderpublic Pattern getJavascriptRefererPattern()
getJavascriptRefererPattern in interface ConfigurationProviderpublic void initializeJavaScriptConfiguration()
ConfigurationProviderinitializeJavaScriptConfiguration in interface ConfigurationProviderpublic boolean isJavascriptInjectGetForms()
ConfigurationProviderisJavascriptInjectGetForms in interface ConfigurationProviderpublic boolean isJavascriptInjectFormAttributes()
ConfigurationProviderisJavascriptInjectFormAttributes in interface ConfigurationProviderpublic boolean isJavascriptInjectIntoForms()
isJavascriptInjectIntoForms in interface ConfigurationProviderpublic boolean isJavascriptRefererMatchProtocol()
ConfigurationProviderisJavascriptRefererMatchProtocol in interface ConfigurationProviderpublic boolean isJavascriptRefererMatchDomain()
ConfigurationProviderisJavascriptRefererMatchDomain in interface ConfigurationProviderpublic boolean isJavascriptInjectIntoAttributes()
isJavascriptInjectIntoAttributes in interface ConfigurationProviderpublic boolean isJavascriptInjectIntoDynamicallyCreatedNodes()
isJavascriptInjectIntoDynamicallyCreatedNodes in interface ConfigurationProviderpublic String getJavascriptDynamicNodeCreationEventName()
getJavascriptDynamicNodeCreationEventName in interface ConfigurationProviderpublic String getJavascriptXrequestedWith()
ConfigurationProvidergetJavascriptXrequestedWith in interface ConfigurationProviderpublic String getJavascriptTemplateCode()
getJavascriptTemplateCode in interface ConfigurationProviderpublic String getJavascriptUnprotectedExtensions()
ConfigurationProvidergetJavascriptUnprotectedExtensions in interface ConfigurationProviderpublic TokenHolder getTokenHolder()
getTokenHolder in interface ConfigurationProviderpublic LogicalSessionExtractor getLogicalSessionExtractor()
getLogicalSessionExtractor in interface ConfigurationProviderpublic Duration getPageTokenSynchronizationTolerance()
getPageTokenSynchronizationTolerance in interface ConfigurationProviderCopyright © 2025 OWASP. All rights reserved.