Releases: dominiquevienne/honeypot
Minor class bug resolution for Drupal FAPI elements
A simple update on FAPI elements. Class is intended to be an array.
Drupal 8 FAPI - Bugs resolution
Some bugs were detected when integrating Honeypot in Drupal modules due to the way Drupal FAPI instanciate forms.
Honeypot and token values were unreachable which has been corrected.
Increase failure counter on check is public
The increaseFailureCounter() function is now public so any developer can increase this counter on data validation in addition of honeypot specific checks.
Timer is also resetted after check in order to get the right value.
Drupal FAPI fields
This version enables the possibility to output Drupal FAPI elements instead of RAW HTML.
Documentation has been updated and example added.
Token field type is hidden
Default value for token field type is now hidden
Possibility has been added to set this value through configuration array on object construct
Code of conduct and Contributing
This release includes code of conduct and contributing guidelines.
Minor version.
Working example
In this release, two updates:
- resolving a minor bug happening on check when form submission is a success (tried to access a non-defined index in $_SESSION)
- added a working example in "example" directory. Please read comments in order to make it work.
More doc on JS
The readme.md has been updated concerning JS script that will, by defaut, remove the honeypot field.
JS Field remover
In this release, we added a Javascript that will automatically remove the Honeypot form field from the DOM.
Bots majority do not enable Javascript so this will lead to a more difficult task to pass the tests.
No need for any JS framework like jQuery... only pure JS!
A bunch of checks
This release contains all necessary checks for a Honeypot.
- timeCheck: minimum form completion time
- honeypotCheck: presence of an empty value in generated input
- tokenCheck: presence of a valid auto-generated token
- failureCheck: maximum failure attempts check
- quantityCheck: maximum attempts checks
Any of these checks could be configured through constructor or using specific functions.