Opened 5 months ago

Closed 5 months ago

#26032 closed defect (fixed)

suggestion URL is broken (duplicate [[]])

Reported by: cypherpunks Owned by: iwakeh
Priority: Medium Milestone:
Component: Metrics/ExoneraTor Version:
Severity: Normal Keywords:
Cc: metrics-team Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

https://exonerator.torproject.org/?ip=%5B2a06%3Ae80%3A1%3A%3A11%5D&timestamp=2018-04-01&lang=en

"
We did not find IP address 2a06:e80:1::11 on or within a day of 2018-04-01. But we did find other IP addresses of Tor relays in the same /48 network around the time:

https://exonerator.torproject.org/?ip=[[2a06%3Ae80%3A1%3A%3A10]]&timestamp=2018-04-01&lang=en
""
clicking that URL gives:

Invalid IP address parameter

The problem relies in the duplicate brackets.

Child Tickets

Change History (3)

comment:1 Changed 5 months ago by iwakeh

Owner: changed from metrics-team to iwakeh
Status: newaccepted

Taking a look at this.

comment:2 Changed 5 months ago by iwakeh

Cc: metrics-team added
Status: acceptedneeds_review

It seems the database query supplies some (or all; I didn't check the productive db) ipv6 addresses surrounded by brackets, but ExoneraTorServlet expects ipv6 addresses from the db to be without brackets, which causes the error.

Please review this patch adding a test with various possible inputs and removing all superfluous brackets when creating suggestion links.

Of course, the removal of brackets could also be placed elsewhere, for example into QueryResult, but the above patch puts this functionality close to the suggestion link generation, because this seems to be the only affected place.

comment:3 Changed 5 months ago by karsten

Resolution: fixed
Status: needs_reviewclosed

Fix looks good! Merged and deployed. Thanks! Closing.

Note: See TracTickets for help on using tickets.