Support a proxy running on something other than 127.0.0.1 #127

Open
opened 1 year ago by duke · 8 comments
duke commented 1 year ago
Owner

CLI supports using a proxy on any IP, but the GUI only supports using localhost

CLI supports using a proxy on any IP, but the GUI only supports using localhost
duke added the
feature
label 1 year ago
Collaborator

@duke Talking about adding a setting somewhere here, right?

@duke Talking about adding a setting somewhere here, right? ![](https://git.hush.is/attachments/e81382de-5bcb-4283-818d-0fd5c1236e6f)
Poster
Owner

@fekt yep. Some of the internals of the code needs to be changed too, because it assumes that all proxies are running on 127.0.0.1 . So if "Connect via Tor" is checked, the code is hardcoded to use 127.0.0.1:PORT

@fekt yep. Some of the internals of the code needs to be changed too, because it assumes that all proxies are running on 127.0.0.1 . So if "Connect via Tor" is checked, the code is hardcoded to use 127.0.0.1:PORT
Collaborator

Gotcha. I'm just going through the issues to see what I can work on for next release. This and some others seemed relatively easy.

Gotcha. I'm just going through the issues to see what I can work on for next release. This and some others seemed relatively easy.
Poster
Owner

@fekt yep, this one is relatively easy. Another one that is super easy is #126, should be just one or a few lines of code changes

@fekt yep, this one is relatively easy. Another one that is super easy is #126, should be just one or a few lines of code changes
Collaborator

I have initial changes for this committed to dev branch. Not tested and not sure if settings actually save yet since I wasn't running an embedded hushd.

I have initial changes for this committed to `dev` branch. Not tested and not sure if settings actually save yet since I wasn't running an embedded hushd.
Poster
Owner

@fekt very nice! The way to test this is to run a Tor proxy on once machine on your LAN, for instance 192.168.1.1 and then attempt to use that address as a proxy for SD running on a different machine, such as 192.168.1.2 . And yes, there are at least 2 main codepaths to test, depending on whether an embedded hushd is being used or not.

@fekt very nice! The way to test this is to run a Tor proxy on once machine on your LAN, for instance 192.168.1.1 and then attempt to use that address as a proxy for SD running on a different machine, such as 192.168.1.2 . And yes, there are at least 2 main codepaths to test, depending on whether an embedded hushd is being used or not.
Collaborator

I'll try and test at some point. I think the pre-existing code might need some tweaks. It seems it might only save the proxy setting to the config file if the Tor setting was unchecked previously.

I was seeing it update the config file at least when testing embedding dragonxd with SilentDragonX. Will need to have it pull the current settings too as I think it just defaults to localhost and default port always.

I'll try and test at some point. I think the pre-existing code might need some tweaks. It seems it might only save the proxy setting to the config file if the Tor setting was unchecked previously. I was seeing it update the config file at least when testing embedding dragonxd with SilentDragonX. Will need to have it pull the current settings too as I think it just defaults to localhost and default port always.
Poster
Owner

@fekt yes, you are probably right. Since there was no options before, only "on or off", it probably doesn't write out the data unless Tor proxy is turned on or off. We will need to change that so it writes out the data if "on or off" changes OR if the value of the proxy ip/port changes.

@fekt yes, you are probably right. Since there was no options before, only "on or off", it probably doesn't write out the data unless Tor proxy is turned on or off. We will need to change that so it writes out the data if "on or off" changes OR if the value of the proxy ip/port changes.
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.