Trac issueshttps://gitlab.torproject.org/legacy/trac/-/issues2020-06-13T15:09:40Zhttps://gitlab.torproject.org/legacy/trac/-/issues/22424Always check for usage underflows in the storage API2020-06-13T15:09:40ZteorAlways check for usage underflows in the storage APITor: 0.3.1.x-finalhttps://gitlab.torproject.org/legacy/trac/-/issues/19483Unit test util/time is broken on OpenBSD2020-06-13T14:58:54ZteorUnit test util/time is broken on OpenBSDThis is in master, I think we should check if it's in 0.2.8 and fix it before the stable release:
```
util/time:
FAIL src/test/test_util.c:302: assert(LONG_MAX OP_EQ tv_udiff(&start, &end)): 2147483647 vs -6005000
[time FAILED]
```...This is in master, I think we should check if it's in 0.2.8 and fix it before the stable release:
```
util/time:
FAIL src/test/test_util.c:302: assert(LONG_MAX OP_EQ tv_udiff(&start, &end)): 2147483647 vs -6005000
[time FAILED]
```
https://buildbot.pixelminers.net/builders/OpenBSD/builds/980/steps/shell_3/logs/stdioTor: 0.2.9.x-finalhttps://gitlab.torproject.org/legacy/trac/-/issues/13538Stop signed left shift overflows in curve25519-donna (non-64-bit)2020-06-13T14:57:34ZteorStop signed left shift overflows in curve25519-donna (non-64-bit)Similarly to #13280, the curve25519-donna.c code contains some signed left shifts of negative numbers, which clang identifies as runtime errors. (This is only an issue with the generic code, not the 64-bit code.)
Under -ftrapv, this cau...Similarly to #13280, the curve25519-donna.c code contains some signed left shifts of negative numbers, which clang identifies as runtime errors. (This is only an issue with the generic code, not the 64-bit code.)
Under -ftrapv, this causes a trap/crash.
I've used a similar strategy to the one in #13280, where we automate the entire SHL32/SHL64 conversion using a perl script. The first commit sets up the macros.
The safe SHL32/SHL64 macros perform potentially overflowing left shifts in unsigned arithmetic.
I'll post a branch as soon as I've set up a change entry (for which I need the bug number).
Version: tor 2.6.?-alpha
git: fc5cab44724e8328e2186f22114625388f1c8f0d (Thu Oct 16 13:29:14 2014 -0400)Tor: 0.2.9.x-final