openvpn 与代理,意外的 EOF:回复不完整

openvpn 与代理,意外的 EOF:回复不完整

我有一个 OpenVPN 配置,用于公司给我的工作。但是,由于我所在国家/地区的某些限制,我无法直接访问公司的服务器。为了解决这个问题,我使用第二台服务器作为代理。我已将 Termius 配置为将我设备的端口 18080 的流量转发到第二台服务器。此外,我使用 macOS Sonoma 上的内置代理将我设备的所有流量路由到该特定端口。

这种方法在 Windows 机器上效果很好,但切换到 Mac 后,我无法连接到公司服务器。我收到:“HTTP 代理意外 EOF:回复不完整”不幸的是,我对网络的了解有限。如果我遗漏了解决此问题的任何关键信息,请告诉我。

我将非常感激您的帮助。

ovpn 配置

client
dev tun
resolv-retry infinite
proto tcp
remote COMPANY_IP PORT
nobind
persist-key
persist-tun
comp-lzo
verb 3
key-direction 1
http-proxy 127.0.0.1 18080

...certs and so on... 

打开 VPN 日志

[Jan 3, 2024, 12:09:09] OpenVPN core 3.8.2connect3 mac arm64 64-bit built on Dec 19 2023 06:56:50
⏎[Jan 3, 2024, 12:09:09] Frame=512/2112/512 mssfix-ctrl=1250
⏎[Jan 3, 2024, 12:09:09] NOTE: This configuration contains options that were not used:
⏎[Jan 3, 2024, 12:09:09] Unsupported option (ignored)
⏎[Jan 3, 2024, 12:09:09] 2 [resolv-retry] [infinite]
⏎[Jan 3, 2024, 12:09:09] 6 [persist-key]
⏎[Jan 3, 2024, 12:09:09] 7 [persist-tun]
⏎[Jan 3, 2024, 12:09:09] EVENT: RESOLVE ⏎[Jan 3, 2024, 12:09:09] Contacting 127.0.0.1:18080 via HTTP Proxy
⏎[Jan 3, 2024, 12:09:09] EVENT: WAIT_PROXY ⏎[Jan 3, 2024, 12:09:09] UnixCommandAgent: transmitting bypass route to /var/run/agent_ovpnconnect.sock
{
    "host" : "127.0.0.1",
    "ipv6" : false,
    "pid" : 17324
}

⏎[Jan 3, 2024, 12:09:09] EVENT: WAIT ⏎[Jan 3, 2024, 12:09:09] TO PROXY: CONNECT COMPANY_IP:1194 HTTP/1.0
Host: COMPANY_IP

⏎[Jan 3, 2024, 12:09:09] TCP recv EOF
⏎[Jan 3, 2024, 12:09:09] Proxy Error: on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete
⏎[Jan 3, 2024, 12:09:09] EVENT: PROXY_ERROR on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete⏎[Jan 3, 2024, 12:09:09] EVENT: DISCONNECTED ⏎[Jan 3, 2024, 12:09:10] Raw stats on disconnect:
 BYTES_OUT : 60
 PACKETS_OUT : 1
 PROXY_ERROR : 1

⏎[Jan 3, 2024, 12:09:10] Performance stats on disconnect:
  CPU usage (microseconds): 2146109
  Network bytes per CPU second: 27
  Tunnel bytes per CPU second: 0
⏎[Jan 3, 2024, 12:09:10] OpenVPN core 3.8.2connect3 mac arm64 64-bit built on Dec 19 2023 06:56:50
⏎[Jan 3, 2024, 12:09:10] Frame=512/2112/512 mssfix-ctrl=1250
⏎[Jan 3, 2024, 12:09:10] NOTE: This configuration contains options that were not used:
⏎[Jan 3, 2024, 12:09:10] Unsupported option (ignored)
⏎[Jan 3, 2024, 12:09:10] 2 [resolv-retry] [infinite]
⏎[Jan 3, 2024, 12:09:10] 6 [persist-key]
⏎[Jan 3, 2024, 12:09:10] 7 [persist-tun]
⏎[Jan 3, 2024, 12:09:10] EVENT: RESOLVE ⏎[Jan 3, 2024, 12:09:10] Contacting 127.0.0.1:18080 via HTTP Proxy
⏎[Jan 3, 2024, 12:09:10] EVENT: WAIT_PROXY ⏎[Jan 3, 2024, 12:09:10] UnixCommandAgent: transmitting bypass route to /var/run/agent_ovpnconnect.sock
{
    "host" : "127.0.0.1",
    "ipv6" : false,
    "pid" : 17324
}

⏎[Jan 3, 2024, 12:09:10] EVENT: WAIT ⏎[Jan 3, 2024, 12:09:10] TO PROXY: CONNECT COMPANY_IP:1194 HTTP/1.0
Host: COMPANY_IP

⏎[Jan 3, 2024, 12:09:10] TCP recv EOF
⏎[Jan 3, 2024, 12:09:10] Proxy Error: on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete
⏎[Jan 3, 2024, 12:09:10] EVENT: PROXY_ERROR on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete⏎[Jan 3, 2024, 12:09:10] EVENT: DISCONNECTED ⏎[Jan 3, 2024, 12:09:11] Raw stats on disconnect:
 BYTES_OUT : 60
 PACKETS_OUT : 1
 PROXY_ERROR : 1

⏎[Jan 3, 2024, 12:09:11] Performance stats on disconnect:
  CPU usage (microseconds): 2256661
  Network bytes per CPU second: 26
  Tunnel bytes per CPU second: 0
⏎[Jan 3, 2024, 12:09:12] OpenVPN core 3.8.2connect3 mac arm64 64-bit built on Dec 19 2023 06:56:50
⏎[Jan 3, 2024, 12:09:12] Frame=512/2112/512 mssfix-ctrl=1250
⏎[Jan 3, 2024, 12:09:12] NOTE: This configuration contains options that were not used:
⏎[Jan 3, 2024, 12:09:12] Unsupported option (ignored)
⏎[Jan 3, 2024, 12:09:12] 2 [resolv-retry] [infinite]
⏎[Jan 3, 2024, 12:09:12] 6 [persist-key]
⏎[Jan 3, 2024, 12:09:12] 7 [persist-tun]
⏎[Jan 3, 2024, 12:09:12] EVENT: RESOLVE ⏎[Jan 3, 2024, 12:09:12] Contacting 127.0.0.1:18080 via HTTP Proxy
⏎[Jan 3, 2024, 12:09:12] EVENT: WAIT_PROXY ⏎[Jan 3, 2024, 12:09:12] UnixCommandAgent: transmitting bypass route to /var/run/agent_ovpnconnect.sock
{
    "host" : "127.0.0.1",
    "ipv6" : false,
    "pid" : 17324
}

⏎[Jan 3, 2024, 12:09:12] EVENT: WAIT ⏎[Jan 3, 2024, 12:09:12] TO PROXY: CONNECT COMPANY_IP:1194 HTTP/1.0
Host: COMPANY_IP

⏎[Jan 3, 2024, 12:09:12] TCP recv EOF
⏎[Jan 3, 2024, 12:09:12] Proxy Error: on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete
⏎[Jan 3, 2024, 12:09:12] EVENT: PROXY_ERROR on 127.0.0.1:18080: HTTP proxy unexpected EOF: reply incomplete⏎[Jan 3, 2024, 12:09:12] EVENT: DISCONNECTED ⏎[Jan 3, 2024, 12:09:13] Raw stats on disconnect:
 BYTES_OUT : 60
 PACKETS_OUT : 1
 PROXY_ERROR : 1

⏎[Jan 3, 2024, 12:09:13] Performance stats on disconnect:
  CPU usage (microseconds): 2364891
  Network bytes per CPU second: 25
  Tunnel bytes per CPU second: 0

相关内容