mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 02:31:40 +09:00
31 lines
1.1 KiB
Text
31 lines
1.1 KiB
Text
# block direct access to templates, XML schemas, config files, dotfiles, environment info, etc.
|
|
location ~ ^/rhymix/modules/editor/(skins|styles)/.+\.html$ {
|
|
# pass
|
|
}
|
|
location ~ ^/rhymix/(addons|common/tpl|files/ruleset|(m\.)?layouts|modules|plugins|themes|widgets|widgetstyles)/.+\.(html|xml)$ {
|
|
return 403;
|
|
}
|
|
location ~ ^/rhymix/files/(attach|config|cache/store)/.+\.(ph(p|t|ar)?[0-9]?|p?html?|cgi|pl|exe|[aj]spx?|inc|bak)$ {
|
|
return 403;
|
|
}
|
|
location ~ ^/rhymix/files/(env|member_extra_info/(new_message_flags|point))/ {
|
|
return 403;
|
|
}
|
|
location ~ ^/rhymix/(\.git|\.ht|\.travis|codeception\.|composer\.|Gruntfile\.js|package\.json|CONTRIBUTING|COPYRIGHT|LICENSE|README) {
|
|
return 403;
|
|
}
|
|
|
|
# fix incorrect relative URLs (for legacy support)
|
|
location ~ ^/rhymix/(.+)/(addons|files|layouts|m\.layouts|modules|widgets|widgetstyles)/(.+) {
|
|
try_files $uri $uri/ /rhymix/$2/$3;
|
|
}
|
|
|
|
# fix incorrect minified URLs (for legacy support)
|
|
location ~ ^/rhymix/(.+)\.min\.(css|js)$ {
|
|
try_files $uri $uri/ /rhymix/$1.$2;
|
|
}
|
|
|
|
# all other short URLs
|
|
location /rhymix/ {
|
|
try_files $uri $uri/ /rhymix/index.php$is_args$args;
|
|
}
|