Commit Graph

24597 Commits

Author SHA1 Message Date
Nick Mathewson
746d959100 Don't build circuits till primary guards have descriptors
In addition to not wanting to build circuits until we can see most
of the paths in the network, and in addition to not wanting to build
circuits until we have a consensus ... we shouldn't build circuits
till all of our (in-use) primary guards have descriptors that we can
use for them.

This is another bug 21242 fix.
2017-01-31 12:31:43 -05:00
Nick Mathewson
02da24f8e5 Don't (usually) return any guards that are missing descriptors.
Actually, it's _fine_ to use a descriptorless guard for fetching
directory info -- we just shouldn't use it when building circuits.
Fortunately, we already have a "usage" flag that we can use here.

Partial fix for bug 21242.
2017-01-31 12:30:33 -05:00
Nick Mathewson
26957a127a entry_guard_pick_for_circuit(): TRAFFIC guards must have descriptors
This relates to the 21242 fix -- entry_guard_pick_for_circuit()
should never yield nodes without descriptors when the node is going
to be used for traffic, since we won't be able to extend through
them.
2017-01-31 11:47:09 -05:00
Nick Mathewson
93b39c5162 Downgrade assertion to nonfatal for #21242
This assertion triggered in the (error) case where we got a result
from guards_choose_guard() without a descriptor.  That's not
supposed to be possible, but it's not worth crashing over.
2017-01-31 11:35:57 -05:00
Nick Mathewson
09a00a2f82 Merge remote-tracking branch 'public/bug21300' 2017-01-31 11:09:04 -05:00
Nick Mathewson
cccd3f1dae entrynodes: Remove "split these functions" XXXXs
They now have a ticket: #21349.
2017-01-30 10:49:40 -05:00
Nick Mathewson
ed4a3dfef2 Remove XXXXprop271 comments from test_entrynodes.c
These commments were complaints about how I didn't like some aspects
of prop271.  They have been superseded by ticket 20832.
2017-01-30 10:43:53 -05:00
Nick Mathewson
7d0df8bad8 Remove a couple of stale comments from entrynodes.h 2017-01-30 10:38:24 -05:00
Nick Mathewson
fe04bdcdbb GUARD_WAIT is now specified too 2017-01-30 10:33:17 -05:00
Nick Mathewson
ead934e61e Remove prop271 "spec deviation" comments -- the spec has been updated
In some cases, replace those comments with better ones.
2017-01-30 10:30:09 -05:00
Nick Mathewson
4d83999213 Make "GETCONF SocksPort" work again
I broke "GETCONF *Port" in 20956, when I made SocksPort a
subordinate option of the virtual option SocksPortLines, so that I
could make SocksPort and __SocksPort provide qthe same
functionality.  The problem was that you can't pass a subordinate
option to GETCONF.

So, this patch fixes that by letting you fetch subordinate options.

It won't always be meaningful to consider these options
out-of-context, but that can be the controller-user's
responsibility to check.

Closes ticket 21300.
2017-01-30 10:09:47 -05:00
Nick Mathewson
088cc3604b Don't use %zu in fuzz-http: windows doesn't like it. 2017-01-30 09:09:42 -05:00
Nick Mathewson
195acd90c9 Fix an error in Fuzzing.md. (asn spotted this) 2017-01-30 08:46:47 -05:00
Nick Mathewson
558c04f5b1 Merge branch 'combined-fuzzing-v4' 2017-01-30 08:40:46 -05:00
Nick Mathewson
d71fc47438 Update documentation and testing integration for fuzzing 2017-01-30 08:37:27 -05:00
Nick Mathewson
2202ad7ab0 Fix a pair of compilation errors. 2017-01-30 08:37:27 -05:00
Nick Mathewson
1d8e9e8c69 Fix memory leak on zero-length input on fuzz_http.c 2017-01-30 08:37:27 -05:00
Nick Mathewson
143235873b Memory leak on bogus ed key in microdesc 2017-01-30 08:37:26 -05:00
Nick Mathewson
34fd636870 memory leak in fuzz_vrs 2017-01-30 08:37:26 -05:00
Nick Mathewson
a092bcdd4f Fix a memory leak found while fuzzing 2017-01-30 08:37:26 -05:00
Nick Mathewson
09d01466b2 actually build .as for fuzzing 2017-01-30 08:37:26 -05:00
Nick Mathewson
1c7862bfb4 missing backslash 2017-01-30 08:37:26 -05:00
Nick Mathewson
f547352637 differently build oss fuzzers 2017-01-30 08:37:26 -05:00
Nick Mathewson
cf71f8ad32 More oss-fuzz fixes 2017-01-30 08:37:25 -05:00
Nick Mathewson
92679d90d5 Try to refactor OSS fuzzers into static libraries. 2017-01-30 08:37:25 -05:00
Nick Mathewson
99d4faf6d3 oss_fuzz also requires no PIE 2017-01-30 08:37:25 -05:00
Nick Mathewson
1b244a64e4 libfuzzer tweaks per recommendations 2017-01-30 08:37:25 -05:00
Nick Mathewson
024fa9d4d7 routerstatus fuzzing 2017-01-30 08:37:25 -05:00
Nick Mathewson
eb414a08a9 Add libfuzzer support. 2017-01-30 08:37:25 -05:00
Nick Mathewson
b1567cf500 Three more fuzzers: consensus, hsdesc, intro points 2017-01-30 08:37:24 -05:00
Nick Mathewson
83e9918107 Tools for working with directories of fuzzed stuff. 2017-01-30 08:37:24 -05:00
Nick Mathewson
301eff0e90 fuzzing: Add copyright notices and whitespace fixes 2017-01-30 08:37:24 -05:00
Nick Mathewson
4afb155db2 Add microdesc format fuzzer. 2017-01-30 08:37:24 -05:00
Nick Mathewson
3c74855934 Addition to test cases: make sure fuzzer binaries allow known cases
This isn't fuzzing per se, so much as replaying the highlights of
past fuzzer runs.
2017-01-30 08:37:24 -05:00
Nick Mathewson
81e44c2257 Add extrainfo fuzzer 2017-01-30 08:37:24 -05:00
Nick Mathewson
44fa14c0e2 Try to tweak fuzzing.md to correspond to my changes 2017-01-30 08:37:24 -05:00
teor
0fb1156e9f Add a script for running multiple fuzzing sessions on multiple cores 2017-01-30 08:37:23 -05:00
teor
416e2f6b28 Guide fuzzing by adding standard tor GET and POST testcases 2017-01-30 08:37:23 -05:00
Nick Mathewson
56b61d1831 Add more tweaks from teor's http fuzzing code.
Move option-manipulation code to fuzzing_common.
2017-01-30 08:37:23 -05:00
teor
584d723e04 Restrict fuzzing to the directory headers 2017-01-30 08:37:23 -05:00
Nick Mathewson
f009b13029 Copy fuzzing instructions by teor 2017-01-30 08:37:23 -05:00
Nick Mathewson
949e9827d6 Add a descriptor fuzzing dictionary. 2017-01-30 08:37:23 -05:00
Nick Mathewson
ca657074b9 Fuzzing: initialize siphash key, don't init_logging twice. 2017-01-30 08:37:23 -05:00
Nick Mathewson
0666928c5c Replace signature-checking and digest-checking while fuzzing 2017-01-30 08:37:22 -05:00
Nick Mathewson
e2aeaeb76c Make a bunch of signature/digest-checking functions mockable 2017-01-30 08:37:22 -05:00
meejah
fc58c37e33 Ticket #21329: GETINFO onions/current returns empty list
If there are no ephemeral or detached onion services, then
"GETINFO onions/current" or "GETINFO onions/detached" should
return an empty list instead of an error
2017-01-28 13:59:29 -07:00
Nick Mathewson
67eb6470d7 Merge branches 'server_ciphers' and 'ciphers.inc' 2017-01-27 16:45:18 -05:00
Nick Mathewson
26a9787aa5 MOre gen_server_ciphers improvements:
- Remove DES from mandatory list.
  - always put the closing ; on its own line.
2017-01-27 16:15:26 -05:00
Nick Mathewson
3bfe5dae04 Merge remote-tracking branch 'dgoulet/ticket21269_030_01' 2017-01-27 11:26:23 -05:00
Daniel Kahn Gillmor
e1337b4252 client: set IPv6Traffic to on by default
See:
  https://trac.torproject.org/projects/tor/ticket/21269
  https://bugs.debian.org/851798

Closes #21269

Signed-off-by: David Goulet <dgoulet@torproject.org>
2017-01-27 09:12:32 -05:00