Xray-core icon indicating copy to clipboard operation
Xray-core copied to clipboard

Tun Support

Open APT-ZERO opened this issue 1 year ago • 14 comments

Hello Desktop clients needs Xray-core to support Tun Do you have any plan to support it?

APT-ZERO avatar Jul 22 '24 08:07 APT-ZERO

dup

Fangliding avatar Jul 22 '24 14:07 Fangliding

如果可以的话,能否考虑支持像openconnect那一种的服务器也有tun接口,然后客户端也有tun接口的方式(即类似VPN但可以更轻量),以方便设置路由,并且应用场景也会更全面

谢谢!

egg1234 avatar Jul 23 '24 05:07 egg1234

Use transproxies. TUN is less performant than transparent proxies anyway, unless you need to also handle packets other than TCP and UDP.

PoneyClairDeLune avatar Jul 28 '24 08:07 PoneyClairDeLune

It would be very good to have tun support. Sing-Box and Fly already have it. I use an additional program tun2socks.

AlexeySa avatar Aug 01 '24 11:08 AlexeySa

Use transproxies. TUN is less performant than transparent proxies anyway, unless you need to also handle packets other than TCP and UDP.

Yes, for example VoIP. There should be TUN implementation because every GUI client uses other core for that purpose and that's sad :(

somebodywashere avatar Aug 15 '24 09:08 somebodywashere

我觉得主要是 Windows 和 macOS 需要 Tun,Linux 上不如透明代理,话说 macOS 上有透明代理吗

RPRX avatar Aug 15 '24 09:08 RPRX

i hope this feature get added sooner with tunneling available it become the best anti censorship product (proxy + TUN)

hoodadt avatar Sep 05 '24 10:09 hoodadt

希望RPRX大佬推出Windows和macOS的TUN功能,因为根本没人愿意用singbox那种漏洞百出的东西,都是因为tun

heibailiangxiangwang20 avatar Sep 07 '24 08:09 heibailiangxiangwang20

这里似乎已经变成许愿井了 issue区不是干这个的。。。 请不要再在这里发送无用的消息

Fangliding avatar Sep 07 '24 10:09 Fangliding

Can we use this dependency? https://github.com/SagerNet/sing-tun

omid-official avatar Sep 09 '24 19:09 omid-official

@omid-official I think GPL is not right to add to xray. There is some GPL code in xray, but it is historical, and the author themselves added it. (otherwise, I am sure adding some dependencies to xray for this feature is fine)

mmmray avatar Sep 10 '24 10:09 mmmray

Can we use this dependency? https://github.com/SagerNet/sing-tun

Sing-Tun is approved by Xray devs at #1814 and is advised to use because it's not wise to reinvent the wheel

I am a novice regarding licenses and do not know what terms and conditions each of them has, but as mmmray mentioned, the GPL license has stricter rules compared to the MPL license.

omid-official avatar Sep 12 '24 18:09 omid-official

Please stop that. We will not use it

Fangliding avatar Sep 12 '24 18:09 Fangliding

I think TUN is really good and practical( not only for Win or MacOS, for all platforms ), and at least for the following reason, it needs to be added:

TUN can cover all network traffic, including traffic from non-browser software, apps, and various protocols. Additionally, you can block WebRTC STUN later to prevent the exposure of the real IPs( Local + Public)! With TUN, all traffic is routed through the tunnel(vNIC), which reduces the likelihood of requests being identified and blocked.

deepsm0ke avatar Dec 06 '24 02:12 deepsm0ke

A proxy without the TUN mode is not serious. They write correctly that not all traffic goes through the browser. In addition, at the moment there is no solution for the TUN mode with the XHTTP protocol. And such a solution will not appear soon. ((( Something needs to be done about this.

EarlVadim avatar Dec 28 '24 19:12 EarlVadim

Could it support both Tun virtual network cards and Tap virtual network cards at the same time?

minusmulticoloredper avatar Jan 09 '25 20:01 minusmulticoloredper

会有 TUN,但脑残开的 issue 不该留着

RPRX avatar Feb 10 '25 13:02 RPRX