public.javadoc.org.spincast.plugins.formsprotection.config.SpincastFormsProtectionConfig.html Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of spincast-website Show documentation
Show all versions of spincast-website Show documentation
Source code for the https://www.spincast.org website.
SpincastFormsProtectionConfig (org.spincast:spincast-framework 1.0.0 API)
org.spincast.plugins.formsprotection.config
Interface SpincastFormsProtectionConfig
-
- All Known Implementing Classes:
- SpincastFormsProtectionConfigDefault
public interface SpincastFormsProtectionConfig
Configurations for the Spincast Forms Protection plugin.
-
-
Field Summary
Fields
Modifier and Type
Field and Description
static String
SESSION_VARIABLE_NAME_CSRF_TOKEN
The name of the session variable used to store the
CSRF token id of the user.
-
Method Summary
All Methods Instance Methods Abstract Methods
Modifier and Type
Method and Description
boolean
autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask()
Should this plugin automatically register a scheduled task
that will call SpincastFormsDoubleSubmitProtectionRepository.deleteOldFormsProtectionIds(int)
for cleanup?
int
getDeleteOldDoubleSubmitProtectionIdsScheduledTaskRunEveryNbrMinutes()
If autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask()
is
enabled, the cleanup of old saved protection ids should runs
every X minutes.
String
getFormCsrfProtectionIdFieldName()
The "name" of the hidden field in which a generated
CSRF protection id will be saved in the HTML form.
String
getFormDoubleSubmitDisableProtectionIdFieldName()
The "name" of the hidden field to add to disable the Double Submit
protection on a specific form.
int
getFormDoubleSubmitFormValidForNbrMinutes()
If the SpincastFormsDoubleSubmitProtectionFilter
filter is used,
this is the number of minutes maximum of form will be considered as
valid.
String
getFormDoubleSubmitProtectionIdFieldName()
The "name" of the hidden field in which a generated
Double Submit protection id will be saved in the HTML form.
-
-
Field Detail
-
SESSION_VARIABLE_NAME_CSRF_TOKEN
static final String SESSION_VARIABLE_NAME_CSRF_TOKEN
The name of the session variable used to store the
CSRF token id of the user.
-
Method Detail
-
getFormCsrfProtectionIdFieldName
String getFormCsrfProtectionIdFieldName()
The "name" of the hidden field in which a generated
CSRF protection id will be saved in the HTML form.
-
getFormDoubleSubmitProtectionIdFieldName
String getFormDoubleSubmitProtectionIdFieldName()
The "name" of the hidden field in which a generated
Double Submit protection id will be saved in the HTML form.
-
getFormDoubleSubmitDisableProtectionIdFieldName
String getFormDoubleSubmitDisableProtectionIdFieldName()
The "name" of the hidden field to add to disable the Double Submit
protection on a specific form. (use any value such as "1" for
the field.)
-
autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask
boolean autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask()
Should this plugin automatically register a scheduled task
that will call SpincastFormsDoubleSubmitProtectionRepository.deleteOldFormsProtectionIds(int)
for cleanup?
Note that wathever the value, the scheduled task will only be registered if a proper
implementation of SpincastFormsDoubleSubmitProtectionFilter
was
bound in the first place.
If disabled, you are responsible to register the scheduled task by
yourself, or at least delete those old ids
by yourself.
Defaults to true
.
-
getDeleteOldDoubleSubmitProtectionIdsScheduledTaskRunEveryNbrMinutes
int getDeleteOldDoubleSubmitProtectionIdsScheduledTaskRunEveryNbrMinutes()
If autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask()
is
enabled, the cleanup of old saved protection ids should runs
every X minutes.
-
getFormDoubleSubmitFormValidForNbrMinutes
int getFormDoubleSubmitFormValidForNbrMinutes()
If the SpincastFormsDoubleSubmitProtectionFilter
filter is used,
this is the number of minutes maximum of form will be considered as
valid. Older than that, it will be refused.
If autoRegisterDeleteOldDoubleSubmitProtectionIdsScheduledTask()
is
enabled, the scheduled task will also use this value to decide when to delete old
protection ids.
Defaults to 120 minutes (2 hours).
Copyright © 2019. All rights reserved.