2dust / v2rayN

A GUI client for Windows and Linux, support Xray core and v2fly core and others
https://1.2345345.xyz
GNU General Public License v3.0
69.63k stars 11.52k forks source link

[Bug]: Tun mode for WS TLS #4562

Closed bia-pain-bache closed 9 months ago

bia-pain-bache commented 10 months ago

预期情况

Vless ws tls connection on Tun mode.

实际情况

Just started the Vless WS TLS config, and turned on tun mode. it should be mentioned that this config works fine on proxy mode. Also Vless GRPC TLS works fine on Tun mode, but not WS config.

复现方法

Just started the Vless WS TLS config, and turned on tun mode.

日志信息

2024/01/01 13:40:27 The ping of current service: 443 ms +0330 2024-01-01 13:40:29 ERROR [588804380 385ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:30 ERROR [1627112469 402ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:31 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:33 ERROR [4113593480 724ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:33 ERROR [3884175180 466ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 ....

额外信息

I changed the config core to sing-box and still the same issue happens.

我确认已更新至最新版本

我确认已查询历史issues

GoldExynos commented 10 months ago

I have the same issue. I tried the latest stable version of v2rayN (6.32) and latest pre-release (6.32) with sing-box core version 1.7.6 and 1.8.0. In all test cases, this type of connection (vless ws tls) does not work with TUN mode. Other types of connections work properly.

Also, these are my Logs:

Configuration successful
[VLESS] Vless-CDN-WS(de***site:8443)
Start service (2024/01/07 00:14:59)...
2024/01/07 00:15:00 System proxy setting is changedForcedClear
+0330 2024-01-07 00:15:02 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: EOF
+0330 2024-01-07 00:15:02 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: EOF
+0330 2024-01-07 00:15:13 ERROR dns: exchange failed for www.google.com. IN A: EOF
+0330 2024-01-07 00:15:13 ERROR dns: exchange failed for geo.prod.do.dsp.mp.microsoft.com. IN A: EOF
+0330 2024-01-07 00:15:14 ERROR dns: exchange failed for www.google.com. IN A: EOF
+0330 2024-01-07 00:15:15 ERROR dns: exchange failed for geo.prod.do.dsp.mp.microsoft.com. IN A: EOF
+0330 2024-01-07 00:15:17 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: EOF
+0330 2024-01-07 00:15:17 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: EOF
+0330 2024-01-07 00:15:18 ERROR dns: exchange failed for www.google.com. IN A: EOF
+0330 2024-01-07 00:15:19 ERROR dns: exchange failed for geo.prod.do.dsp.mp.microsoft.com. IN A: EOF
+0330 2024-01-07 00:15:19 ERROR dns: exchange failed for www.google.com. IN A: EOF
+0330 2024-01-07 00:15:20 ERROR dns: exchange failed for geo.prod.do.dsp.mp.microsoft.com. IN A: EOF
2dust commented 10 months ago

Please provide configuration file

bia-pain-bache commented 10 months ago

Should I share my config in public?

2dust commented 10 months ago

send email to captainIronng@protonmail.com

SkyWalker1726 commented 9 months ago

预期情况

Vless ws tls connection on Tun mode.

实际情况

Just started the Vless WS TLS config, and turned on tun mode. it should be mentioned that this config works fine on proxy mode. Also Vless GRPC TLS works fine on Tun mode, but not WS config.

复现方法

Just started the Vless WS TLS config, and turned on tun mode.

日志信息

2024/01/01 13:40:27 The ping of current service: 443 ms +0330 2024-01-01 13:40:29 ERROR [588804380 385ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:30 ERROR [1627112469 402ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:31 ERROR dns: exchange failed for www.msftconnecttest.com. IN A: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:33 ERROR [4113593480 724ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 +0330 2024-01-01 13:40:33 ERROR [3884175180 466ms] inbound/tun[tun-in]: unexpected HTTP response status: 404 ....

额外信息

I changed the config core to sing-box and still the same issue happens.

我确认已更新至最新版本

  • [x] 是

我确认已查询历史issues

  • [x] 是

Did you get an answer on how to fix the issue ?

DgithubA commented 5 months ago

i have the same issue in sing-box v1.9.0. my log:

+0330 2024-05-27 19:35:41 ERROR [2598137143 538ms] inbound/http[http]: process connection from 127.0.0.1:42444: unexpected HTTP response status: 404
+0330 2024-05-27 19:35:41 ERROR [824222885 212ms] inbound/http[http]: process connection from 127.0.0.1:42450: unexpected HTTP response status: 404
+0330 2024-05-27 19:35:43 ERROR [408676090 4.65s] inbound/http[http]: process connection from 127.0.0.1:42422: unexpected HTTP response status: 404
+0330 2024-05-27 19:35:43 ERROR [2890060476 790ms] inbound/http[http]: process connection from 127.0.0.1:42461: unexpected HTTP response status: 404
+0330 2024-05-27 19:35:44 ERROR [2242653156 1.19s] inbound/http[http]: process connection from 127.0.0.1:42464: unexpected HTTP response status: 404

and sime time is:

inbound/http[http]: connection closed: process connection from 127.0.0.1:21775: Post "http://91.108.56.158/api": EOF

or

inbound/http[http]: connection closed: process connection from 127.0.0.1:21767: download: ws closed: 1005  | upload: io: read/write on closed pipe | Post "http://91.108.56.158/api": EOF

outbound:

{
      "type": "vless",
      "tag": "proxy",
      "server": "104.21.65.13",//cloud flare ip
      "server_port": 443,
      "uuid": "e0ba05f5-1bc4-4302-875b-69b77c694c2a",
      "packet_encoding": "xudp",//i change it to other options,no difference.
      "tls": {
        "enabled": true,
        "server_name": "no.block.domain.ir",
        "insecure": false,
        "alpn": [
          "h2",
          "http/1.1"
        ],
        "utls": {
          "enabled": true,
          "fingerprint": "randomized"
        }
      },
      "transport": {
        "type": "ws",
        "path": "/somthing?ed=2048",
        "max_early_data": 0,
        "early_data_header_name": "Sec-WebSocket-Protocol",//i change it to empty,no difference.
        "headers": {
          "Host": "no.block.domain.ir"
        }
      }
    },