2016-07-02 19:40:02 +00:00
|
|
|
from stem.control import Controller
|
|
|
|
|
|
|
|
with Controller.from_port(port = 9051) as controller:
|
2016-07-03 15:09:07 +00:00
|
|
|
controller.authenticate("password")
|
2016-07-02 19:40:02 +00:00
|
|
|
|
2016-07-09 23:33:24 +00:00
|
|
|
print("List of relays found on the network:")
|
2016-07-02 19:40:02 +00:00
|
|
|
for desc in controller.get_network_statuses():
|
2016-07-09 23:33:24 +00:00
|
|
|
print("%s (%s) at %s" % (desc.nickname, desc.fingerprint, desc.address))
|