🔥 Proxy is a high performance HTTP(S) proxies, SOCKS5 proxies,WEBSOCKET, TCP, UDP proxy server implemented by golang. Now, it supports chain-style proxies,nat forwarding in different lan,TCP/UDP port forwarding, SSH forwarding.Proxy是golang实现的高性能http,https,websocket,tcp,socks5代理服务器,支持内网穿透,链式代理,通讯加密,智能HTTP,SOCKS5代理,黑白名单,限速,限流量,限连接数,跨平台,KCP支持,认证API。
Expected Behavior
我在使用贵项目做http代理时,中间使用tcp协议可以通,但是使用kcp协议就失败了,提示decoder err,我想解决这个问题。
Current Behavior
一级代理日志如下,提示 released [192.168.1.32:80] C:\Users\Administrator\Desktop\proxy-windows-amd64>proxy http -t kcp -p "0.0.0.0 :38080" --kcp-key mypassword 2023/01/10 09:58:14.251976 INFO kcp http(s) proxy on 0.0.0.0:38080 2023/01/10 10:00:20.676777 INFO GET:http://192.168.1.32/?user/login.html 2023/01/10 10:00:20.676777 INFO use parent : false, 192.168.1.32:80 2023/01/10 10:00:20.677777 INFO conn 192.168.1.31:65084 - 0.0.0.0:38080 <-> 192. 168.1.32:53461 - 192.168.1.32:80 connected [192.168.1.32:80] 2023/01/10 10:00:20.697777 INFO conn 192.168.1.31:65084 - 0.0.0.0:38080 <-> 192. 168.1.32:53461- 192.168.1.32:80 released [192.168.1.32:80] 2023/01/10 10:00:23.409177 INFO CONNECT:sug.so.360.cn:443 2023/01/10 10:00:23.409177 INFO use parent : false, sug.so.360.cn:443 2023/01/10 10:00:25.798377 INFO CONNECT:sug.so.360.cn:443 2023/01/10 10:00:25.798377 INFO use parent : false, sug.so.360.cn:443 2023/01/10 10:00:26.161377 INFO GET:http://192.168.1.112/ 2023/01/10 10:00:26.161377 INFO use parent : false, 192.168.1.112:80 2023/01/10 10:00:26.163377 INFO conn 192.168.1.31:65087 - 0.0.0.0:38080 <-> 192. 168.1.32:53462 - 192.168.1.112:80 connected [192.168.1.112:80] 2023/01/10 10:00:26.189377 INFO conn 192.168.1.31:65087 - 0.0.0.0:38080 <-> 192. 168.1.32:53462- 192.168.1.112:80 released [192.168.1.112:80]
二级代理日志如下,提示http decoder read err: C:\Users\Administrator\Desktop\proxy-windows-amd64>proxy http -t tcp -p "0.0.0.0 :8083" -T kcp -P "192.168.1.32:38080" --kcp-key mypassword 2022/01/10 09:59:30.986955 INFO use kcp parent [192.168.1.32:38080] [ ROUNDROBIN ] 2022/01/10 09:59:31.009555 INFO tcp http(s) proxy on [::]:8083 2022/01/10 10:00:22.503755 INFO GET:http://192.168.1.32/?user/login.html 2022/01/10 10:00:22.503755 INFO use parent : true, 192.168.1.32:80 2022/01/10 10:00:22.503755 INFO conn 192.168.1.111:59477 - 192.168.1.31:8083 <-> 0.0.0.0:65084 - 192.168.1.32:38080 connected [192.168.1.32:80] 2022/01/10 10:00:23.503955 WARN decoder error , from 192.168.1.111:59478, ERR:ht tp decoder read err: http decoder read err: read tcp 192.168.1.31:8083->192.168. 1.111:59478: i/o timeout 2022/01/10 10:00:25.285955 INFO CONNECT:sug.so.360.cn:443 2022/01/10 10:00:25.285955 INFO use parent : true, sug.so.360.cn:443 2022/01/10 10:00:25.286955 INFO conn 192.168.1.111:59481 - 192.168.1.31:8083 <-> 0.0.0.0:65085 - 192.168.1.32:38080 connected [sug.so.360.cn:443] 2022/01/10 10:00:27.668955 INFO CONNECT:sug.so.360.cn:443 2022/01/10 10:00:27.669955 INFO use parent : true, sug.so.360.cn:443 2022/01/10 10:00:27.669955 INFO conn 192.168.1.111:59484 - 192.168.1.31:8083 <-> 0.0.0.0:65086 - 192.168.1.32:38080 connected [sug.so.360.cn:443] 2022/01/10 10:00:28.001955 INFO GET:http://192.168.1.112/ 2022/01/10 10:00:28.001955 INFO use parent : true, 192.168.1.112:80 2022/01/10 10:00:28.002955 INFO conn 192.168.1.111:59485 - 192.168.1.31:8083 <-> 0.0.0.0:65087 - 192.168.1.32:38080 connected [192.168.1.112:80] 2022/01/10 10:00:28.995955 WARN decoder error , from 192.168.1.111:59486, ERR:ht tp decoder read err: http decoder read err: read tcp 192.168.1.31:8083->192.168. 1.111:59486: i/o timeout
Possible Solution
Steps to Reproduce
首先启动一级代理 然后启动二级代理 浏览器设置代理 发现问题,代理失败
Context (Environment)
Detailed Description
通过kcp协议代理http,代理失败,提示http decoder err
Possible Implementation
无法推测原因