Review main Merged

89983[TASK] Replace $_FILES with PSR-7 UploadedFile in ExtendedFileUtility

Oliver Hader CR +2 V +2 Hard +285 −89 updated 07/08/25, 13:32

Commit message

This change substitutes the low-level usage of super global
`$_FILES` with the corresponding PSR-7 `UploadedFile` models.

The `is_uploaded_file()` check in `ResourceStorage` is only
performed for path values (as string). In case `UploadedFile`
structures are given, the assumption is, that file were actually
uploaded (this allows functional testing via `UploadedFile`).

Review

  • Code review CR +2 Done
    • Oliver Hader +2
    • Garvin Hicking +1
    • Stefan Bürk +1
    • Benni Mack +1
    • Simon Schaufelberger +1
  • Verified V +2 Done
    • Oliver Hader +2
    • Garvin Hicking +1
    • Stefan Bürk +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 1

Files 9

Review log 2734

Show 69 earlier messages
  1. Oliver Hader uploaded patch set 1 07/03/25, 13:55

  2. Oliver Hader marked it work in progress 07/03/25, 13:55

  3. core-ci voted on patch set 1 V -1 07/03/25, 14:04 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81282

  4. Oliver Hader uploaded patch set 2 V -1 07/03/25, 16:48

  5. core-ci voted on patch set 2 V +1 07/03/25, 16:55 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81285

  6. Oliver Hader uploaded patch set 3 V +1 07/03/25, 18:54

  7. Oliver Hader commented on patch set 3 07/03/25, 18:56

    This change is ready for review.
    @simonschaufi+typo3@gmail.com As requested in https://review.typo3.org/c/Packages/TYPO3.CMS/+/89740, I'm happily introducing new tests for `ExtendedFileUtility` in combination with the required move towards `UploadedFile` models. Looking forward to your review & feedback. Thx
  8. core-ci voted on patch set 3 V +1 07/03/25, 19:01 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81287

  9. Oliver Hader uploaded patch set 4 V +1 07/03/25, 19:02

  1. core-ci voted on patch set 4 V +1 07/03/25, 19:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81288

  2. Garvin Hicking commented on patch set 4 CR +1 V +1 07/03/25, 19:31

    Nice! Couldn't break it, tried variants with/without sanitization, single/multi file upload, replace, rename.
  3. Simon Schaufelberger voted on patch set 4 CR +1 07/03/25, 20:04

  4. Simon Schaufelberger commented on patch set 4 07/03/25, 20:56

    ResourceStorage.php:989

    this comment doesn't fit for me here as below is no check if this file is uploaded.

    ExtendedFileUtility.php:1170

    is it possible to narrow it down as mixed can really be anything?
  5. Oliver Hader uploaded patch set 5 CR +1 V +1 07/04/25, 07:59

  6. Oliver Hader commented on patch set 4 07/04/25, 07:59

    ResourceStorage.php:989 Reply

    Done

    ExtendedFileUtility.php:1170 Reply

    Done
  7. core-ci voted on patch set 5 V +1 07/04/25, 08:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81314

  8. Simon Schaufelberger voted on patch set 5 CR +1 07/04/25, 08:07

  9. Garvin Hicking voted on patch set 5 CR +1 V +1 07/04/25, 12:23

  10. Simon Schaufelberger commented on patch set 5 07/08/25, 09:50

    merge conflict
  11. Garvin Hicking uploaded patch set 6 CR +1 V +1 07/08/25, 10:00

  12. Garvin Hicking commented on patch set 6 07/08/25, 10:02

    Reply

    just a quick shot at rebasing, didn't check fully yet.
  13. Oliver Hader commented on patch set 6 07/08/25, 10:03

    Reply

    I'll adjust the tests...
  14. Oliver Hader voted on patch set 6 CR -1 07/08/25, 10:05

  15. core-ci voted on patch set 6 V -1 07/08/25, 10:09 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81481

  16. Oliver Hader uploaded patch set 7 CR -1 V -1 07/08/25, 10:17

  17. Oliver Hader commented on patch set 7 07/08/25, 10:20

    Reply

    Done
  18. core-ci voted on patch set 7 V +1 07/08/25, 10:24 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81482

  19. Benni Mack voted on patch set 7 CR +1 V +1 07/08/25, 12:36

  20. Garvin Hicking voted on patch set 7 CR +1 V +1 07/08/25, 12:47

  21. Stefan Bürk voted on patch set 7 CR +1 V +1 07/08/25, 12:50

  22. Simon Schaufelberger voted on patch set 7 CR +1 07/08/25, 12:57

  23. Oliver Hader voted on patch set 7 CR +2 V +2 07/08/25, 13:31

  24. Oliver Hader commented on patch set 7 07/08/25, 13:31

    Thx folks! 😊
  25. Oliver Hader merged patch set 8 07/08/25, 13:32