[tor-bugs] #20714 [Metrics/CollecTor]: Retain hidserv- lines in sanitized bridge extra-info descriptors

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Nov 18 16:39:49 UTC 2016


#20714: Retain hidserv- lines in sanitized bridge extra-info descriptors
-----------------------------------+--------------------------
     Reporter:  karsten            |      Owner:  metrics-team
         Type:  defect             |     Status:  new
     Priority:  High               |  Milestone:
    Component:  Metrics/CollecTor  |    Version:
     Severity:  Normal             |   Keywords:
Actual Points:                     |  Parent ID:
       Points:                     |   Reviewer:
      Sponsor:                     |
-----------------------------------+--------------------------
 CollecTor logs recently started containing lines like this:

 {{{
 2016-11-18 09:09:01,897 WARN o.t.c.b.SanitizedBridgesWriter:1214
 Unrecognized line 'hidserv-stats-end 2016-11-17 22:50:24 (86400 s)'.
 Skipping.
 }}}

 The reason is that we don't have code in
 `SanitizedBridgesWriter#sanitizeAndStoreExtraInfoDescriptor()` to handle
 `hidserv-` lines, and the default is to skip descriptors with unknown
 lines.

 There's nothing particular sensitive in these lines that would reveal the
 bridge IP address or location.  We should simply copy them over like the
 other statistics lines.

 Patch:

 {{{
 diff --git
 a/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java
 b/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java
 index 5e101eb..c54d83e 100644
 ---
 a/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java
 +++
 b/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java
 @@ -1192,7 +1192,8 @@ public class SanitizedBridgesWriter extends
 CollecTorMain {
              || line.startsWith("dirreq-")
              || line.startsWith("cell-")
              || line.startsWith("entry-")
 -            || line.startsWith("exit-")) {
 +            || line.startsWith("exit-")
 +            || line.startsWith("hidserv-")) {
            scrubbed.append(line + "\n");

          /* When we reach the signature, we're done. Write the sanitized
 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/20714>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list