[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #29990 [Core Tor/Tor]: Handle zero monotonic time differences in the circuit padding code
#29990: Handle zero monotonic time differences in the circuit padding code
-------------------------------------------------+-------------------------
Reporter: teor | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor:
| 0.4.1.x-final
Component: Core Tor/Tor | Version: Tor:
| unspecified
Severity: Normal | Resolution:
Keywords: wtf-pad, tor-relay, tor-cell, | Actual Points:
padding, 041-must |
Parent ID: #29500 | Points: 2
Reviewer: | Sponsor:
| Sponsor2
-------------------------------------------------+-------------------------
Comment (by teor):
Replying to [comment:6 mikeperry]:
> Aha, I think I found it! Our mocking forces us to call monotime_init()
*before* we set the mocked time value. monotime_init() thus stores the
first ratchet value at whatever the platform is at, and then we set fake
mocked time to some later value.
>
> If monotime_init() gets a value from the host that is **greater** than
what we choose to mock time at for our unittests, all subsequent
monotime_abosolute() calls return zero.
>
> So, the right way to fix all of this mess is to either fix our mocking
to allow us to call monotime_init() with a mocked time, or just always set
our mocked time to some time after whatever monotime_init() stored.
Oh wow. That's a tricky bug.
> I am going to attempt the later, to see if it fixes whatever hackintosh
VM is involved here (I don't have one of those).
It's just a standard mac, running macOS as host, and macOS inside some
virtual machine software. You can probably achieve the same thing using:
* a script that rapidly changes your hardware or software clock, or
* VMWare, VirtualBox, or qemu with clock skew between guest and host, and
a VM setting that applies the host time to the guest (and an apparent VM
bug which causes the time to switch rapidly between host and guest time).
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/29990#comment:7>
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