Skip to content
Snippets Groups Projects
Commit de95bf62 authored by Michael Gapczynski's avatar Michael Gapczynski
Browse files

Prevent any null bytes related exploits, thanks to Lukas Reschke

parent 3c6c8eca
No related branches found
No related tags found
No related merge requests found
......@@ -424,7 +424,7 @@ class OC{
register_shutdown_function(array('OC_Helper','cleanTmp'));
//parse the given parameters
self::$REQUESTEDAPP = (isset($_GET['app'])?strip_tags($_GET['app']):'files');
self::$REQUESTEDAPP = (isset($_GET['app'])?str_replace('\0', '', strip_tags($_GET['app'])):'files');
if(substr_count(self::$REQUESTEDAPP, '?') != 0){
$app = substr(self::$REQUESTEDAPP, 0, strpos(self::$REQUESTEDAPP, '?'));
$param = substr(self::$REQUESTEDAPP, strpos(self::$REQUESTEDAPP, '?') + 1);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment