Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

移植到 UWP 平台的可行性探讨 #7

Open
bdbai opened this issue Jun 6, 2017 · 66 comments
Open

移植到 UWP 平台的可行性探讨 #7

bdbai opened this issue Jun 6, 2017 · 66 comments

Comments

@bdbai
Copy link

bdbai commented Jun 6, 2017

  1. 基于原生 UWP VPN API
    之前 @Noisyfox请问有没有计划推出Windows10Mobile客户端? shadowsocks-windows#862 表示微软没有把文档放出来。事实上 MSDN 文档已经有了,只是描述不够清晰,也没有例子。按照前人在 iOS 上的做法,我大概有了一点点思路,但目前并没有着手实现。欢迎一起探讨。
  2. 桌面到通用 Windows 平台 (UWP) 桥
    如果完全抛弃移动版用户,用这种方法也许可以少走些弯路,不过要牺牲掉一些 Win32 特性。

利益相关: Lumia 640 用户

@pexcn
Copy link

pexcn commented Jun 6, 2017

Lumia 640 (Windows Phone 10) 用户 + 1

@BestOwl
Copy link

BestOwl commented Jun 7, 2017

@bdbai
Copy link
Author

bdbai commented Jun 7, 2017

@BestOwl I'm wondering if their engineering team are really working on it, or maybe we are deserted.

@Noisyfox
Copy link

@bdbai I was thinking about the same question.

@tommyxu97
Copy link

Surface Pro 4 User +1

@florianmonfort
Copy link

I sent them a message on Twitter. Waiting to hear back.

@florianmonfort
Copy link

All my UWP apps are useless. 有很多的APP不可以用:

  • Facebook
  • Twitter
  • Instagram
  • SoundCloud
  • Messenger
    。。。。

@celeron533
Copy link

celeron533 commented Jul 6, 2017

@florianmonfort have you tried Proxifier as a workaround?
https://www.proxifier.com/

@florianmonfort
Copy link

I believe Shadowsocks client already uses Proxifier? Every time something goes wrong with my server I can see a Proxifier error in my browser, so I'm not sure why you're suggesting to use it?

By the way, some Microsoft guy's response on Twitter:

image

@florianmonfort
Copy link

@celeron533 I just looked at Proxifier's download page:

image

It clearly states for downloads for Windows 10*: Windows Desktop applications only

@celeron533
Copy link

Hi @florianmonfort , sorry I haven't tried it on my personal Win10 environment.

Windows 10*: Windows Desktop applications only

IMO, perhaps it only means the Proxifier application itself is winform/mfc based not UWP but still could be used for redirecting other UWP Apps' network usage (unconfirmed, just my personal assumption)

@celeron533
Copy link

Nop, shadowsocks-windows uses Privoxy to adapt HTTP proxy to SOCKS5 protocol. Because not all the applications support socks5 proxy.

I believe Shadowsocks client already uses Proxifier? Every time something goes wrong with my server I can see a Proxifier error in my browser, so I'm not sure why you're suggesting to use it?

@JamesMackerel
Copy link

也有这个想法,跑来官方的repo想找有没有能够移植的代码,就看到了这个issue。

其实如果要是移植到UWP的话,最好还是支持MOBILE。因为这样意义就更加大了,否则其实如果已经有一个稳定的经典windows客户端,要去重新造一个轮子好像也没什么意义。

现在问题就是官方的文档描述不是很清晰,没有给相关的例程。

其实我觉得这些问题都不大,问题是到底能不能有一个sslocal稳定的在后台运行,不会被杀掉或者挂起,这是最重要的。

@JamesMackerel
Copy link

另外,请问一下从哪里能看到这个项目的基本架构……我刚刚看了两小时都没想出怎么把ss的部分抽出来。

@Noisyfox
Copy link

Noisyfox commented Jul 8, 2017

是我肯定从头写,不会基于现在的win版开发uwp版。

@JamesMackerel
Copy link

JamesMackerel commented Jul 8, 2017 via email

@wongsyrone
Copy link

从头写没问题,加密和随机数那部分别随便改就行了

@florianmonfort
Copy link

I personally don't care about mobile, just care if Shadowsocks can support UWP apps, is this going to happen? It's just more and more apps that will be unusable with time...

@celeron533 not sure I fully understand the translations of this thread!

@JamesMackerel
Copy link

@florianmonfort
We are actually discussing the possibility of making a UWP shadowsocks.
IMO, if we do it recently and do not support windows mobile, it's not much a meaningful work, since legacy application runs well and supports many functions at the time.

@JamesMackerel
Copy link

microsoft/Windows-universal-samples#699 (comment)

I asked sample from Microsoft, but they refused. I think we may contact directly to the support team.

@florianmonfort
Copy link

@JamesMackerel have you done so yet? Or are you waiting for someone to do it?

The legacy client supports a lot of features yes, but doesn't support UWP apps, and more and more apps are going to UWP including the most important ones... I'm so annoyed that I can't use my UWP apps right now

@JamesMackerel
Copy link

@florianmonfort

Nope, it's only an idea at the time.
For UWP apps, I saw an article at Stackoverflow says UWP apps would find proxy from Edge/IE automatically. In fact, I have tried to use Edge with this client and it works fine, only by using PAC mode, but haven't tried others.

If we are to develop a UWP client, we must get same sample rather than those doc from Microsoft. However, I will try, but I don't count on it very much.

@florianmonfort
Copy link

@JamesMackerel ok... So you are waiting to conclude on it once you have made a test?

@itsuki-hayashi
Copy link

For UWP apps, I saw an article at Stackoverflow says UWP apps would find proxy from Edge/IE

@JamesMackerel that is a feature of HttpClient class, not every UWP application use it, and some use custom TCP/UDP protocol which definitely not using HttpClient.

UWP VPN API is the only way to proxify the whole system without the need to develop a custom network driver.

I hope M$ could release a sample code soon.

@itsuki-hayashi
Copy link

@celeron533

IMO, perhaps it only means the Proxifier application itself is winform/mfc based not UWP but still could
be used for redirecting other UWP Apps' network usage (unconfirmed, just my personal assumption)

Wrong. UI of the application does not matter. Proxifier uses Winsock Layered Service Provider to proxify applications, which is deprecated as of Windows 8, hence all Metro/UWP applications will simply bypass it, this is done by design.

Desktop application can use Windows Filtering Platform to proxify Metro/UWP applications, it is a new API meant to replace Layered Service Provider. However it runs as a network driver and require digital signature, which is far too expensive for a open source project.($223/yr for a code signing certificate from DigiCert, Symantec's will be more expensive).

UWP VPN API is the only proxifier API available for free at Windows platform.

@JamesMackerel
Copy link

JamesMackerel commented Aug 3, 2017 via email

@wongsyrone
Copy link

let's give up the UWP

Agreed. That's why M$ sucks.

@bdbai
Copy link
Author

bdbai commented Aug 3, 2017 via email

@JamesMackerel
Copy link

JamesMackerel commented Aug 3, 2017 via email

@dongqiceo
Copy link

UWP的话,会登陆Windows store吗

@koolwiki
Copy link

How are things going ? @bdbai

@bdbai
Copy link
Author

bdbai commented Nov 13, 2017

@hbxntsxw Thanks for your kindly attention! At the moment I am working on cryptography libraries and addressing issues related to lwip.

@realLiangshiwei
Copy link

realLiangshiwei commented Dec 4, 2017

How are things going ? What can I do for you? @bdbai

@florianmonfort
Copy link

Would be great to see this arrived!

@Noisyfox
Copy link

Just in case, https://github.com/Noisyfox/ShadowsocksUWP

@bdbai
Copy link
Author

bdbai commented Feb 13, 2018

Several days ago, YtFlowTunnel was published in YtFlow. This repo, together with Wintun2socks, is intended to inspire those interested in it.

Actually anyone can make a UWP VPN app out of these repos with a little effort although it would be too unstable to handle daily usage.

@CaiMiao
Copy link

CaiMiao commented Jun 8, 2018

还有可能面世么,纯WP环境要爬墙头都大了

@chenshaoju
Copy link

@CaiMiao 请阅读:shadowsocks/shadowsocks-windows#897

@OpportunityLiu
Copy link

现在的版本已经可以把临时文件放回 %TEMP% 了

@BestOwl
Copy link

BestOwl commented Aug 27, 2018

UWP的版本做出来也不太可能上架的,这样Desktop Bridge就没有意义了。 UWP版本主要还是考虑Mobile和Xbox等非PC平台

@OpportunityLiu
Copy link

@BestOwl 不上架的话XBOX也没法用吧,不就只剩半死不活的Mobile了

@OpportunityLiu
Copy link

@wenqiangxie VPN有专有的API啊,不用App Service

@BestOwl
Copy link

BestOwl commented Sep 16, 2018

I've implemented a Socks5 global proxy using BadVPN and UWP VPN platform, it will be very easy to adapt it to Shadowsock.
https://github.com/BestOwl/ShadowsocksUWP

@Noisyfox
Copy link

I've implemented a Socks5 global proxy using BadVPN and UWP VPN platform, it will be very easy to adapt it to Shadowsock.
https://github.com/BestOwl/ShadowsocksUWP

Nicely done!

@florianmonfort
Copy link

Does that mean we will get ShadhowSocks for UWP soon? @BestOwl would you be able to provide binaries to download from your repository page?

@BestOwl
Copy link

BestOwl commented Sep 19, 2018

@florianmonfort Yes, I am working on it, I will publish it once it's ready.

@florianmonfort
Copy link

@BestOwl Any news? 😛

@BestOwl
Copy link

BestOwl commented Nov 30, 2018

Got stucked with a strange bug, please join https://telegram.me/ytflow for further details.

@bdbai
Copy link
Author

bdbai commented Apr 21, 2019

YtFlow is now able to handle system-wide connections using a fake IP pool. It also works fine on Mobile platform. See https://t.me/YtFlowChannel/73

Cc shadowsocks/shadowsocks-windows#862

@bdbai
Copy link
Author

bdbai commented Apr 28, 2019

Now that UWP VPN Platform is proven to work with Shadowsocks, wouldn't it be nicer to create a new repo for official Shadowsocks implementation and work on it?
After that this issue may be closed as well.

@5ngs94jzqw
Copy link

I found two bugs of uwp vpn api and find the workaround of them in case someone need it:
ysc3839/UWPToyVpn#1
ysc3839/UWPToyVpn#2

@bdbai
Copy link
Author

bdbai commented Jun 3, 2019

@5ngs94jzqw the problem you have mentioned cannot be reproduced using YtFlowTunnel . Can you provide more detailed clues?

@5ngs94jzqw
Copy link

5ngs94jzqw commented Jun 4, 2019

@bdbai
Do you try connect to a public ip(like 32.xx.xx.xx)?
Do you try to test to watch a youtube video for 10 minutes and make sure the youtube video tcp connection is go over your vpn? Test with small ip packets and small number of ip packets is ok for me too.(some ip packets as big as 1390)

I can see your project is not connect to a public ip(like 32.xx.xx.xx) server from your source code. Maybe that is the reason. Big delay(like 200ms) between client and server may be the reason.

Another reason is my test windows 10 is not exact the same as yours.
This computer also have some bugs with https://reqrypt.org/windivert.html , and I have to add 3 version of windivert to solve all problems in all test windows 10 computers.

@ghost
Copy link

ghost commented Mar 9, 2020

Maybe we can add YtFlow to shadowsocks organization. @bdbai

@bdbai
Copy link
Author

bdbai commented Mar 9, 2020

@studentmain Is there an official plan to support Shadowsocks on UWP? YtFlow contains a couple of different protocols other than Shadowsocks. We might need a Shadowsocks-only variant, where support for Windows Mobile device family could be dropped and shadowsocks/Shadowsocks-Net could be used. See also #6 .

@ghost
Copy link

ghost commented Mar 9, 2020

Is there an official plan to support Shadowsocks on UWP?

Not yet. Shadowsocks-Net is build for next major release of shadowsocks-windows.

We might need a Shadowsocks-only variant

Drop feature is much easier than add feature😄, we're going to drop Windows 7, 32bit x86 and stream cipher too.

@ghost
Copy link

ghost commented Mar 9, 2020

Transfer issue to Shadowsocks-Net

@ghost ghost closed this as completed Mar 9, 2020
@ghost ghost transferred this issue from shadowsocks/shadowsocks-windows Mar 9, 2020
@ghost ghost reopened this Mar 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests