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

[FEATURE] Support HTTPS proxy #260

Closed
zonyitoo opened this issue May 21, 2020 · 11 comments
Closed

[FEATURE] Support HTTPS proxy #260

zonyitoo opened this issue May 21, 2020 · 11 comments

Comments

@zonyitoo
Copy link
Collaborator

Does any one really need this?

@zonyitoo zonyitoo assigned zonyitoo and unassigned zonyitoo May 21, 2020
@dev4u
Copy link

dev4u commented May 21, 2020

@dev4u
Copy link

dev4u commented May 21, 2020

If so, I hope the ssserver can be support h2c.

@Mygod
Copy link
Contributor

Mygod commented May 21, 2020

Do you mean CONNECT verb in HTTP proxy?

@zonyitoo
Copy link
Collaborator Author

Do you mean CONNECT verb in HTTP proxy?

Nope. I mean communicating with proxy with https protocol instead of http.

@zonyitoo
Copy link
Collaborator Author

If so, I hope the ssserver can be support h2c.

No. We are discussing https protocol in sslocal.

sslocal <-> ssserver will always be shadowsocks' protocol.

@zonyitoo
Copy link
Collaborator Author

zonyitoo commented May 22, 2020

It will eventually become a MITM proxy.

What if client just connects proxy with HTTPS, and then uses CONNECT method to connect remote targets?

Ref: CURLPROXY_HTTPS

@Mygod
Copy link
Contributor

Mygod commented May 22, 2020

I checked curl's implementation and I think HTTPS proxy is just HTTP proxy over TLS, not MITM. I don't see any reasonable use case for this as we usually assume sslocal runs in a trusted environment.

By the way, socks5 is backwards compatible with socks4/4a. If you really want to go overboard with this, you can identify the incoming connection type (socks5/4/4a/http) by probing the first byte. I think that is what is done in shadowsocks-windows.

@Mygod
Copy link
Contributor

Mygod commented May 22, 2020

If you are looking for some kind of MitM, you might be referring to SNI proxy instead, e.g. https://github.com/dlundquist/sniproxy

I do not see reasonable use case for this either -- even if there is, a separate binary can easily achieve this.

@zonyitoo
Copy link
Collaborator Author

By the way, socks5 is backwards compatible with socks4/4a. If you really want to go overboard with this, you can identify the incoming connection type (socks5/4/4a/http) by probing the first byte. I think that is what is done in shadowsocks-windows.

I know. The only reason that I don't want to implement it is lazy...

I checked curl's implementation and I think HTTPS proxy is just HTTP proxy over TLS, not MITM. I don't see any reasonable use case for this as we usually assume sslocal runs in a trusted environment.

For curl's implementation, it is just a HTTP proxy over TLS. But for mitmproxy, it acts like a transparent HTTPS proxy, which is eventually a MITM proxy.

And yes, I don't think it is necessary to support HTTP proxy over TLS for sslocal.

@Mygod
Copy link
Contributor

Mygod commented May 22, 2020

Same thing for mitmproxy. If you want to use it, just use a separate binary.

@zonyitoo
Copy link
Collaborator Author

I don't. This issue is just an idea pop up in my mind.

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

3 participants