mirror of
https://github.com/opnsense/plugins.git
synced 2026-06-13 19:00:22 -04:00
net/haproxy: HSTS is only applicable to HTTP frontends
This commit is contained in:
parent
190b48b3e5
commit
139ef0a634
1 changed files with 1 additions and 1 deletions
|
|
@ -607,7 +607,7 @@ frontend {{frontend.name}}
|
|||
{% do ssl_options.append('ciphers ' ~ frontend.ssl_cipherList) %}
|
||||
{% endif %}
|
||||
{# # HSTS #}
|
||||
{% if frontend.ssl_hstsEnabled|default("") == '1' %}
|
||||
{% if frontend.ssl_hstsEnabled|default("") == '1' and frontend.mode == 'http' %}
|
||||
http-response set-header Strict-Transport-Security max-age={{frontend.ssl_hstsMaxAge}}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
|
|
|||
Loading…
Reference in a new issue