0
我试图做一个SSL代理使用Apache 2侦听端口443并转发请求基于上下文不同的IP /端口:代理升级HTTP1.1(https:// IP1:443到http:// IP2:8080)使用Apache 2
场景:
做一个JBOSS “HTTPS的远程处理” 请求(它使用HTTP1.1升级到 “的jboss-远程” 在Wildfly 8.2),从:
https://xxxxxxx.com:443
并将其转发至:
http://192.168.x.y:8080
我发现下面的RewriteCond的作品:
RewriteCond %{HTTP:Upgrade} jboss-remoting [NC]
RewriteRule ^/(.*)$ http://192.168.x.y:8080/$1 [P]
但我不能找出重写规则,我应该为了申请去请求HTTP的远程处理而不是http。
阿帕奇输入:
GET/HTTP/1.1\r\n
Sec-JbossRemoting-Key: WJaD+AcnutfrXiBna+KL5w==\r\n
Upgrade: jboss-remoting\r\n
Host: xxxxxxx.com\r\n
Connection: upgrade\r\n
阿帕奇输出:
GET/HTTP/1.1\r\n
Host: xxxxxxx.com\r\n
Sec-JbossRemoting-Key: WJaD+AcnutfrXiBna+KL5w==\r\n
X-Forwarded-For: 192.168.x.y\r\n
X-Forwarded-Host: xxxxxxx.com\r\n
X-Forwarded-Server: xxxxxxx.com\r\n
Connection: Keep-Alive\r\n
正如你可以看到,升级和连接头被剥离出来。 有什么方法可以转发一切吗?