我正在尝试为所有类型的帧(HTTP、HTTPS)设置透明代理,我正在使用 tinyproxy 来执行此操作。我已经设置了我的路由器以将所有传入和传出帧重定向(使用 NAT)到 tinyproxy(正在侦听端口 8888)。
我尝试访问 HTTPS 网站 ( https://www.google.com/ ),但出现 SSL 连接错误。查看 tinyproxy 日志,我看到以下内容:
CONNECT Mar 24 23:34:27 [22533]: Connect (file descriptor 11): 128.112.94.38 [128.112.94.38]
CONNECT Mar 24 23:34:27 [22533]: Request (file descriptor 11):
WARNING Mar 24 23:34:27 [22533]: Could not retrieve all the headers from the client
INFO Mar 24 23:34:27 [22533]: Read request entity of 103 bytes
tinyproxy 文档说,只要我在tinyproxy.conf
文件中设置以下行,Connect 帧的转发应该透明地工作:
# ConnectPort: This is a list of ports allowed by tinyproxy when the
# CONNECT method is used. To disable the CONNECT method altogether, set
# the value to 0. If no ConnectPort line is found, all ports are
# allowed (which is not very secure.)
#
# The following two ports are used by SSL.
ConnectPort 443
ConnectPort 563
我还尝试删除所有ConnectPort
行以查看是否有效(无效)。有谁知道为什么我无法透明地转发 HTTPS 流量?