Commit Graph

30951 Commits

Author SHA1 Message Date
Nick Mathewson
845e8dbe59 Fuzzing module for various string operations, currently focusing on
encoding and decoding.

There are bunches of places where we don't want to invest in a full
fuzzer, but we would like to make sure that some string operation
can handle all its possible inputs.  This fuzzer uses the first byte
of its input to decide what to do with the rest of the input.  Right
now, all the possibilities are decoding a string, and seeing whether
it is decodeable.  If it is, we try to re-encode it and do the whole
thing again, to make sure we get the same result.

This turned up a lot of bugs in the key-value parser, and I think it
will help in other cases too.

Closes ticket 28808.
2018-12-12 11:07:08 -05:00
Nick Mathewson
f0a8664677 Add code to parse K=V lines into config_line_t format.
Closes ticket 28755
2018-12-12 11:07:08 -05:00
Nick Mathewson
2ccb9e9444 Merge branch 'maint-0.3.5' 2018-12-06 09:26:34 -05:00
Nick Mathewson
c1f86f7492 Merge branch 'maint-0.3.4' into maint-0.3.5 2018-12-06 09:26:33 -05:00
Nick Mathewson
c4f7953d8b Merge branch 'maint-0.3.3' into maint-0.3.4 2018-12-06 09:26:32 -05:00
Nick Mathewson
00341d97f3 Merge branch 'maint-0.2.9' into maint-0.3.3 2018-12-06 09:26:32 -05:00
Karsten Loesing
57798eb1cb Update geoip and geoip6 to the December 5 2018 database. 2018-12-05 21:02:39 +01:00
Nick Mathewson
46a321fbdd Merge branch 'maint-0.3.5' 2018-12-05 10:25:12 -05:00
Nick Mathewson
967efc0d28 Merge remote-tracking branch 'tor-github/pr/546' into maint-0.3.5 2018-12-05 10:23:28 -05:00
Nick Mathewson
1eb3719a62 Merge remote-tracking branch 'public/prop298' 2018-12-05 09:43:03 -05:00
Nick Mathewson
1f95e80351 Merge branch 'prop293_squashed' 2018-12-05 09:24:51 -05:00
Nick Mathewson
a2f81b644b Write tests for mark_my_descriptor_dirty_if_too_old() 2018-12-05 09:24:45 -05:00
Nick Mathewson
d4f558e385 Merge remote-tracking branch 'tor-github/pr/531' 2018-12-05 09:02:49 -05:00
Nick Mathewson
4002a84ffe Merge remote-tracking branch 'tor-github/pr/561' 2018-12-05 08:29:41 -05:00
Nick Mathewson
00509aaafa Merge remote-tracking branch 'tor-github/pr/553' 2018-12-05 08:28:54 -05:00
Nick Mathewson
ca4b86f90a Merge remote-tracking branch 'tor-github/pr/508' 2018-12-05 08:19:02 -05:00
Nick Mathewson
c01507a5fe remember why we are doing getsockopt() 2018-12-05 08:14:21 -05:00
Nick Mathewson
4c81ab5914 Merge remote-tracking branch 'tor-github/pr/560' 2018-12-05 08:13:02 -05:00
Nick Mathewson
df70bc3a88 Merge branch 'ticket28479_squashed' 2018-12-05 07:59:44 -05:00
Nick Mathewson
1f6d7bc4af Update ReleasingTor.md to reflect current practice
See #28479.
2018-12-05 07:58:53 -05:00
David Goulet
8506dcdeb7 Merge branch 'maint-0.3.5' 2018-12-04 12:55:02 -05:00
David Goulet
0906dde9d5 man: Document HSv3 client authorization revocation
Removing a ".auth" file revokes a client access to the service but the
rendezvous circuit is not closed service side because the service simply
doesn't know which circuit is for which client.

This commit notes in the man page that to fully revoke a client access to the
service, the tor process should be restarted.

Closes #28275

Signed-off-by: David Goulet <dgoulet@torproject.org>
2018-12-04 18:49:19 +02:00
Nick Mathewson
31a6d9f499 Add tests for parsing each routerstatus flag. 2018-12-03 13:40:08 -05:00
Nick Mathewson
92af8e5113 Add a framework for testing set_routerstatus_from_routerinfo().
Additionally, use it to test that is_staledesc is set correctly.

Eventually we'll want to test all the other flags, but I'm aiming
for only adding coverage on the changed code here.
2018-12-03 13:22:23 -05:00
Nick Mathewson
417a324a85 Make input argument const in set_routerstatus_from_routerinfo. 2018-12-03 12:34:29 -05:00
Nick Mathewson
32213fa9ad Keep list of dirauth flags in sync between dirvote.c and fuzz_vrs.c
Suggested by Teor on PR
2018-12-03 12:18:45 -05:00
rl1987
894d207f84 manpage: Mention that adding new HS is unsupported if Sandbox is enabled 2018-12-03 15:23:01 +02:00
rl1987
db9ab3754a Print error message we get from socket.connect_ex when it fails 2018-12-03 14:49:33 +02:00
rl1987
25f3b82445 More logging for #28229 2018-12-03 14:40:37 +02:00
rl1987
9369152aae Check that new listener connection is actually listening 2018-12-03 14:28:32 +02:00
Nick Mathewson
0d9dc13e08 Merge remote-tracking branch 'tor-github/pr/544' 2018-12-02 19:50:04 -05:00
Nick Mathewson
8221b5d587 Merge remote-tracking branch 'tor-github/pr/559' 2018-12-02 19:38:40 -05:00
teor
90ce8d0a58
doc: remove cached-routers from the man page
cached-routers was removed from the code a long time ago
2018-12-03 10:22:49 +10:00
teor
612b21b8ea
comment: replace cached-routers with cached-descriptors
cached-routers has been gone for a long time
2018-12-03 10:19:34 +10:00
Nick Mathewson
0015d00842 Use tor_strdup() in place of malloc+strncpy+terminate. 2018-12-01 20:46:06 -05:00
Nick Mathewson
8accf71c44 Merge remote-tracking branch 'tor-github/pr/556' 2018-12-01 20:35:38 -05:00
Nick Mathewson
2b2b97484a Merge branch 'ticket27490a_squashed' 2018-12-01 20:32:18 -05:00
Neel Chauhan
ad031b64ce Add regression test for ClientAutoIPv6ORPort 2018-12-01 14:55:57 -05:00
Neel Chauhan
81f2828d67 In fascist_firewall_use_ipv6(), say we can use IPv6 if ClientAutoIPv6ORPort is 1 2018-12-01 14:55:57 -05:00
Neel Chauhan
822cb93cab Add new option ClientAutoIPv6ORPort to switch between IPv4 and IPv6 OR ports 2018-12-01 14:55:57 -05:00
rl1987
009205dabe Add changes file 2018-12-01 14:31:17 -05:00
rl1987
353d2a091d Fix coverage build 2018-12-01 14:31:17 -05:00
rl1987
39e158db36 tor-resolve: Rework SOCKS5 response parsing with trunnel 2018-12-01 14:31:17 -05:00
rl1987
8b9d6581f6 tor-resolve: Rework SOCKS5 method negotiation client part with trunnel 2018-12-01 14:31:17 -05:00
rl1987
1051969a1d tor-resolve: parse SOCKS4a reply 2018-12-01 14:31:17 -05:00
rl1987
d49baa77b5 Allow socks4_server_reply version to be 0 (for tor-resolve) 2018-12-01 14:31:17 -05:00
rl1987
83af6d6149 tor-resolve: Use trunnel code for SOCKS5 request generation 2018-12-01 14:31:17 -05:00
rl1987
30582b940e tor-resolve: link tor-resolve binary with trunnel lib 2018-12-01 14:31:17 -05:00
rl1987
a2bb172225 tor-resolve: generate SOCKS4a request with trunnel 2018-12-01 14:31:17 -05:00
Nick Mathewson
701eaef980 Move net.inet.ip.random_id code to lib/net/ 2018-12-01 11:36:03 -05:00