Forum Discussion
CraigBo
Nimbostratus
Mar 08, 2022Request POST Header Rewrite of Origin and Referer
Can someone tell me if the Origin and/or the Referer in the Request POST header and be rewritten before sending to the pool members? If so, do you have a irule suggestion? I've tried different irul...
CA_Valli
MVP
Mar 09, 2022
when HTTP_REQUEST {
if {[HTTP::method] eq "POST"}{
HTTP::header replace origin "http://123.abc.com"
HTTP::header replace referer "http://123.abc.com"
} else { return }
}
This should do, but please test before installing.
Also, you should be able to achieve the same with an LTM policy, which is recommended because it is faster and more importantly is fully supported within configuration changes like an upgrade since syntax is standard.
iRule can be improved if you require support for multiple hosts
CraigBo
Nimbostratus
Mar 09, 2022Thanks, that worked perfectly!! I think I may have been trying to make it to difficult.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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