Review main Merged

32817[BUGFIX] Do not check file extension on local file

Alexander Opitz CR +2 V +2 Easy +15 −17 updated 09/23/14, 11:16

Commit message

If a file is uploaded and file extension deny pattern is set,
we should not test this temporary file for extension permissions.
Also on adding a file into a storage do not need to test the
extension of the local file, the extension of the target file is
enough.

Review

  • Code review CR +2
    • Stefan Neufeind +2
    • Frans Saris +1
    • Helmut Hummel +1
  • Verified V +2
    • Stefan Neufeind +2
    • Frans Saris +1

Issues 1

Files 1

Review log 12

  1. Alexander Opitz uploaded patch set 1 09/17/14, 08:08

  2. Alexander Opitz commented on patch set 1 09/17/14, 08:11

    In Question: - Do we need a "breaking docu"? As the function is more or less internal. For Backporting to 6.2: - It's planned that the 6.2 backport only removes the usage of the $localFilePath in the if statement of assureFileAddPermissions
  3. Helmut Hummel commented on patch set 1 CR +1 09/17/14, 08:18

    ResourceStorage.php:1081

    this change here is crutial to not introduce a vulnerability! Maybe add a comment that the check needs to be *after* the calculation of the targetFileName
  4. Frans Saris voted on patch set 1 CR +1 09/17/14, 16:29

  5. Frans Saris voted on patch set 1 V +1 09/19/14, 15:40

  6. Stefan Neufeind voted on patch set 1 CR +1 09/20/14, 22:24

  7. Frans Saris commented on patch set 1 09/21/14, 08:11

    Stefan could you maybe also verify this patch? - Add following to your localconf $TYPO3_CONF_VARS['BE']['fileExtensions']['webspace']['allow'] = 'png,gif,jpg,jpeg,pdf'; $TYPO3_CONF_VARS['BE']['fileExtensions']['webspace']['deny'] = '*'; - Login as non admin user - Try to upload a file.
  8. Stefan Neufeind voted on patch set 1 CR +2 V +2 09/21/14, 16:47

  9. Stefan Neufeind merged patch set 1 09/21/14, 16:47

  10. Stefan Neufeind commented on patch set 2 09/21/14, 16:47

    @Alex: How did you plan to backport this? Please go ahead :-)
  11. Alexander Opitz commented on patch set 2 09/23/14, 09:15

  12. Oliver Hader commented on patch set 2 09/23/14, 11:16

    Cherry Picked This patchset was cherry picked to branch TYPO3_6-2 as commit 692a8000cebf8a510cbc5621a7a1bfeb06e1b002