Review 12.4 Merged

84002[BUGFIX] Avoid mapping route values that are out of scope

Oliver Hader CR +2 V +2 Normal +113 −6 updated 04/23/24, 11:12

Commit message

Given a static route argument mapper is used - for instance one
that allows values in the range of 1 to 100 - then generating an
URL from a route with an out of scope `&value=5000` was still
generating an URL. However, HTTP request to that URL would
result in an 404 error.

This change skips routes using out of scope values during the
URL generation process to avoid pointing to invalid resources.

Review

  • Code review CR +2 Done
    • Oliver Hader +2
  • Verified V +2 Done
    • Oliver Hader +2
    • core-ci +1 CI

Issues 1

Files 3

Review log 79

  1. Oliver Hader uploaded patch set 1 04/23/24, 10:54

  2. Oliver Klee commented on patch set 1 04/23/24, 10:59

    VariableValue.php:45

    To be compatible with PHP 8.4, the type needs to be nullable: https://wiki.php.net/rfc/deprecate-implicitly-nullable-types
  3. core-ci voted on patch set 1 V +1 04/23/24, 10:59 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/56564

  4. Oliver Hader rebased onto patch set 2 V +1 04/23/24, 11:00

  5. Oliver Hader commented on patch set 2 04/23/24, 11:04

    VariableValue.php:45 Reply

    → should be done in main branch then, since this is the back-port
  6. Oliver Hader commented on patch set 2 04/23/24, 11:09

    VariableValue.php:45 Reply

    Besides that, other methods and functions of this class are using a similar pattern. These should be addressed in general, including other classes as well.
  7. Oliver Hader voted on patch set 2 CR +2 V +2 04/23/24, 11:11

  8. core-ci voted on patch set 2 V +1 04/23/24, 11:12 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/56566

  9. Oliver Hader merged patch set 3 04/23/24, 11:12