xyanrch / overplus

Yet another proxy server that support trojan protocol and v protocol.
BSD 2-Clause "Simplified" License
176 stars 41 forks source link

CDN support #15

Closed devAlikhani closed 1 year ago

devAlikhani commented 1 year ago

Hi, is there any plan to support CDN on overplus over WebSocket or GRPC?

xyanrch commented 1 year ago

Yes it‘s in my plan, but currently it's a low priority thing.

xyanrch commented 1 year ago

already supported in v1.0.4

molezz commented 1 year ago

already supported in v1.0.4

ws 改成true了, 但是v2rayn的trojin里要路径path, 不知道填什么, 空白? 似乎一直连不上

xyanrch commented 1 year ago

随便填一下,这个不影响

molezz commented 1 year ago

还是不成功,先是利用脚本的,只改了ws true, 因为是v6only,所以只能用cdn

/etc/overplus/server.json 
{
    "run_type": "server",
    "local_addr": "0.0.0.0",
    "local_port": "443",
    "allowed_passwords": [
        "qwer1234"
    ],
    "log_level": "NOTICE",
    "log_dir":"",
    "ssl": {
        "cert": "/etc/overplus/server_N4BJNel36ggJKcy5.crt",
        "key": "/etc/overplus/server_N4BJNel36ggJKcy5.key"
    },
    "websocketEnabled": true
}

客户端如图xxx.com已cf小云朵 op

提示bad handshake

 [Warning] [3547147887] app/proxyman/outbound: failed to process outbound traffic > proxy/trojan: failed to find an available destination > common/retry: [transport/internet/websocket: failed to dial WebSocket > transport/internet/websocket: failed to dial to (wss://xxx.com/op): 521 Origin Down > websocket: bad handshake] > common/retry: all retry attempts failed
xyanrch commented 1 year ago

改了配置后重启服务了吗?有服务端log吗

molezz commented 1 year ago

systemctrl restart了 我也手动启动查看了 服务端只有

/usr/bin/overplus /etc/overplus/server.json
[2022-12-09 14:27:14][NOTICE] /__w/1/s/Server/Service.cpp Service: line: 28 [139752243918848] listen websocket connection
[2022-12-09 14:27:14][NOTICE] /__w/1/s/Server/Service.cpp run: line: 111 [139752243918848] SslServer start...

然后客户端怎么改 服务端也就这2句。 之前曾经用过xray trojin的cdn正常,现在卸载了换用overplus

molezz commented 1 year ago

换用v2rayn也试了下

 app/proxyman/outbound: failed to process outbound traffic > proxy/trojan: failed to find an available destination > common/retry: [transport/internet/websocket: failed to dial WebSocket > transport/internet/websocket: failed to dial to (wss://xxx.com/):  > remote error: tls: handshake failure] > common/retry: all retry attempts failed

op

服务端仍是2句

xyanrch commented 1 year ago

跳过证书验证设置为 true,试一下

molezz commented 1 year ago

还是一样的提示, 感觉好像就是没连上服务端, notice那里也没刷新到有入站请求类的

xyanrch commented 1 year ago
屏幕截图 2022-12-09 151207

我试过ws直连是可以的,我不知道套cdn的话,是不是什么配置有问题。

molezz commented 1 year ago

ok 我再研究下各种组合看看

molezz commented 1 year ago

试了下 ,地址改成直连可以,

 operator(): line: 43 [140449995233024] accept incoming connection :100.9
[2022-12-09 15:30:36][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] accept incoming connection :100.90
[2022-12-09 15:30:36][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] 

切换cf绑定的域名后就不行了

[2022-12-09 15:31:22][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] accept incoming connection :100.90.24.65
[2022-12-09 15:31:27][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] accept incoming connection :100.90.24.65
[2022-12-09 15:31:30][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] accept incoming connection :100.90.24.65
[2022-12-09 15:31:49][NOTICE] /__w/1/s/Server/Service.cpp operator(): line: 43 [140449995233024] accept incoming connection :100.90.24.65
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449978447616] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449995233024] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449970054912] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449961662208] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449970054912] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449986840320] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449978447616] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449970054912] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449995233024] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449961662208] Client-->Server: The WebSocket stream was gracefully closed at both endpoints
[2022-12-09 15:32:03][ERROR] /__w/1/s/Server/Session.cpp operator(): line: 314 [140449986840320] Client-->Server: stream truncated