瀏覽代碼

Fix #yogosha4534

Laurent Destailleur 4 年之前
父節點
當前提交
a0b230fa46
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      htdocs/core/lib/functions.lib.php

+ 2 - 2
htdocs/core/lib/functions.lib.php

@@ -606,9 +606,9 @@ function GETPOST($paramname, $check = 'alphanohtml', $method = 0, $filter = null
 			break;
 	}
 
-	// Sanitizing for special var name. There is no reason to allow a backtopage to an external URL.
+	// Sanitizing for special parameters. There is no reason to allow the backtopage parameter to contains an external URL.
 	if ($paramname == 'backtopage') {
-		$out = preg_replace(array('/\/\/+/', '/^[a-z]*:/'), '', $out);
+		$out = preg_replace(array('/[\\\/][\\\/]+/', '/^[a-z]*:/'), '', $out);
 	}
 
 	// Code for search criteria persistence.