mirror of
https://github.com/nextcloud/server.git
synced 2026-04-24 23:59:27 -04:00
Use SCRIPT_NAME instead of PHP_SELF which won't send the PATH_INFO, this prevents XSS in old browsers. Thanks to Nico Golde.
This commit is contained in:
parent
f1cabdd8e0
commit
6ef5edf5ea
1 changed files with 1 additions and 1 deletions
|
|
@ -39,7 +39,7 @@ OCP\App::setActiveNavigationEntry( 'files_index' );
|
|||
$dir = isset( $_GET['dir'] ) ? stripslashes($_GET['dir']) : '';
|
||||
// Redirect if directory does not exist
|
||||
if(!OC_Filesystem::is_dir($dir.'/')) {
|
||||
header('Location: '.$_SERVER['PHP_SELF'].'');
|
||||
header('Location: '.$_SERVER['SCRIPT_NAME'].'');
|
||||
exit();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue