mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-02 14:57:37 +02:00
[ticket/10198] validate_config_vars() improperly validates multibyte strings
PHPBB3-10198
This commit is contained in:
@@ -402,7 +402,7 @@ function validate_config_vars($config_vars, &$cfg_array, &$error)
|
|||||||
switch ($validator[$type])
|
switch ($validator[$type])
|
||||||
{
|
{
|
||||||
case 'string':
|
case 'string':
|
||||||
$length = strlen($cfg_array[$config_name]);
|
$length = utf8_strlen($cfg_array[$config_name]);
|
||||||
|
|
||||||
// the column is a VARCHAR
|
// the column is a VARCHAR
|
||||||
$validator[$max] = (isset($validator[$max])) ? min(255, $validator[$max]) : 255;
|
$validator[$max] = (isset($validator[$max])) ? min(255, $validator[$max]) : 255;
|
||||||
|
Reference in New Issue
Block a user