Skip to content

Commit 490fece

Browse files
TimZ99kenjis
authored andcommitted
Replaced deprecated FILTER_SANITIZE_STRING
Replaced with FILTER_SANITIZE_FULL_SPECIAL_CHARS. Equivalent to calling htmlspecialchars() with ENT_QUOTES set.
1 parent 505b396 commit 490fece

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

system/Helpers/cookie_helper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ function get_cookie($index, bool $xssClean = false)
6565
{
6666
$prefix = isset($_COOKIE[$index]) ? '' : config(App::class)->cookiePrefix;
6767
$request = Services::request();
68-
$filter = $xssClean ? FILTER_SANITIZE_STRING : FILTER_DEFAULT;
68+
$filter = $xssClean ? FILTER_SANITIZE_FULL_SPECIAL_CHARS : FILTER_DEFAULT;
6969

7070
return $request->getCookie($prefix . $index, $filter);
7171
}

0 commit comments

Comments
 (0)