-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Extend the scope of webserver protected folders #23101
base: 5.x-dev
Are you sure you want to change the base?
Conversation
@@ -195,7 +201,7 @@ protected static function createWebConfigFiles() | |||
<requestFiltering> | |||
<denyUrlSequences> | |||
<add sequence=".php" /> | |||
</denyUrlSequences>' . ($directoryToProtect === '/plugins' ? $additionForPlugins : '') . ' | |||
</denyUrlSequences>' . (!is_numeric($directoryToProtect) ? $additions : '') . ' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
key->value items in the array have string keys, without the pair the key is numeric, so we can use this to check if we have some additions or not.
@@ -68,7 +68,7 @@ public static function createHtAccessFiles() | |||
'/libs' => $denyAll . $allowStaticAssets, | |||
'/vendor' => $denyAll . $allowStaticAssets, | |||
'/plugins' => $denyAll . $allowStaticAssets . $allowManifestFile, | |||
'/misc/user' => $denyAll . $allowStaticAssets, | |||
'/misc' => $denyAll . $allowStaticAssets, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is an explicit .htaccess
in misc/cron allowing access to the archive.php
script, so this should be ok as an extended scope.
This is the content of the
|
The generation can be tested using the ddev local env if you comment out the |
Description:
As per the title, ref. DEV-18936
Review