Ste*_*wie 7 apache-http-server proxy php curl openssl
通过 PHP Curl 连接到某个第三方服务会引发此错误:
CURL error: Received HTTP code 403 from proxy after CONNECT
Run Code Online (Sandbox Code Playgroud)
代理上的 Apache 错误日志抛出:
Connect to remote machine blocked returned by remote.service.com:59315
Run Code Online (Sandbox Code Playgroud)
我想知道如何让它发挥作用!
代理配置:
<VirtualHost *:8001>
ProxyRequests On
<Proxy *>
Order deny,allow
Deny from all
Allow from 10.
</Proxy>
ProxyVia Off
<IfModule mod_headers.c>
Header set P3P "policyref=\"/w3c/p3p.xml\", CP=\"NOI DSP COR NID CUR ADM DEV OUR BUS\""
</IfModule>
AllowCONNECT 443 1129 7934 8080 993
</VirtualHost>
Run Code Online (Sandbox Code Playgroud)
从这个日志中可以看出,允许使用域 IP:
[error] [client 10.234.9.46] proxy: Connect to remote machine blocked returned by
Run Code Online (Sandbox Code Playgroud)
小智 2
为代理端口添加AllowCONNECT 有效。Apache 2.2 不需要,但 Apache 2.4 需要。对于我们来说,是从 IBM HTTP Server 8.5.5 到 IBM HTTP Server 9。
之前的评论得到了我的虚拟支持,因为这还不起作用。你可能会认为他们可能会从 Stack Overflow 中获取声誉点。花了一些时间寻找这个答案,所以谢谢。
| 归档时间: |
|
| 查看次数: |
5096 次 |
| 最近记录: |