Skip to content

Instantly share code, notes, and snippets.

@mig5
Created October 13, 2018 03:22
Show Gist options
  • Save mig5/4f9b397b17625c4a4a178beb68ed2c21 to your computer and use it in GitHub Desktop.
Save mig5/4f9b397b17625c4a4a178beb68ed2c21 to your computer and use it in GitHub Desktop.
diff --git a/onionshare/onion.py b/onionshare/onion.py
index 7122c20..6066f05 100644
--- a/onionshare/onion.py
+++ b/onionshare/onion.py
@@ -494,7 +494,7 @@ class Onion(object):
# A new private key was generated and is in the Control port response.
if self.settings.get('save_private_key'):
if not self.settings.get('private_key'):
- self.settings.set('private_key', key_content)
+ self.settings.set('private_key', res.private_key)
if self.stealth:
# Similar to the PrivateKey, the Control port only returns the ClientAuth
@@ -579,7 +579,7 @@ class Onion(object):
else:
return (self.settings.get('socks_address'), self.settings.get('socks_port'))
- def is_v2_key(key):
+ def is_v2_key(self, key):
"""
Helper function for determining if a key is RSA1024 (v2) or not.
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment