Bug #58872

ResourceStorage::addFile throws exception due invalid file permission check

Added by Rico Sonntag almost 7 years ago. Updated almost 2 years ago.

Must have
File Abstraction Layer (FAL)
Target version:
Start date:
Due date:
% Done:


Estimated time:
TYPO3 Version:
PHP Version:
Is Regression:
Sprint Focus:


/typo3/sysext/core/Classes/Resource/ResourceStorage.php => addFile

A call to addFile

$file = $resourceStorage->addFile(

throws the exception "File name is invalid." (Code: 1320288991). Parameter $targetFileName is allowed to be empty but $this->assureFileAddPermissions does not take it into account. Instead the targetFileName is evaluated two lines later:

$targetFileName = $this->driver->sanitizeFileName($targetFileName ?: PathUtility::basename($localFilePath));

Do you really test your stuff before you release it (Commit 054207881d3be1d76b8205231c8847947d5c2e4c for instance)? Its a pain to work with TYPO3 6.2 and FAL. Really annoying.


Updated by Mathias Schreiber over 5 years ago

  • Target version deleted (next-patchlevel)

Updated by Susanne Moog about 2 years ago

  • Status changed from New to Needs Feedback

I cannot reproduce the issue. The code example in the description actually checks if the $targetFileName is empty and falls back to basename - so there does not seem to be a bug at all.


Updated by Riccardo De Contardi almost 2 years ago

  • Status changed from Needs Feedback to Closed

No feedback since the last 90 days => closing this issue.

If you think that this is the wrong decision or experience the issue again and have more information about how to reproduce your problem, please reopen it or ping me.

Thank you and best regards

Also available in: Atom PDF