For more information regarding the security incident at F5, the actions we are taking to address it, and our ongoing efforts to protect our customers, click here.

Forum Discussion

eLeCtRoN's avatar
eLeCtRoN
Icon for Cirrus rankCirrus
Sep 02, 2016

F5 iRule for header and url rewrite/redirect

Hello,

 

I want to access from external https://free-busy.company.com/ews/exchange.asmx and https://free-busy.company.com/autodiscover/autodiscover.svc as well this would redirect via firewall to a internal VIP but just https://free-busy.company.com to the internal https://mail.int.company.com/ this VIP has a pool and in this pool is the exchange server. (from internal I can access https://mail.int.company.com/ews/exchange.asmx, https://mail.int.company.com/autodiscover/autodiscover.svc) Now I want to access the both external links and redirct to the both internal link and I think I need a host header rewirte as well for this ? Can someone give me a iRule with good performance for this scenario ?

 

THX Manuel

 

1 Reply

  • it is better to do this rewrite with a LTM policy, otherwise this should help

     

    when HTTP_REQUEST {

     

    if { [HTTP::header host] eq "www.abc.com" } {

     

    HTTP::header replace Host "www.xyz.com"

     

    }

     

    }