[FEATURE] Enhance form protection and add class for frontend 26/43426/12
authorHelmut Hummel <helmut.hummel@typo3.org>
Fri, 18 Sep 2015 15:24:03 +0000 (17:24 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Sat, 24 Oct 2015 14:48:54 +0000 (16:48 +0200)
commitb118b0847f32ae6f6234566b8f786c697293d558
treea04d8333faeaf513b85ac0b9478da94d97d1264f
parent12218cdb4f93cf22e13aa1f92aa5b7850b678773
[FEATURE] Enhance form protection and add class for frontend

This change adds API for CSRF protection in the frontend.
The usage is exactly the same as for backend modules, except
that the factory now returns a proper implementation for frontend.

The refactoring enabled a massive cleanup of the tests as the classes
now properly use dependency inversion.

Resolves: #56633
Releases: master
Change-Id: I7a9710215c38fda705fea62827419f63abdd2dc1
Reviewed-on: https://review.typo3.org/43426
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Stephan GroƟberndt <stephan@grossberndt.de>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
12 files changed:
typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php
typo3/sysext/core/Classes/FormProtection/AbstractFormProtection.php
typo3/sysext/core/Classes/FormProtection/BackendFormProtection.php
typo3/sysext/core/Classes/FormProtection/DisabledFormProtection.php
typo3/sysext/core/Classes/FormProtection/FormProtectionFactory.php
typo3/sysext/core/Classes/FormProtection/FrontendFormProtection.php [new file with mode: 0644]
typo3/sysext/core/Classes/FormProtection/InstallToolFormProtection.php
typo3/sysext/core/Documentation/Changelog/master/Feature-56633-FormProtectionAPIForFrontEndUsage.rst [new file with mode: 0644]
typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php
typo3/sysext/core/Tests/Unit/FormProtection/BackendFormProtectionTest.php
typo3/sysext/core/Tests/Unit/FormProtection/Fixtures/FormProtectionTesting.php
typo3/sysext/core/Tests/Unit/FormProtection/FormProtectionFactoryTest.php