ADC-13.1-How to limit URLs for POST and GET seperatedly with APPFW StartURL feature

ADC-13.1-How to limit URLs for POST and GET seperatedly with APPFW StartURL feature

book

Article ID: CTX694765

calendar_today

Updated On:

Description

For a website, we may have same URLs with diferent request methods like POST and GET.

You may want to define different whitelist for the URLs with POST and GET seperatedly using APPFW StartURL.

Cause

 The customer is looking for a way to limit URLs for POST and GET method seperatedly with APPFW StartURL feature

Resolution

We need to create two different APPFW profiles and two different APPFW policies . In the two APPFW profiles, we define the URLs for POST and GET method seperatedly. And In the two APPFW polices, we evaluate whether the request is using POST or GET method and then we apply different APPFW profiles.

1.In APPFW profile_1 , we specifiy the whitelist for URLs with POST method.

bind appfw profile appfw-prof_1 -startURL "url_1"

 

2.In APPFW profile_2 , we specifiy the whitelist for URLs with GET method.

bind appfw profile appfw-prof_2 -startURL "url_2"

 

3.In APPFW policy_1, we set the expression for POST method.

add appfw policy appfw-pol_1 "HTTP.REQ.METHOD.EQ(\"POST\")" appfw-prof_1

 

4.In APPFW policy_2, we set the expression for GET method.

add appfw policy appfw-pol_2 "HTTP.REQ.METHOD.EQ(\"GET\")" appfw-prof_2

 

5.bind the two APPFW policy to the LB vserver at the same time

bind lb vserver <vs_name> -policyName appfw-pol_1 -priority 100 -gotoPriorityExpression END -type REQUEST
bind lb vserver <vs_name> -policyName appfw-pol_2 -priority 110 -gotoPriorityExpression END -type REQUEST

Issue/Introduction

In this article, we indrocued a way to limit URLs for POST and GET method seperatedly with APPFW StartURL feature