{"action":"created","issue":{"url":"https://api.github.com/repos/micahflee/onionshare/issues/731","repository_url":"https://api.github.com/repos/micahflee/onionshare","labels_url":"https://api.github.com/repos/micahflee/onionshare/issues/731/labels{/name}","comments_url":"https://api.github.com/repos/micahflee/onionshare/issues/731/comments","events_url":"https://api.github.com/repos/micahflee/onionshare/issues/731/events","html_url":"https://github.com/micahflee/onionshare/pull/731","id":352461734,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA5NzY1NzE5","number":731,"title":"Introduce v3 onion support","user":{"login":"mig5","id":99173,"node_id":"MDQ6VXNlcjk5MTcz","avatar_url":"https://avatars2.githubusercontent.com/u/99173?v=4","gravatar_id":"","url":"https://api.github.com/users/mig5","html_url":"https://github.com/mig5","followers_url":"https://api.github.com/users/mig5/followers","following_url":"https://api.github.com/users/mig5/following{/other_user}","gists_url":"https://api.github.com/users/mig5/gists{/gist_id}","starred_url":"https://api.github.com/users/mig5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mig5/subscriptions","organizations_url":"https://api.github.com/users/mig5/orgs","repos_url":"https://api.github.com/users/mig5/repos","events_url":"https://api.github.com/users/mig5/events{/privacy}","received_events_url":"https://api.github.com/users/mig5/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2018-08-21T09:39:36Z","updated_at":"2018-08-23T00:48:18Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/micahflee/onionshare/pulls/731","html_url":"https://github.com/micahflee/onionshare/pull/731","diff_url":"https://github.com/micahflee/onionshare/pull/731.diff","patch_url":"https://github.com/micahflee/onionshare/pull/731.patch"},"body":"This PR introduces v3 onion support. I'm deliberately basing this on the receiver-mode-gui branch because it has so many other breaking changes that it's not worth branching off of develop branch anymore.\r\n\r\nThis PR:\r\n\r\n1) favours v3 onions if the Tor version is new enough\r\n\r\n2) Requires the (testing) user to `pip install pysha3` if they don't have it already (I encountered an issue on Debian 9 whereby, if the version of Python is too low, the logic that uses hashlib doesn't quite work (`hashlib.sha3_256`) , but pysha3 does. However, there's no deb or rpm for it, so it introduces the need to pip install at least one package on those platforms (for the first time) if building/testing from source. Or, more generally, introduces that dependency. Not sure how that will fly for Debian/Ubuntu .debs....\r\n\r\n3) Deliberately hides the 'persistent URL' and 'stealth' features in the settings dialog (since we know those don't work properly with v3 onions) \r\n\r\n4) even if somehow persistent or stealth mode is enabled (think: previously-saved .json file, or command line flags), they are silently ignored (resulting in a non-persistent onion with no stealth)\r\n\r\nOtherwise it contains the logic from my previous prop224 branch. Note the onionkey.py, which *pre-generates* private keys for both v3 and v2 now. This is necessary to interact with Stem with v3 keys, but even more significantly, it paves the way for saving that v3 private key to json once persistence is possible, *and* it paves the way for a 'dead man's switch' feature (reverse shutdown-timer: a *start-up* timer that allows the user to communicate a *future* onionshare URL yet to be published), which I will send a PR for later down the track.\r\n\r\n\r\nI'm assuming it's not quite ready yet.\r\n\r\nthe v3 onion works for both share and receiver mode.\r\n\r\nWelcome testing.\r\n\r\nOnce the persistence feature is released in Tor stable (expected in December), we can remove the logic that ignores-or-hides persistence mode. Likewise for stealth (Client Auth)\r\n\r\n@Baccount "},"comment":{"url":"https://api.github.com/repos/micahflee/onionshare/issues/comments/415235059","html_url":"https://github.com/micahflee/onionshare/pull/731#issuecomment-415235059","issue_url":"https://api.github.com/repos/micahflee/onionshare/issues/731","id":415235059,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNTIzNTA1OQ==","user":{"login":"mig5","id":99173,"node_id":"MDQ6VXNlcjk5MTcz","avatar_url":"https://avatars2.githubusercontent.com/u/99173?v=4","gravatar_id":"","url":"https://api.github.com/users/mig5","html_url":"https://github.com/mig5","followers_url":"https://api.github.com/users/mig5/followers","following_url":"https://api.github.com/users/mig5/following{/other_user}","gists_url":"https://api.github.com/users/mig5/gists{/gist_id}","starred_url":"https://api.github.com/users/mig5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mig5/subscriptions","organizations_url":"https://api.github.com/users/mig5/orgs","repos_url":"https://api.github.com/users/mig5/repos","events_url":"https://api.github.com/users/mig5/events{/privacy}","received_events_url":"https://api.github.com/users/mig5/received_events","type":"User","site_admin":false},"created_at":"2018-08-23T00:48:18Z","updated_at":"2018-08-23T00:48:18Z","author_association":"COLLABORATOR","body":"the Tor version parsing depends on an already-connected Tor. I don't think I can work around that to parse the Tor version any other way. But obviously we need the SettingsDialog to open if there is no Tor connection (to allow users to change the connection method).\r\n\r\nMaybe we should just show the 'use legacy v2 onions' checkbox regardless of the Tor version (e.g even if the Tor version can *only* support legacy v2). Because either way, the backend/CLI will ignore any attempt to use persistence/stealth regardless of what the json settings say, as a safety measure.\r\n\r\nI'll push such a 'fix' for now, and state explicitly in the 'use legacy v2 onion' label that this is true even if unchecked, if the Tor version is too old."}}
{"actor":{"display_login":"mig5"}}