Forum Discussion
silver
Nimbostratus
Sep 26, 2012URI Rewrite
HI All,
I have a specific requirement to rewrite the URI when the user requests the URL and the change has to be made interanlly without knowing to the external user.
Original URL : https://www.abc.com/customer/context/html need to be changed internally as below
https://abc.com/testcustomer/testcontext/html
Can anyone help me by providing an iRule matching the above.
Thanks in advance.
- Kevin_Stewart
Employee
Silently changing the URI on the inbound request is best done with the HTTP::uri command. - silver
Nimbostratus
Basically i need as below. - Kevin_Stewart
Employee
Well, very simply: - silver
Nimbostratus
I had updated as below but not working. - Michael_Yates
Nimbostratus
Hi Silver,when HTTP_REQUEST { if { [string tolower [HTTP::uri]] equals "/testcustomer/testcontext/html" } { HTTP::uri "/customer/context/html" } }
- silver
Nimbostratus
Hi Mike, - What_Lies_Bene1
Cirrostratus
Could you do a tcpdump and see what the server response contains? Does it look normal? What exactly do you mean by the connection is getting closed, can you be more specific? - nathe
Cirrocumulus
I'd try fiddler / httpfox and see if that gives any more info. Also, you could try Curl as well on the ltm box to see what errors are returned e.g. - nathe
Cirrocumulus
Apologies - - Michael_Yates
Nimbostratus
Hi silver,
Recent Discussions
Related Content
Â
DevCentral Quicklinks
* 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
Discover DevCentral Connects