Review main Merged Breaking

91652[!!!][TASK] Avoid $_GET / $_POST safety net

Christian Kuhn CR +2 V +2 Normal +88 −64 updated 12/31/25, 08:34

Commit message

To further streamline the request handling, the
patch removes a fallback layer in backend and
frontend RequestHandler which did reset globals
_GET, _POST, HTTP_GET_VARS and HTTP_POST_VARS
to what has been written to the request object
within middlewares. That b/w compat layer has been
slated for removal in v10/v11 already.

A couple of functional tests need minor modifications
since they actively tested for _GET values.

In the frontend, we also populate $GLOBALS['TYPO3_REQUEST']
a little later and now only do this within RequestHandler.
This was done within PrepareTypoScriptFrontendRendering
middleware until now, so middlewares after that one can now
no longer rely on that global being set. This should be
ok since middlewares of course receive the request and
can actively hand it over to other services like the
ContentObjectRenderer. One middleware is adjusted
accordingly. The ContentObjectRenderer will receive
additional hardening with upcoming patches.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Lina Wolf +1
  • Verified V +2 Done
    • Benni Mack +2
    • Lina Wolf +1
    • core-ci +1 CI

Issues 1

Files 8

Review log 1829

Show 24 earlier messages
  1. Christian Kuhn uploaded patch set 1 11/13/25, 22:26

  2. core-ci voted on patch set 1 V -1 11/13/25, 22:43 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89600

  3. Christian Kuhn uploaded patch set 2 V -1 11/13/25, 22:57

  4. core-ci voted on patch set 2 V -1 11/13/25, 23:11 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89603

  1. Christian Kuhn uploaded patch set 3 V -1 11/13/25, 23:20

  2. core-ci voted on patch set 3 V +1 11/13/25, 23:28 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89604

  3. Christian Kuhn uploaded patch set 4 V +1 11/13/25, 23:41

  4. Christian Kuhn uploaded patch set 5 11/13/25, 23:43

  5. Christian Kuhn uploaded patch set 6 11/13/25, 23:45

  6. core-ci voted on patch set 4 V +1 11/13/25, 23:51 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89606

  7. core-ci voted on patch set 6 V -1 11/14/25, 00:00 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89608

  8. core-ci voted on patch set 5 V -1 11/14/25, 00:00 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89607

  9. Christian Kuhn uploaded patch set 7 V -1 11/14/25, 00:29

  10. Christian Kuhn uploaded patch set 8 11/14/25, 00:35

  11. Christian Kuhn uploaded patch set 9 11/14/25, 00:37

  12. core-ci voted on patch set 7 V +1 11/14/25, 00:37 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89611

  13. core-ci voted on patch set 8 V +1 11/14/25, 00:44 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89612

  14. core-ci voted on patch set 9 V +1 11/14/25, 00:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89613

  15. Christian Kuhn uploaded patch set 10 V +1 11/14/25, 01:21

  16. core-ci voted on patch set 10 V +1 11/14/25, 01:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89616

  17. Christian Kuhn updated the commit message in patch set 11 V +1 11/14/25, 01:31

  18. core-ci voted on patch set 11 V +1 11/14/25, 01:38 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/89617

  19. Lina Wolf commented on patch set 11 11/14/25, 03:38

    In the docs we mention this as a last resort to get the request in a context where it is not passed on: https://docs.typo3.org/permalink/t3coreapi:typo3-request-global-variable Do we have resolved all cases in which the request could previously not be resolved?
  20. Benni Mack commented on patch set 11 11/14/25, 06:49

    For some context: I added this safety net in v9 to overcome values from TypoScript "getData = GP:my_get_var" etc. This wasn't fully solved in v10, but actually in v11/v12 when we added the ServerRequestInterface to a lot of parts (Extbase, VHs, UserFunctions as third parameter), which is why we can now safely remove it in v14.

    Reply

    it is still available (see RequestHandler.php), the safety net for $_GET and $_POST (which are overridden and synced) are the only parts that have been removed.
  21. Lina Wolf commented on patch set 11 11/14/25, 06:52

    Reply

    Acknowledged
  22. Lina Wolf commented on patch set 11 CR +1 V +1 11/14/25, 06:53

    Let us go for it then!
  23. Benni Mack voted on patch set 11 CR +2 V +2 11/14/25, 07:07

  24. Benni Mack merged patch set 12 11/14/25, 07:07

  25. Lina Wolf commented on patch set 12 12/31/25, 08:34