mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[Change] Remove NUL-Bytes directly in request_var() for strings and within the custom DBAL sql_escape() functions (MSSQL, Firebird, Oracle) (reported by AdhostMikeSw)
git-svn-id: file:///svn/phpbb/trunk@8968 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -351,7 +351,7 @@ class dbal_firebird extends dbal
|
||||
*/
|
||||
function sql_escape($msg)
|
||||
{
|
||||
return str_replace("'", "''", $msg);
|
||||
return str_replace(array("'", "\0"), array("''", ''), $msg);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -302,7 +302,7 @@ class dbal_mssql extends dbal
|
||||
*/
|
||||
function sql_escape($msg)
|
||||
{
|
||||
return str_replace("'", "''", $msg);
|
||||
return str_replace(array("'", "\0"), array("''", ''), $msg);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -312,7 +312,7 @@ class dbal_mssql_odbc extends dbal
|
||||
*/
|
||||
function sql_escape($msg)
|
||||
{
|
||||
return str_replace("'", "''", $msg);
|
||||
return str_replace(array("'", "\0"), array("''", ''), $msg);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -515,7 +515,7 @@ class dbal_oracle extends dbal
|
||||
*/
|
||||
function sql_escape($msg)
|
||||
{
|
||||
return str_replace("'", "''", $msg);
|
||||
return str_replace(array("'", "\0"), array("''", ''), $msg);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user