[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #25252 [Core Tor/Tor]: Rust implementation of protover code deviates from C in some cases
#25252: Rust implementation of protover code deviates from C in some cases
------------------------------------+------------------------------------
Reporter: nickm | Owner: nickm
Type: defect | Status: needs_review
Priority: High | Milestone: Tor: 0.3.3.x-final
Component: Core Tor/Tor | Version:
Severity: Normal | Resolution:
Keywords: 033-must protover rust | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
------------------------------------+------------------------------------
Changes (by nickm):
* status: assigned => needs_review
* priority: Medium => High
Comment:
Update: most of the issues here are solvable with a little tweaking. I've
made changes in torspec in a8455f4d1a6ef7 to define the C behavior as
"right" a little more.
The one issue that will be trickiest to handle is that the Rust code
stores versions in a hashset of u32, whereas the C code stores an array of
(lo,hi) pairs. As such, the Rust code needs to reject 1-4000000000 as a
range, or else it will fill up RAM. C accepts such a range everywhere
except during voting.
I propose that we handle that last issue separately from the others.
The easier issues are solved in my branch `protover_rust_compat_v3`, along
with a fix for #25250.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/25252#comment:1>
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