Skip to content
Commit 136537c2 authored by Damian Johnson's avatar Damian Johnson
Browse files

Don't check 'UseMicrodescriptors 1' when calling get_network_statuses()

So much confusion around this...

  https://trac.torproject.org/projects/tor/ticket/24110

It turns out in practice these methods essentially never provided
microdescriptor flavored router status entries because 'UseMicrodescriptors'
defaults to 'auto' (and it's rare to set it to '1' since that's the default
anyway). However, if that was done we stacktraced...

  >>> desc = next(controller.get_network_statuses())
  Traceback (most recent call last):
    File "<console>", line 1, in <module>
    File "/home/atagar/Desktop/stem/stem/control.py", line 494, in wrapped
      for val in func(self, *args, **kwargs):
    File "/home/atagar/Desktop/stem/stem/control.py", line 1993, in get_network_statuses
      for desc in desc_iterator:
    File "/home/atagar/Desktop/stem/stem/descriptor/router_status_entry.py", line 104, in _parse_file
      yield entry_class(desc_content, validate, *extra_args)
    File "/home/atagar/Desktop/stem/stem/descriptor/router_status_entry.py", line 446, in __init__
      raise ValueError("%s must have a '%s' line:\n%s" % (self._name(True), keyword, str(self)))
  ValueError: Router status entries (micro v3) must have a 'm' line:
  r networkofthesmoker AAaX5kASI9/xzl9Qp7aFdPOSnrQ aoqBoLrUWKssJAKnO8r6GpZs5p8 2017-11-02 13:51:59 128.72.180.74 443 0
  s Fast Guard HSDir Running Stable V2Dir Valid
  w Bandwidth=4150

From what I can tell nowadays UseMicrodescriptors doesn't change the 'GETINFO
ns/all' response. As such reverting...

  https://gitweb.torproject.org/stem.git/commit/?id=d70fa9cd
parent c01d8c85
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment