[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #23998 [Core Tor/Tor]: Add a new HSDir protocol version that definitely doesn't have the 0.3.0.7 bug



#23998: Add a new HSDir protocol version that definitely doesn't have the 0.3.0.7
bug
---------------------------------------+-----------------------------------
 Reporter:  teor                       |          Owner:  (none)
     Type:  defect                     |         Status:  needs_information
 Priority:  Medium                     |      Milestone:  Tor:
                                       |  0.3.2.x-final
Component:  Core Tor/Tor               |        Version:  Tor: 0.3.0.8
 Severity:  Normal                     |     Resolution:
 Keywords:  prop224, tor-hs, tor-spec  |  Actual Points:
Parent ID:                             |         Points:  0.5
 Reviewer:                             |        Sponsor:
---------------------------------------+-----------------------------------

Comment (by dgoulet):

 Replying to [comment:2 nickm]:
 > Hm. We should have made it so that if the version is Tor, and it is
 _less than_ 0.3.0.8, it doesn't count as HSDir.  Is it too late to change
 it that way?

 This is what we do:

 {{{
     if (!strcmpstart(tok->args[0], "Tor ") && found_protocol_list) {
       /* Bug #22447 forces us to filter on this version. */
       if (!tor_version_as_new_as(tok->args[0], "0.3.0.8")) {
         rs->supports_v3_hsdir = 0;
       }
     }
 }}}
 If you advertise a protocol list (which all 0.3.0 do >= do), and we have a
 "Tor ..." version, then we filter on <= 0.3.0.8 to _remove_ the hsdir
 support. This is in `routerstatus_parse_entry_from_string()` in
 routerparse.c.

 Then in `node_supports_v3_hsdir()`:

 {{{
     if (node->ri->platform) {
       if (!strcmpstart(node->ri->platform, "Tor ") &&
           !tor_version_as_new_as(node->ri->platform, "0.3.0.8")) {
         return 0;
       }
     }
 }}}

 Same, it has to start with "Tor ..." else the protocol list is used.

 So if another tor implementation shows up, as long as the version field is
 not set to "Tor ...", then the protocol list is used that is HSDir=2 for
 v3 support.

 Not sure afterall there is a bug? If so, can you point it out teor?

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/23998#comment:3>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs