Forum Discussion
apply different ASM policy based on URI content
Hi,
I have three URLs hosted on single server and mapped to one VS on ASM working with single ASM policy as of now.
Now, i want to create an irule on LTM to differentiate the traffic having /car and /home in URI path. Further i want two different ASM policies to be applied for the traffic having /car in URI and traffic having /home in URI.
Please suggest how to achieve this.
I have understanding to segregate the traffic on LTM by creating irule. After creating an irule how i will map this segregated traffic to different policy. DO i need to create two VS server for this or i can assign multiple policies to single VS based on the traffic segregation from LTM.
2 Replies
- nathe
Cirrocumulus
Sandeep,
Whilst an irule could work for you have you considered doing this via HTTP Class profiles (11.3.0 and before) or Local Traffic Policies (11.4.0 and after)?
All the above can be achieved using these two methods without needing iRules.
Hope this helps,
N
- nathe
Cirrocumulus
Out of interest...an irule would use the ASM::enable command. See ASM__enable.
Something like this:
when HTTP_REQUEST { switch -glob [string tolower [HTTP::uri]] { "*/car/*" { ASM::enable /Common/car_policy } "*/house/*" { ASM::enable /Common/house_policy } } }
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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