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

Add Socks v5 support to daemon and wallet #9443

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vtnerd
Copy link
Contributor

@vtnerd vtnerd commented Aug 17, 2024

Socks v5 adds IPv6 support and basic username/password authentication. The user/pass authentication is a cheap way to prevent rogue applications from requesting proxied connections. Tor and SSH do not support authentication but I2P, Nym, and Dante do.

When I started this implementation, I didn't know Nym added Socks v4 support. This makes the patch somewhat less useful, as the original #8562 Socks v5 request was for Nym support. This patch might want to be rejected on that reason alone - the only useful features are user/pass and IPv6.

This includes a fairly extensive explanation of proxies in the daemon and cli wallets, so that might be useful for keeping regardless.

@vtnerd
Copy link
Contributor Author

vtnerd commented Aug 18, 2024

Crap, looks like older versions of boost don't have some ASIO functionality I used. Crap, will have to update.

@tobtoht
Copy link
Collaborator

tobtoht commented Aug 18, 2024

What would be the minimum Boost version for this PR?

Is it time to undust #9162 and bump the minimum Boost requirement?

@vtnerd
Copy link
Contributor Author

vtnerd commented Aug 18, 2024

The minimum version for this feature would be 1.67. In this case, its not really critical, I should be able to work-around it.

@iamamyth
Copy link

After many years, IPv6 has started to see substantial, and increasing, adoption, so I think this would be a reasonable addition. However, it's not urgent, and, based on the comments in #9162, I think you could safely assume Boost 1.67 (Ubuntu 18.04 continues to wither) and roll out this feature after a boost version upgrade to 1.67. Of course, you can do the extra work to support the current Boost version, but you may very well have better uses for your time.

@vtnerd
Copy link
Contributor Author

vtnerd commented Aug 21, 2024

I just pushed a change to fix the Boost issues. Everything looks good for that.

The functional tests failed, but it looks spurious right now. Testing locally to confirm, and may just push a dummy update to re-run the tests.

@vtnerd
Copy link
Contributor Author

vtnerd commented Aug 21, 2024

Good for review!

Copy link
Contributor

@sneurlax sneurlax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adds SOCKSv5 support with tests and documentation included. Tested working. The code looks relatively minimal such that I don't see anything to remove, really. I don't see any potential privacy or security concerns, LGTM

@sneurlax
Copy link
Contributor

Closes #9443

@woodser
Copy link
Contributor

woodser commented Oct 8, 2024

Closes #9390 ?

@woodser
Copy link
Contributor

woodser commented Feb 21, 2025

This PR needs rebased, and hopefully moves forward. Will be nice to support IPv6.

@vtnerd
Copy link
Contributor Author

vtnerd commented Feb 26, 2025

Force Push:

  • To newest version of master, with changes along the way to resolve conflicts
  • Changes requested by @nahuhh

@vtnerd
Copy link
Contributor Author

vtnerd commented Feb 26, 2025

Force pushed a size check fix.

Copy link

@SyntheticBird45 SyntheticBird45 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested, no issues.

@nahuhh
Copy link
Contributor

nahuhh commented Mar 3, 2025

@vtnerd would it make sense to revert this change, since boost on master and release has been updated to 1.67+?

https://github.com/monero-project/monero/compare/9a9d2064290ac9f8f8137053341efe2ee3412a2a..f3fcac82acbbf35cc9c23a1cc0e6c36620ab194e

@vtnerd
Copy link
Contributor Author

vtnerd commented Mar 3, 2025

Yes, looks like this is no longer needed, so I will try to revert that change.

@vtnerd
Copy link
Contributor Author

vtnerd commented Mar 3, 2025

Force pushed a change to revert the workaround for older Boost versions. I'm not sure if this is a good idea, as officially the last supported version is Boost 1.66

@selsta , what do you think?

@vtnerd
Copy link
Contributor Author

vtnerd commented Mar 3, 2025

Nevermind, I just checked again and this code should work with Boost 1.66+ so everything should be good.

@nahuhh
Copy link
Contributor

nahuhh commented Mar 3, 2025

Force pushed a change to revert the workaround for older Boost versions. I'm not sure if this is a good idea, as officially the last supported version is Boost 1.66

@selsta , what do you think?

Also, i think we're raising min to 1.69
#9807 (comment)

@selsta
Copy link
Collaborator

selsta commented Mar 3, 2025

@nahuhh we will use 1.69 for release binaries but ideally work around the boost bug so we can keep a lower minimum

@vtnerd
Copy link
Contributor Author

vtnerd commented Mar 3, 2025

I just verified this still compiles with Boost 1.66-1.87, so no issues with that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants