Draftcode Microsoft restrictions #1645

This commit is contained in:
the-djmaze 2024-07-01 12:53:01 +02:00
parent 60abc83ff1
commit dcfe7d3f2d
2 changed files with 15 additions and 0 deletions

View file

@ -1,7 +1,16 @@
#<FilesMatch "index\.php">
# allow from all
# AcceptPathInfo On
#</FilesMatch>
<IfModule mod_rewrite.c>
RewriteEngine On
# Redirect cPanel
RewriteRule cpsess.* https://%{HTTP_HOST}/ [L,R=301]
# RewriteCond %{REQUEST_FILENAME} !-f
# RewriteCond %{REQUEST_FILENAME} !-d
# RewriteRule ^(.+)$ index.php/$1 [L,QSA]
</IfModule>
<IfModule mod_expires.c>

View file

@ -66,6 +66,12 @@ abstract class Service
}
$sQuery = \trim($_SERVER['QUERY_STRING'] ?? '');
/*
if (!empty($_SERVER['PATH_INFO'])) {
$sQuery = "{$_SERVER['PATH_INFO']}&{$sQuery}";
$_SERVER['REQUEST_URI'] = \substr($_SERVER['REQUEST_URI'],0, -\strlen($_SERVER['REQUEST_URI']));
}
*/
$iPos = \strpos($sQuery, '&');
if (0 < $iPos) {
$sQuery = \substr($sQuery, 0, $iPos);