Forum Discussion
Godswill
Nimbostratus
Jun 11, 2019How to configure F5 virtual servers to ensure HSTS-compliant headers for URL are included URL
I need help on how to configure all the URLs that are rediected from my F5 to comply with HSTS compliant header. MY lTM version is 12.1.3
- Lee_Sutcliffe
Nacreous
You will need to determine the best settings for HSTS for your organisation however this is an example taken from the OWASP Cheat Sheet:
This example will check if the HSTS header exists, if it doesn't it will be inserted. You may wish to change the logic a bit and remove the header if it does exist to ensure consistency.
when HTTP_RESPONSE { if {!([HTTP::header exists "Strict-Transport-Security"])} { HTTP::header insert name "Strict-Transport-Security" value "Strict-Transport-Security: max-age=86400; includeSubDomains" } }
Let me know how you get on
Lee
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects