-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
(socks) proxy support #286
Comments
So, @rklaehn pointed out a simple solution for dialing: use the websocket transport. It should work just fine over any HTTP(s) proxy. All we need to do is expose this somehow. Unfortunately, listening could be tricky. |
So it should work, but in my experiments I could not actually get it to work. Just to clarify: websocket is a complete transport that will work just as well as the native tcp or udp transports? So in theory you could have a swarm just communicating over ws? Or is it in some way limited? |
Yes, it's a full transport. I assumed it wouldn't work because we don't explicitly tell it to use the proxy from the environment. However, it looks like it does this by default. So, this is a bit odd. It should just work. I'm wondering if it's a port issue. Does your proxy not support forwarding to random ports? |
I too need a transport proxy interface. In many cases in Go, proxies are implemented by accepting a EDIT: as mentioned in libp2p/go-ws-transport#33 I instead am just proxying raw |
Did anyone find a solution that worked for this problem?
|
So, I've tested this and dialing does actually work. You just need to correctly configure your environment to use a proxy: https://wiki.archlinux.org/index.php/Proxy_settings#Environment_variables For example, if you're using SSH, you can run Note: this still doesn't help with inbound connections. |
I have my environment variables set in etc/environment and exported http_proxy in ~/.bashrc, Ive tried passing http_proxy before the daemon and before the computes daemon. Im only connecting 2 Ubuntu machines through a bridged network and have them communicate in a swarm. Im still getting the following task status:
|
Ah. Sorry, I forgot. While we can dial websocket addresses, go-ipfs doesn't listen on them by default. That's probably the problem here. Note: we haven't enabled listening by default as our primary usecase for the websocket transport is allowing browsers to dial go-ipfs nodes. Unfortunately, browsers often need to dial websocket over https and IPFS nodes can't get valid certificates. I've opened an issue for enabling it by default: ipfs/kubo#5251. In the mean-time, try running |
|
Damn. It looks like the bootstrappers only listen on |
Any idea what the scope might be to update this? |
Are there any updates? |
Team, are there any updates on this? |
Any updates on this? |
Dialing wss is now supported (libp2p/go-ws-transport#115). So this should work if you use the websocket transport |
Are there bootstrap websocket nodes? |
How are you hoping to use this? If you're trying to leverage the IPFS Public DHT while only having websockets available as a transport you'll be out of luck since most of the DHT server nodes aren't listening on websockets and so your queries won't really work even if you can talk to the bootstrappers. |
In some environments, users need to be able to proxy all traffic through, e.g., a corporate socks proxy. This sucks but is sometimes inevitable.
Solution:
Problems:
The text was updated successfully, but these errors were encountered: