# iRule for Reverse Proxy with data-group

**URL:** <https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803>\
**Category:** Technical Forums\
**Tags:** irules, big-ip, security\
**Created:** [June 5, 2020, 3:37pm UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803 "2020-06-05T15:37:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![JamesB12](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JamesB12](https://community.f5.com/u/JamesB12)\
**Post date:** [June 5, 2020, 3:37pm UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803/1 "2020-06-05T15:37:30Z")

</div>

Hi,

The below URL to be restricted to the specific set of IP addresses.

[https://pbr.corp.com/exp-int-lifetime-mgmt/v1/sit](https://pbr.corp.com/exp-int-lifetime-mgmt/v1/sit)

Also would like to match the complete URI in HTTP rather than the keywords.

but the main URL [https://pbr.corp.com/](https://pbr.corp.com/) should be accessible for Anybody.

Any help much appreciated…Thanks.

---

<div class="post-metadata">

**Author:** ![Mayur\_Sutare](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/mayur_sutare/32/5035_2.png) [@Mayur\_Sutare](https://community.f5.com/u/Mayur_Sutare)\
**Post date:** [June 6, 2020, 5:23am UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803/2 "2020-06-06T05:23:05Z")

</div>

Hello,

​

iRule given in below post should fulfill your requirement.

​

​

​[https://devcentral.f5.com/s/question/0D51T00007Xf8lOSAR/reverse-proxy-irule-to-restrict-the-access-on-ip?page=3](https://devcentral.f5.com/s/question/0D51T00007Xf8lOSAR/reverse-proxy-irule-to-restrict-the-access-on-ip?page=3)

​

Hope it works!

Mayur​

---

<div class="post-metadata">

**Author:** ![JamesB12](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JamesB12](https://community.f5.com/u/JamesB12)\
**Post date:** [June 6, 2020, 10:26am UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803/3 "2020-06-06T10:26:34Z")

</div>

Hi , In the URI match can i use complete URL ?

**if {[HTTP::uri] eq "**[pbr.corp.com/exp-int-lifetime-mgmt/v1/sit](https://pbr.corp.com/exp-int-lifetime-mgmt/v1/sit) **"}**

**Thanks.**

---

<div class="post-metadata">

**Author:** ![Mayur\_Sutare](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/mayur_sutare/32/5035_2.png) [@Mayur\_Sutare](https://community.f5.com/u/Mayur_Sutare)\
**Post date:** [June 8, 2020, 6:41am UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803/4 "2020-06-08T06:41:03Z")

</div>

Hello,

No, you can’t use it in that way. You can use statement like given below,

**if { [HTTP::host] equals “[pbr.corp.com](http://pbr.corp.com)” and [HTTP::uri] equals “/exp-int-lifetime-mgmt/v1/sit” }**

Hope it helps!

Mayur

---

<div class="post-metadata">

**Author:** ![JamesB12](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JamesB12](https://community.f5.com/u/JamesB12)\
**Post date:** [June 24, 2020, 9:54pm UTC](https://community.f5.com/t/irule-for-reverse-proxy-with-data-group/53803/5 "2020-06-24T21:54:36Z")

</div>

Thanks Mayur, Cheers
