Forum Discussion
LTM Policy: Wildcard for HTTP Header value
I would like to create ltm policy for persistence, when a special http-header is in request. Value of the header is unimportant. When i create a policy: HTTP-Header 'headername' contains or is '*' in request it doesnt work. What is the wildcard symbol in this case ?
'*' doesnt work and an empty field isnt possible.
Bye, Nick
- youssef1
Cumulonimbus
Hello,
I don't think that regex are supported with Policies, you can solve it with an iRule.
Check this topic below that notify that regular expression is not supported in policy:
https://devcentral.f5.com/questions/using-regex-in-policy-rule-condition
https://devcentral.f5.com/questions/using-regex-in-policy-rule-condition
As i told you, you can do it with an Irule (let me now if you need help, but it's better that you do it yourself, up to skill, and it's more simple).
If you want use Policy there are reliable solutions but a little dirty :-)
you can create your condition like that: HTTP Header named "toto" begin with "you can put a random value that will never match"...
But for this use case i advise you to use an Irule...
Regards,
- JG
Cumulonimbus
Here's a shot in the dark: you could try "
" where you want the wildcard to be.tcl:[HTTP::header values name_of_the_header]
We know tcl commands work in "action", but I am not sure if they work at all in conditions as well. Let us know either way if you do try.
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