Open dsbaars opened 2 years ago
This is incredibly important IMO. I'm hearing from many node operators who are choosing to abandon Tor-only in favor of a clearnet IPv4 or VPN due to negative effects of Tor network congestion affecting their ability to route payments. At a time when online privacy is under attack, any effort to decrease reliance on Tor should be a priority.
Great proposal/feature request. Looks like PR #5651 is trying to achieve very similar objectives.
While I think adding other proxy/connection types is a good idea in general, just adding generic support for proxies in lnd
doesn't mean they can be used for p2p connections (at least not end to end) automatically. For the wider network to understand I2P for example, the spec also needs to be adjusted.
Duplicate of https://github.com/lightningnetwork/lnd/issues/6595
Currently, LND allows for Tor connectivity by connecting to the Tor socks proxy and/or Control port. No other proxies are currently supported, but this would be beneficial to users since it could provide a way to allow for clearnet, i2p and other connectivity like cjdns.
Implementation idea
I have never written in go myself before, but it looks like the code from the
tor
package can be used as a basis for SOCKS5 proxies. It think it is good to start refactoring to a genericproxy
package and let thetor
package build upon that (which is already suggested in the comments in the source files).Considerations
tor.skip-proxy-for-clearnet-targets=true
should be used when next to tor, a generic proxy is used.