-
Notifications
You must be signed in to change notification settings - Fork 63
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
Issue with plugin when using always-use-proxy=true and a local tower #219
Comments
Hi @21M4TW, there're a couple of things to have in mind here:
I guess we could make a single exception for localhost, even if this is not the intended use case. |
Yes I understand your point about not providing protection if there is a power/internet outage. I would not rely solely on a local tower for sure. Maybe it could make sense for the plugin to honor always-use-proxy as it currently does, by using an additional watchtower-always-use-proxy parameter whose value defaults to always-use-proxy's value, but that could be set differently if needed? The issue I have when I set always-use-proxy to false (or undefined), is that my node tries to reach its pears through clearnet even if I connect to them using an onion address (the onion address gets replaced by IPv4 when I connect the peer, I don't know why). Maybe the issue I have has more to do with the fact that CLN favors clearnet when a peer can be reached either through Tor or clearnet and always-use-proxy is not set to true? |
Given this is a pretty minimal change, I've created a hotfix for it you can easily try: https://github.com/sr-gi/rust-teos/tree/cln-proxy-localhost I'll wait to reach consensus on whether this is a usecase we'd like to support, but you can go ahead and try it out if this is given you a hard time. This mainly just creates an exception for |
Hi, I tested it, but it does not seem to work unfortunately. I regenerated both the plugin and teosd, and I restarted both teosd and lightningd. I tried: and it says: If I set always-use-proxy it is able to register it... Thanks! |
Sorry, I should have tested that, there was an issue with he localhost parsing. It should work now. |
Thank you. It seems to be working so far. I have not seen any error in the log at least. |
We had something like this before honoring CLN's own
Local IP addresses aren't always this loop back one ( I think we can have the users provide a list of non-proxyable addresses in the config file, those which we won't ever use Tor with. |
That could work |
Yes I agree it would be the most flexible solution :) |
Is there any solution to this? |
@jfrader I guess this #219 (comment) is a sought after solution right now, but there is no PR for it yet. Would be nice if someone could take it from there (maybe start with an incomplete PR and I can provide help as needed). |
@mariocynicys i could take a look at this . |
Hi,
So I have teosd running locally in case lightningd crashes or something goes really wrong with its lightning DB. I have always-use-proxy set to true because I want all peers connections to go through Tor. However when always-use-proxy is set to true, the watchtower-plugin tries connecting through Tor to reach teosd which is running on localhost, so the connection fails. What would make sense here to make it work? Should there be a list of IPs that could be whitelisted to be reacheable directly, should there be a specific exception for 127.0.0.1? Should this be implemented within the watchtower-plugin or within CLN? Thanks!
The text was updated successfully, but these errors were encountered: