-
Notifications
You must be signed in to change notification settings - Fork 31
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
v3: Allow migration from Tor to Onionbalance #10
Comments
OK this is not an easy feature but it should be possible. Here are some notes. The reason is that Tor stores the identity private key of onion services in a special format (let's call it the Tor format here, but it's also what bittorrent uses) so that it can support key blinding. In particular, it stores private keys in a OTOH, the Python3 cryptography module that Onionbalance and stem uses, do ed25519 private keys with the standard Unfortunately, it's not possible to go from the Tor format to the standard format, which means that we can't read the identity private key of a real Tor instance, and translate it to a format that stem will understand, and then pass it to stem, and do things normally. This means that the only solution here is to parse the private identity key of Tor, and then create a wrapper class for that private key in Onionbalance that will emulate the behavior of a standard ed25519 format in terms of duck-typing. Then pass that emulated standard private key to stem and let it use it. I already did something similar for stem in the past, so I think I can re-use that code here. However, I would need to pay close attention because this is a complicated procedure. |
I'm encountering issues with the approach outlined in the comment above. It might not be possible to do duck-typing wrapper classes for hazmat keys because stem actually checks that the received identity private key is a hazmat key with I then thought of tricking So I think this approach is busted. Seems like I need to think of something smarter, or write a patch for stem and then implement this in Onionbalance.... |
Please see #17 for an approach here!!!! |
Allow operators to migrate their onion service from tor to onionbalance.
This means that we need to parse the v3 private key and make it into an onionbalance private key. Let's hope that the ed25519 private key formats don't prove too complicated here.
The text was updated successfully, but these errors were encountered: