Forum Discussion
HTTP::header insert - Cannot insert header with an underscore in the name
Hi,
I have a requirement to insert a header field that has a name containing an underscore. When the field name of the header contains an "_", the header does not get inserted.
The code below does not insert the request header:
modify rule rule_set_is_ssl_hdr { when HTTP_REQUEST { if { [TCP::local_port] == 443 } { HTTP::header insert IS_SSL "1" } else { HTTP::header insert IS_SSL "0" } } }
However this code does insert the request header.
modify rule rule_set_is_ssl_hdr { when HTTP_REQUEST { if { [TCP::local_port] == 443 } { HTTP::header insert IS-SSL "1" } else { HTTP::header insert IS-SSL "0" } } }
How do I insert a header with a field name containing an "_".
Thanks, Larry
1 Reply
- What_Lies_Bene1
Cirrostratus
Have you tried quoting the header name as you have with it's value "IS_SSL" - not that I think you should have to.
Recent Discussions
Related Content
* 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