Forum Discussion
assaf_benedic_1
Nimbostratus
Aug 31, 2006Identify HTTP requests in TCP traffic
Is it possible to redirect HTTP traffic that is not sent on port 80?
I other words, can I create an iRule that will analyze all TCP traffic and will redirect only traffic that has HTTP syntax?
E,g, http on ports 5674, 4444, 8080 (without creating a special virtual server for these ports).
BTW: can I use the HTTP:: iRules Booleans on HTTP in other ports (not 80) ? what happens if I apply an iRule like that on non HTTP traffic?
Thanks in advance,
Assaf.
- dennypayne
Employee
If you don't create a virtual for those ports LTM will reject the traffic (unless you have a port 0 virtual which is often not ideal).when CLIENT_ACCEPTED { TCP::collect 15 } when CLIENT_DATA { if { [TCP::payload 15] contains "XYZ" } { pool xyz_servers } else { pool web_servers } }
- unRuleY_95363Historic F5 AccountThere's nothing that prevents you from putting an http profile on any virtual. So, you would want to put an http profile on your virtual. Then you would do a rule like Denny previously posted, except when the payload does not contain a valid HTTP-like method, you could issue the command HTTP::disable which will take the http processing offline and allow the non-http traffic to proceed to wherever you declared it to go.
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