client.py 500 B

1234567891011121314151617181920
  1. #!/usr/bin/env python3
  2. import network
  3. import dirauth
  4. import relay
  5. class Client:
  6. """A class representing a Tor client."""
  7. def __init__(self):
  8. self.consensus = None
  9. # Get a network address for client-side use only (do not bind it
  10. # to the network)
  11. self.myaddr = network.NetAddr()
  12. self.guardaddr = None
  13. def initial_bootstrap(self):
  14. """This method will use the network's fallback relays to enable
  15. this client to choose a guard."""