mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-25 10:09:20 +03:00
Security fixes
This commit is contained in:
parent
12a2f324b2
commit
34ab65fc80
3 changed files with 33 additions and 5 deletions
|
|
@ -1043,8 +1043,19 @@ class Utils
|
|||
*/
|
||||
public static function ClearFileName($sFileName)
|
||||
{
|
||||
return \preg_replace('/[\s]+/', ' ',
|
||||
\str_replace(array('"', '/', '\\', '*', '?', '<', '>', '|', ':'), ' ', $sFileName));
|
||||
return \MailSo\Base\Utils::ClearNullBite(\preg_replace('/[\s]+/', ' ',
|
||||
\str_replace(array('"', '/', '\\', '*', '?', '<', '>', '|', ':'), ' ', $sFileName)));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $sValue
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public static function ClearXss($sValue)
|
||||
{
|
||||
return \MailSo\Base\Utils::ClearNullBite(
|
||||
\str_replace(array('"', '/', '\\', '*', '?', '<', '>', '|', ':'), ' ', $sValue));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue