From df033ebef1c9fafb6a63de732eb019fded5d9bdd Mon Sep 17 00:00:00 2001 From: Robert Date: Sun, 2 Oct 2022 20:09:11 +0300 Subject: [PATCH] apply requested changes --- src/nginxconfig/generators/conf/security.conf.js | 3 ++- .../i18n/en/templates/global_sections/security.js | 1 + src/nginxconfig/templates/global_sections/security.vue | 8 +++----- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/nginxconfig/generators/conf/security.conf.js b/src/nginxconfig/generators/conf/security.conf.js index 9db4284..a318a75 100644 --- a/src/nginxconfig/generators/conf/security.conf.js +++ b/src/nginxconfig/generators/conf/security.conf.js @@ -66,8 +66,9 @@ export default (domains, global) => { } if (global.security.blockCommonExploits.computed) { + // Based on https://github.com/NginxProxyManager/nginx-proxy-manager/blob/v2.9.0/docker/rootfs/etc/nginx/conf.d/include/block-exploits.conf // Block SQL Injections - config.push(['## Block SQL injections', '']); + config.push(['# Block SQL injections', '']); config.push(['set $block_sql_injections', '0']); config.push([ 'if ($query_string ~ "union.*select.*(")', diff --git a/src/nginxconfig/i18n/en/templates/global_sections/security.js b/src/nginxconfig/i18n/en/templates/global_sections/security.js index fec968f..d2df02c 100644 --- a/src/nginxconfig/i18n/en/templates/global_sections/security.js +++ b/src/nginxconfig/i18n/en/templates/global_sections/security.js @@ -29,4 +29,5 @@ import common from '../../common'; export default { whenUsingWordPressUnsafeEvalIsOftenRequiredToAllowFunctionality: `When using ${common.wordPress}, script-src 'self' 'unsafe-inline' 'unsafe-eval'; is often required in the Content Security Policy to allow the admin panel to function correctly.`, security: 'Security', + blockCommonExploits: 'Block common exploits', }; diff --git a/src/nginxconfig/templates/global_sections/security.vue b/src/nginxconfig/templates/global_sections/security.vue index 56f0e2a..3ed30c3 100644 --- a/src/nginxconfig/templates/global_sections/security.vue +++ b/src/nginxconfig/templates/global_sections/security.vue @@ -158,14 +158,13 @@ THE SOFTWARE.
- +
-
+
- + {{ $t("common.enable") }}
@@ -222,7 +221,6 @@ THE SOFTWARE. enabled: true, }, }; - export default { name: 'GlobalSecurity', // Component name display: 'templates.globalSections.security.security', // Display name for tab (i18n key)