GIFBUILDER uses provided file names and text snippets in order to
generate the final name for files to be written to. In case text
snippets start with a dot, this is also reflected into the file
name - preventing some web servers to deliver the file since it's
considered to be internal.
Resolves: #83029
Releases: master, 8.7
Change-Id: Iebed832c1c2429c7400373a6af4d5ae14a9ea18e
Reviewed-on: https://review.typo3.org/54677
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
/** @var $basicFileFunctions \TYPO3\CMS\Core\Utility\File\BasicFileUtility */
$basicFileFunctions = GeneralUtility::makeInstance(BasicFileUtility::class);
$filePrefix = implode('_', array_merge($this->combinedTextStrings, $this->combinedFileNames));
- $filePrefix = $basicFileFunctions->cleanFileName($filePrefix);
+ $filePrefix = $basicFileFunctions->cleanFileName(ltrim($filePrefix, '.'));
// shorten prefix to avoid overly long file names
$filePrefix = substr($filePrefix, 0, 100);