Nick Mathewson
33841a6030
Merge remote-tracking branch 'teor/fix18809-warnings' into maint-0.2.8
2016-05-19 16:04:56 -04:00
Nick Mathewson
4a14c2cfc7
Merge branch 'maint-0.2.8'
2016-05-19 15:56:39 -04:00
Nick Mathewson
0d6f293e0e
Merge remote-tracking branch 'public/bug19073' into maint-0.2.8
2016-05-19 15:56:31 -04:00
teor (Tim Wilson-Brown)
2d21f03cdc
Fix unused-but-set-variable warnings in the connection unit tests
...
No behaviour change - just remove the variables
2016-05-19 12:49:36 -04:00
Nick Mathewson
a7a44f2db0
Merge branch 'maint-0.2.8'
2016-05-19 08:29:58 -04:00
Nick Mathewson
06803c317f
Fix a compilation error in test_dir.c
2016-05-19 08:27:11 -04:00
Nick Mathewson
d718c717a6
Merge branch 'maint-0.2.8'
2016-05-19 08:25:12 -04:00
Nick Mathewson
9f217c83b0
Merge branch 'bug18809_028_squashed' into maint-0.2.8
2016-05-19 08:17:02 -04:00
teor (Tim Wilson-Brown)
f698b509d8
Add unit tests for networkstatus_consensus_is_bootstrapping
2016-05-19 07:58:41 -04:00
teor (Tim Wilson-Brown)
d5c70d7102
Restore and improve download schedule unit tests
2016-05-19 07:58:41 -04:00
teor (Tim Wilson-Brown)
4254d0297c
Update unit tests for multiple bootstrap connections
2016-05-19 07:58:41 -04:00
Nick Mathewson
159ea7a88f
Fix a bad sizeof() in test_crypto.c. Harmless. Spotted by coverity.
2016-05-18 08:29:13 -04:00
Nick Mathewson
ab932cd7bf
Remove duplicate siging_key_cert fields.
...
With the fix for #17150 , I added a duplicate certificate here. Here
I remove the original location in 0.2.8. (I wouldn't want to do
that in 027, due to the amount of authority-voting-related code
drift.)
Closes 19073.
2016-05-17 20:04:16 -04:00
Nick Mathewson
36909674b4
Merge remote-tracking branch 'teor/bug18963-remember-v2'
2016-05-17 12:15:53 -04:00
Nick Mathewson
6382cd93cb
Merge branch 'maint-0.2.8'
2016-05-17 11:10:20 -04:00
Nick Mathewson
0f9b0b8bfe
Initialize networking _before_ initializing libevent in the tests
...
This prevents WSANOTINITIALISED errors and fixes bug 18668. Bugfix
on 0.2.8.1-alpha -- 1bac468882
specifically.
2016-05-16 14:30:04 -04:00
Nick Mathewson
249f3a1664
Fix memory leak in test_crypto_aes_ctr_testvec
2016-05-16 09:55:09 -04:00
Nick Mathewson
9abd7b8f90
Windows lacks truncate(3).
...
Fix the new crypto tests, which used truncate(3).
2016-05-16 09:25:19 -04:00
Nick Mathewson
060e0d0a75
Merge branch 'crypto_unit_tests_v2_squashed'
2016-05-16 08:26:11 -04:00
Nick Mathewson
365d0fcc6d
Cover all our DH code, and/or mark it unreachable.
2016-05-16 08:26:00 -04:00
Nick Mathewson
94b34d1be6
At long last, unit tests for degenerate DH public keys.
...
Apparently, we detect and reject them correctly. Aren't you glad?
2016-05-16 08:26:00 -04:00
Nick Mathewson
d88656ec06
Slight improvements to DH coverage.
2016-05-16 08:25:59 -04:00
Nick Mathewson
7a5f15b6e0
Improve test coverage of our strongest-rng code.
2016-05-16 08:25:59 -04:00
Nick Mathewson
148f0004e1
Test coverage on ed25519 load/store functions.
2016-05-16 08:25:59 -04:00
Nick Mathewson
8a536be705
Mark unreachable lines in crypto_curve25519.c
...
Also, resolve a bug in test_ntor_cl.c
2016-05-16 08:25:53 -04:00
Nick Mathewson
df3a5e0cad
HKDF-SHA256 test vectors from RFC5869
2016-05-16 08:25:53 -04:00
Nick Mathewson
a7207329a8
Run tor_sscanf test in subprocess, in hopes of coaxing more info from jenkins
2016-05-12 13:37:05 -04:00
Nick Mathewson
445e05a015
Fix inconsistent tab/space mixing in include.am files.
...
This is a whitespace only, cosmetic fix.
There is still some inconsistency between lists, but less
inconsistency inside individual lists.
2016-05-12 13:06:58 -04:00
Nick Mathewson
607a9056d4
Merge branch 'ftrapv_v3'
...
There were some conflicts here, and some breakage to fix concerning
library link order in newer targets.
2016-05-12 13:00:45 -04:00
Nick Mathewson
fb999abea6
Document why we build memwipe that way.
2016-05-12 12:56:47 -04:00
Nick Mathewson
b1dce55b82
Do not apply bugtrapping flags to test-memwipe, since testing memwipe requires bugs.
...
Fixes bug 18901.
2016-05-12 11:22:10 -04:00
Nick Mathewson
20432fc541
Refactor out u64_dbl_t
...
This type saved a tiny amount of allocation, but not enough to be
worth keeping.
(This is in preparation for moving choose_array_element_by_weight)
2016-05-12 11:21:28 -04:00
Nick Mathewson
ce854a8d22
Add -ftrapv to gcc-hardening ... mostly!
...
We know there are overflows in curve25519-donna-c32, so we'll have
to have that one be fwrapv.
Only apply the asan, ubsan, and trapv options to the code that does
not need to run in constant time. Those options introduce branches
to the code they instrument.
(These introduced branches should never actually be taken, so it
might _still_ be constant time after all, but branch predictors are
complicated enough that I'm not really confident here. Let's aim for
safety.)
Closes 17983.
2016-05-12 11:21:28 -04:00
teor (Tim Wilson-Brown)
cdb528d841
Fetch certificates from the same directory as previous certificates
...
Improves the fix to #18963 .
2016-05-11 13:30:30 -04:00
Nick Mathewson
00ee62b8a5
Merge branch 'pubsub_squashed'
2016-05-11 13:26:29 -04:00
Nick Mathewson
80a6c8caa3
Basic work on a publish/subscribe abstraction
...
The goal here is to provide a way to decouple pieces of the code
that want to learn "when something happens" from those that realize
that it has happened.
The implementation here consists of a generic backend, plus a set of
macros to define and implement a set of type-safe frontends.
2016-05-11 13:25:11 -04:00
Nick Mathewson
33d3572a1d
Merge branch 'feature15588_squashed'
2016-05-09 14:41:36 -04:00
Roger Dingledine
ce8266d52d
fix typos/etc before i go nuts on #18809
2016-05-09 14:40:21 -04:00
John Brooks
dcc11674db
Add client auth for ADD_ONION services
2016-05-09 14:28:58 -04:00
John Brooks
d5a23ce115
Move rend auth cookie en-/decoding to a function
...
Tor stores client authorization cookies in two slightly different forms.
The service's client_keys file has the standard base64-encoded cookie,
including two chars of padding. The hostname file and the client remove
the two padding chars, and store an auth type flag in the unused bits.
The distinction makes no sense. Refactor all decoding to use the same
function, which will accept either form, and use a helper function for
encoding the truncated format.
2016-05-09 14:28:08 -04:00
Nick Mathewson
69380033d6
Merge branch 'timeouts_v2_squashed'
2016-05-09 14:06:10 -04:00
Nick Mathewson
af132fc299
timer tests: differences in timing accuracy can be negative.
...
Also, use symbolic names for good-enough thresholds for timer accuracy.
2016-05-09 14:04:54 -04:00
Nick Mathewson
11a09778d6
Test coverage for timers.
2016-05-09 14:04:54 -04:00
Nick Mathewson
118556e4b3
Quick-and-dirty test for timers code.
2016-05-09 14:04:53 -04:00
Nick Mathewson
5845c22822
Ed25519 test vectors from draft-irtf-cfrg-eddsa-05
2016-05-03 09:54:26 -04:00
Nick Mathewson
54697fa40b
Add test vector for AES_CTR from NIST SP800-38a sec F.5
2016-05-03 09:40:47 -04:00
Nick Mathewson
44a3248197
Add test vector for Curve25519 from RFC7748
2016-05-03 09:31:34 -04:00
Nick Mathewson
405b637598
tests for some of the simpler functions in crypto.c
2016-05-03 09:21:08 -04:00
Nick Mathewson
d1f2af57df
White-box tests for crypto_rand_*_range(), rand_hostname().
...
Coverage-driven; part of ticket 16794.
2016-05-03 09:21:07 -04:00
Nick Mathewson
b72aa18d73
test_bt.sh: Check stderr for backtrace as well as stdout.
...
addresssanitizer likes to put backtraces on stderr.
2016-05-02 12:58:58 -04:00