[tor-bugs] #31126 [Circumvention/Snowflake]: Query.parse returns spurious keys (originating from Object.prototype)

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Jul 19 00:38:56 UTC 2019


#31126: Query.parse returns spurious keys (originating from Object.prototype)
-------------------------------------+------------------------------
 Reporter:  dcf                      |          Owner:  dcf
     Type:  defect                   |         Status:  needs_review
 Priority:  Medium                   |      Milestone:
Component:  Circumvention/Snowflake  |        Version:
 Severity:  Minor                    |     Resolution:
 Keywords:                           |  Actual Points:
Parent ID:                           |         Points:
 Reviewer:                           |        Sponsor:
-------------------------------------+------------------------------
Changes (by dcf):

 * status:  assigned => needs_review


Comment:

 Here's a branch for review. It deletes `Query.parse` and replaces
 `Query.parse(location.search.substr(1))` with `new
 URLSearchParams(location.search)`. Then in a second commit, I converted
 the single call to `Query.buildString(params)` to `new
 URLSearchParams(params).toString()`, and removed the now-unused `Query`
 global.

 https://gitweb.torproject.org/user/dcf/snowflake.git/log/?h=bug31126&id=e87ec6585801eb704ccabb783a56bc9a29ea2c7b
 https://gitweb.torproject.org/user/dcf/snowflake.git/diff/?h=bug31126&id=e87ec6585801eb704ccabb783a56bc9a29ea2c7b&id2=76b81bcf77be01565365833ade805397ed093dc9

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


More information about the tor-bugs mailing list