80379[BUGFIX] Keep the honeypot name in the form state
Commit message
Review
-
Code review CR +2 Done
- Georg Ringer +2
- Josua Vogel +1
-
Verified V +2 Done
- Georg Ringer +2
- Josua Vogel +1
- core-ci +1 CI
Issues 3
Files 6
- typo3/sysext/core/Documentation/Changelog/14.3.x/Important-101562-HoneypotNameIsStoredInTheFormState.rstnew+63 −0
- typo3/sysext/form/Classes/Domain/Runtime/FormRuntime.php4+17 −61
- typo3/sysext/form/Classes/Domain/Runtime/FormState.php+15 −0
- typo3/sysext/form/Documentation/I/Config/proto/form/renderingOptions/honeypot/enable.rst.txt+3 −32
- typo3/sysext/form/Documentation/I/FAQ/Index.rst+0 −10
- typo3/sysext/form/Tests/Functional/RequestHandling/RequestHandlingTest.php+65 −0
Review log 2740
Show 1015 earlier messages
-
Tim Schreiner uploaded patch set 1 08/03/23, 22:28
-
core-ci voted on patch set 1 V -1 08/03/23, 22:44 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45011
-
Tim Schreiner uploaded patch set 2
V -108/04/23, 08:32 -
core-ci voted on patch set 2 V -1 08/04/23, 08:48 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45028
-
Tim Schreiner commented on patch set 2 08/04/23, 08:51
The intention of this MR is to fix this bug. There might be better solution that needs more code and maybe new concepts, but this bug currently leads to spam problems in forms because the honeypot could easily be bypassed when there is no cookie set.AbstractExceptionHandler.php:50I would like to exclude the exception in the logging because bots might spam the logs when trying to send forms.FormRuntime.php:420I removed the page identifier as part of the session identifier which holds the honeypot name because it might break the form handling. The honeypot name is generated on the first form call (GET). When the form request is once submitted, the honeypot name will be fetched from the request/session. With the included page identifier, the initial honeypot name is generated for page-1. When the for got submitted from page-2, there is no session identifier holding the honeypot name for this page and it is empty. This might be the reason, why the condition for the honeypot evaluation exists in the first place. But I'm not sure, if my change leads to another set of problems. I would be happy if someone could evaluate this.FormRuntime.php:428There might be a better solution than throwing an exception, but when there is no honeypot name, there is no element to bind a validation error to. Maybe it is an option to add a validation error to the form object itself instead of a child node. -
Tim Schreiner commented on patch set 2 08/04/23, 13:05
Another problem is, that the form framework CE is cached. Therefore the session cookie is not set and there is no unique name for the honeypot field generated. I suggest thinking about changing the behaviour, how the honeypot name is generated. Maybe the name for the honeypot could be an hmac. Therefore the name would be different between systems but could be build anytime it needs to. There would be no need to store it in a session. -
Tim Schreiner uploaded patch set 3
V -108/04/23, 13:24 -
Tim Schreiner updated the commit message in patch set 4 08/04/23, 13:29
-
Tim Schreiner commented on patch set 4 08/04/23, 13:33
I have updated this review and changed the handling of the honeypot name. The honeypot name is now generated using a static string from that an hmac is build. There is no need to store this in the session because it can be regenerated. This is not a perfect solution but it should be an improvement to the current state in which the honeypot is getting ignored when no honeypot name could be fetched from the session.AbstractExceptionHandler.php:50ReplyDoneFormRuntime.php:420ReplyDoneFormRuntime.php:428ReplyDone -
core-ci voted on patch set 3 V +1 08/04/23, 13:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45068
-
core-ci voted on patch set 4 V +1 08/04/23, 13:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45070
-
Tim Schreiner uploaded patch set 5
V +108/04/23, 13:37 -
core-ci voted on patch set 5 V +1 08/04/23, 13:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45071
-
Oliver Wand voted on patch set 5 CR +1 08/04/23, 15:55
-
Tim Schreiner rebased onto patch set 6
CR +1V +103/04/24, 14:36
-
core-ci voted on patch set 6 V +1 03/04/24, 14:44 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/53857
-
Benni Mack updated the commit message in patch set 7
V +110/18/24, 13:23 -
core-ci voted on patch set 7 V -1 10/18/24, 19:49 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/67960
-
Benni Mack wrote 03/28/25, 09:18
Topic set to form -
Thomas Löffler voted on patch set 7 CR +1 01/19/26, 10:19
-
Josua Vogel uploaded patch set 8
CR +1V -103/06/26, 10:12 -
core-ci voted on patch set 8 V +1 03/06/26, 10:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/97481
-
Josua Vogel updated the commit message in patch set 9
V +103/06/26, 12:29 -
core-ci voted on patch set 9 V +1 03/06/26, 13:15 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/97497
-
Benni Mack updated the commit message in patch set 10
V +104/22/26, 06:41 -
core-ci voted on patch set 10 V -1 04/22/26, 11:01 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/100764
-
Georg Ringer uploaded patch set 11
V -109/28/26, 21:09 -
core-ci voted on patch set 11 V -1 09/28/26, 21:23 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109460
-
Georg Ringer rebased onto patch set 12
V -109/28/26, 21:25 -
core-ci voted on patch set 12 V +1 09/28/26, 21:34 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109463
-
Josua Vogel uploaded patch set 13
V +110/15/26, 21:44 -
Josua Vogel commented on patch set 13 10/15/26, 21:45
I changed the fix to a slightly different approach. If you don´t like it, feel free to roll back -
core-ci voted on patch set 13 V +1 10/15/26, 21:52 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111284
-
Josua Vogel voted on patch set 13 CR +1 V +1 10/15/26, 21:56
-
Georg Ringer voted on patch set 13 CR +2 V +2 10/16/26, 06:25
-
Georg Ringer commented on patch set 13 CR -2 10/16/26, 06:39
need to check -
Georg Ringer commented on patch set 13 CR 0 V 0 10/16/26, 13:47
not so sure about it ---- Weaker protection with the new approach. The honeypot name is no longer bound to the session. A bot can save a valid state together with its honeypot name and reuse it as often as it likes. With static file caching, the name is the same for every visitor. The changelog states this openly, and it is still better than no validation at all. But the "rotating" property of the honeypot is lost. -
Georg Ringer voted on patch set 13 CR +1 V +1 10/16/26, 17:44
-
Georg Ringer voted on patch set 13 CR +2 V +2 10/16/26, 17:44
-
Georg Ringer merged patch set 14 10/16/26, 17:44