File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -43,22 +43,31 @@ controller:
4343 priorityClassName: "otomi-critical"
4444 extraArgs:
4545 v: 3
46- config:
4746 enable-ssl-passthrough: true
47+ config:
4848 ssl-redirect: {{ if $v.otomi.hasCloudLB }}"false"{{ else }}"true"{{ end }}
4949 hsts: "true"
5050 disable-ipv6: "true"
5151 client-body-timeout: "5"
5252 client-header-timeout: "5"
5353 enable-modsecurity: {{ $n | get "modsecurity.enabled" "false" }}
54- enable-owasp-modsecurity-crs: {{ and ($n | get " modsecurity.enabled" "false") ($n | get "modsecurity.owasp" "false") }}
54+ enable-owasp-modsecurity-crs: false # modsecurity-snippet only works when this is turned off
5555 http2-max-field-size: 64k
5656 http2-max-header-size: 128k
5757 proxy-buffers-number: "8"
5858 proxy-buffer-size: 16k
5959 large-client-header-buffers: 8 16k
6060 proxy-body-size: {{ $n | get "maxBodySize" "1024m" }}
6161 log-format-upstream: '$remote_addr - $remote_user [$time_local] $host "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" $request_length $request_time [$proxy_upstream_name] $upstream_addr $upstream_response_length $upstream_response_time $upstream_status'
62+ {{- if $n | get "modsecurity.enabled" "true" }}
63+ modsecurity-snippet: |
64+ {{ if $n | get "modsecurity.block" "true" }}SecRuleEngine On{{- end }}
65+ SecRequestBodyLimit {{ $n | get "maxBodySizeBytes" "1073741824" }}
66+ # SecAuditLogFormat JSON
67+ SecRuleRemoveById 920350 # discard internal requests
68+ {{/* so we include the owasp ruleset here if required */}}
69+ {{ if ($n | get "modsecurity.owasp" "false") }}Include /etc/nginx/owasp-modsecurity-crs/nginx-modsecurity.conf{{- end }}
70+ {{- end }}
6271 stats:
6372 enabled: true
6473 metrics:
You can’t perform that action at this time.
0 commit comments