[TYPO3-core] RFC #8040: Bug: Wrong check on creating folders in filelist makes them unaccessible

Martin Kutschker Martin.Kutschker at n0spam-blackbox.net
Tue Apr 22 12:46:37 CEST 2008


Dmitry Dulepov [typo3] schrieb:
> Hi!
> 
> Moreno Feltscher wrote:
>> OK, new patch attached. Now directories and files with ending dots are
>> going to created in a Windows friendly way.
> 
> <skip>
> 
>> -        return preg_replace('/[^.[:alnum:]_-]/','_',trim($fileName));
>> +    $fileName = preg_replace('/[^.[:alnum:]_-]/','_',trim($fileName));
> 
> I am not sure that old a new code is correct. I checked PHP manual and 
> it declares support for "alnum: only for "ereg" family of functions. 

PREG supports, as does Perl, POSIX character classes.

Masi


More information about the TYPO3-team-core mailing list