sslproxyf5http-tunneling

F5 iRule to manage HTTP proxy CONNECT requests


I have a F5 Virtual Server configured with client-side https encryption, in front of a web server.

I would like this VS to manage also HTTP CONNECT requests, so that clients can request it either as a web server, or as a proxy.

That is to say, the VS should decrypt all TCP connections, but if the first TCP packet starts with "CONNECT", it should first respond HTTP 200, then wait for the next packet (that must be "client hello") and process the SSL handshake.

It is certainly possible with some iRule, but I can't easily get a solution, and I can't find any help on Internet, since F5 doc is not open. Does anyboy know how to do it ?


Solution

  • I finally found a solution.

    The VS default behavour is to process the SSL decryption right from the first TCP packet : so one must look at the first TCP packet, and, if it starts with CONNECT,

    It works in both context :