Browse Source

Merge #842: Don't request privkey for ephemeral onion from Tor

8b0d08d260 Don't request privkey for ephemeral onion from Tor (Adam Gibson)

Pull request description:

  Prior to this commit, the Tor control request `ADD_ONION`
  did not specify that the private key need not be returned.
  After this commit we add the flag `DiscardPK` by specifying
  the argument private_key=txtorcon.DISCARD to the call to
  `create_onion_endpoint`, so that the private key is not
  returned. The private key is not needed, so this is better.

ACKs for top commit:
  kristapsk:
    ACK 8b0d08d260 (tested payjoin send from BTCPay to JM)

Tree-SHA512: dc6891cb91e896f7d7ad114ab85b3d78babb34186400d00ac80f09138c3303b6c1b05d3c3376a085c0e42a4b6e8399119896c8f2d00631d1a9a397195fabe624
master
Kristaps Kaupe 5 years ago
parent
commit
b6c7a48a6f
No known key found for this signature in database
GPG Key ID: 33E472FE870C7E5D
  1. 2
      jmbase/jmbase/twisted_utils.py

2
jmbase/jmbase/twisted_utils.py

@ -131,7 +131,7 @@ class JMHiddenService(object):
def create_onion_ep(self, t):
self.tor_connection = t
return t.create_onion_endpoint(self.port)
return t.create_onion_endpoint(self.port, private_key=txtorcon.DISCARD)
def onion_listen(self, onion_ep):
return onion_ep.listen(self.site)

Loading…
Cancel
Save