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

Rodrigo_Mori_13's avatar
Jul 28, 2016

Redirect [url:port] WAN for [url:port] LAN - iRules

Good afternoon people.

 

I have an application published on the web, which accounts for DNS.

 

This application to be opened, runs on port 81. So, to access the application on the Internet, have to put the Url and door to run.

 

Ex. Url1.algumacoisa.com:81

 

The Vs and the server, respond on port 81.

 

I need to do the following. The User to access the application not put the door in the url, and BigIP is a redirect to the Vs correctly with the included port, as follows.

 

By accessing the application, both internal and external, when you type in the browser url1.algumacoisa.com the BigIP does redirect to the Vs correctly to url1.algumacoisa.com:81.

 

I need that door is transparent to the User, without his having to type in the URL.

 

It is possible to make a iRules that?

 

 

7 Replies

  • Hi,

    If I understand correctly, you may need an irule like below :

    when HTTP_REQUEST {
         if { [HTTP::host] eq "url1.algumacoisa.com" } {
              HTTP::respond 302 Location "http://url1.algumacoisa.com:81[HTTP::uri]"
         }   
    }
    
    • boneyard's avatar
      boneyard
      Icon for MVP rankMVP

      it would help if you explain what happens which you didn't want to and how you would like it to work.

       

  • Hi,

    If I understand correctly, you may need an irule like below :

    when HTTP_REQUEST {
         if { [HTTP::host] eq "url1.algumacoisa.com" } {
              HTTP::respond 302 Location "http://url1.algumacoisa.com:81[HTTP::uri]"
         }   
    }
    
    • boneyard's avatar
      boneyard
      Icon for MVP rankMVP

      it would help if you explain what happens which you didn't want to and how you would like it to work.

       

  • In this case, you won't need the ":81"

     

    • You need to configure your VS to listen on port 80.
    • Pool members need to listen on port 81.