]> git.ipfire.org Git - thirdparty/tor.git/log
thirdparty/tor.git
7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Fri, 29 Jun 2018 17:07:13 +0000 (13:07 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge remote-tracking branch 'ahf-github/maint-0.3.2' into maint-0.3.2
Nick Mathewson [Fri, 29 Jun 2018 17:07:07 +0000 (13:07 -0400)] 
Merge remote-tracking branch 'ahf-github/maint-0.3.2' into maint-0.3.2

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Fri, 29 Jun 2018 17:06:15 +0000 (13:06 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Fri, 29 Jun 2018 17:06:15 +0000 (13:06 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Fri, 29 Jun 2018 17:06:15 +0000 (13:06 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge remote-tracking branch 'ahf-github/maint-0.3.0' into maint-0.3.1
Nick Mathewson [Fri, 29 Jun 2018 17:06:11 +0000 (13:06 -0400)] 
Merge remote-tracking branch 'ahf-github/maint-0.3.0' into maint-0.3.1

7 years agoMerge remote-tracking branch 'ahf-github/maint-0.3.1' into maint-0.3.1
Nick Mathewson [Fri, 29 Jun 2018 17:06:08 +0000 (13:06 -0400)] 
Merge remote-tracking branch 'ahf-github/maint-0.3.1' into maint-0.3.1

7 years agoChanges file for 26467
Nick Mathewson [Fri, 29 Jun 2018 17:04:29 +0000 (13:04 -0400)] 
Changes file for 26467

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Fri, 29 Jun 2018 17:00:56 +0000 (13:00 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Fri, 29 Jun 2018 17:00:56 +0000 (13:00 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Fri, 29 Jun 2018 17:00:56 +0000 (13:00 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge remote-tracking branch 'ahf-github/maint-0.2.9' into maint-0.2.9
Nick Mathewson [Fri, 29 Jun 2018 17:00:52 +0000 (13:00 -0400)] 
Merge remote-tracking branch 'ahf-github/maint-0.2.9' into maint-0.2.9

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Tue, 26 Jun 2018 13:21:59 +0000 (09:21 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Tue, 26 Jun 2018 13:21:59 +0000 (09:21 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Tue, 26 Jun 2018 13:21:59 +0000 (09:21 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge branch 'feature26372_029' into maint-0.2.9
Nick Mathewson [Tue, 26 Jun 2018 13:21:55 +0000 (09:21 -0400)] 
Merge branch 'feature26372_029' into maint-0.2.9

7 years agoFix memory leak in test_sr_setup_commits().
Alexander Færøy [Sat, 23 Jun 2018 09:31:59 +0000 (11:31 +0200)] 
Fix memory leak in test_sr_setup_commits().

This patch fixes a memory leak in test_sr_setup_commits() where the
place_holder is allocated, but never freed again.

See: Coverity CID 1437440.

7 years agoFix memory leak in disk_state_parse_commits().
Alexander Færøy [Sat, 23 Jun 2018 09:28:00 +0000 (11:28 +0200)] 
Fix memory leak in disk_state_parse_commits().

This patch fixes a memory leak in disk_state_parse_commits() where if
commit is NULL, we continue the internal loop, but without ever freeing
the args variable.

See: Coverity CID 1437441.

7 years agoFix memory leak in frac_nodes_with_descriptors().
Alexander Færøy [Sat, 23 Jun 2018 01:24:10 +0000 (03:24 +0200)] 
Fix memory leak in frac_nodes_with_descriptors().

This patch fixes a memory leak in frac_nodes_with_descriptors() where
we might return without free'ing the bandwidths variable.

See: Coverity CID 1437451.

7 years agoFix memory leak in helper_add_hsdir_to_networkstatus().
Alexander Færøy [Sat, 23 Jun 2018 11:05:41 +0000 (13:05 +0200)] 
Fix memory leak in helper_add_hsdir_to_networkstatus().

This patch fixes a memory leak in helper_add_hsdir_to_networkstatus()
where the rs object might not get properly freed.

See: Coverity CID 1437427.

7 years agoFix memory leak in new_establish_intro_cell().
Alexander Færøy [Sat, 23 Jun 2018 08:48:42 +0000 (10:48 +0200)] 
Fix memory leak in new_establish_intro_cell().

This patch fixes a memory leak in new_establish_intro_cell() that could
happen if a test assertion fails and the *cell_out value isn't properly
free'd.

See: Coverity CID 1437445

7 years agoFix memory leak in test_channelpadding_consensus().
Alexander Færøy [Sat, 23 Jun 2018 10:52:04 +0000 (12:52 +0200)] 
Fix memory leak in test_channelpadding_consensus().

The relay variable is always allocated, but might not be freed before we
return from this function.

See: Coverity CID 1437431

7 years agoFix memory link in test_link_specifier().
Alexander Færøy [Sat, 23 Jun 2018 10:39:20 +0000 (12:39 +0200)] 
Fix memory link in test_link_specifier().

This patch fixes a memory leak in test_link_specifier() where ls might
not get freed in case one of the test macros fails.

See: Coverity CID 1437434.

7 years agoFix memory leak in decode_link_specifiers().
Alexander Færøy [Sat, 23 Jun 2018 09:54:36 +0000 (11:54 +0200)] 
Fix memory leak in decode_link_specifiers().

This patch fixes a memory leak in decode_link_specifiers() where the
hs_spec variable might leak if the default label is taken in the
switch/case expression.

See: Coverity CID 1437437.

7 years agoFix memory leak in client_likes_consensus().
Alexander Færøy [Sat, 23 Jun 2018 08:33:40 +0000 (10:33 +0200)] 
Fix memory leak in client_likes_consensus().

This patches fixes a memory leak in client_likes_consensus() where if
consensus_cache_entry_get_voter_id_digests() would fail we would return
without having free'd the voters list.

See: Coverity CID 1437447

7 years agoFix potential memory leak in hs_helper_build_hs_desc_impl().
Alexander Færøy [Sat, 23 Jun 2018 08:27:10 +0000 (10:27 +0200)] 
Fix potential memory leak in hs_helper_build_hs_desc_impl().

This patch fixes a memory leak in hs_helper_build_hs_desc_impl() where
if a test assertion would fail we would leak the storage that `desc`
points to.

See: Coverity CID 1437448

7 years agoFix memory leak in pick_hsdir_v3().
Alexander Færøy [Sat, 23 Jun 2018 01:40:32 +0000 (03:40 +0200)] 
Fix memory leak in pick_hsdir_v3().

This patch fixes a memory leak in pick_hsdir_v3() where we might return
early, but forgot to free the responsible_hsdirs variable. We solve this
by not allocating storage for responsible_hsdirs until it's actually
needed.

See: Coverity CID 1437449

7 years agoFix potential memory leak in test_hs_auth_cookies().
Alexander Færøy [Sat, 23 Jun 2018 01:17:09 +0000 (03:17 +0200)] 
Fix potential memory leak in test_hs_auth_cookies().

This patch fixes a potential memory leak in test_hs_auth_cookies() if a
test-case fails and we goto the done label where no memory clean up is
done.

See: Coverity CID 1437453

7 years agoFix potential memory leak in hs_helper_build_intro_point().
Alexander Færøy [Fri, 22 Jun 2018 22:44:33 +0000 (00:44 +0200)] 
Fix potential memory leak in hs_helper_build_intro_point().

This patch fixes a potential memory leak in
hs_helper_build_intro_point() where a `goto done` is called before the
`intro_point` variable have been assigned to the value of the `ip`
variable.

See: Coverity CID 1437460
See: Coverity CID 1437456

7 years agoPrefer recent Python 3 in autoconf.
Nick Mathewson [Thu, 21 Jun 2018 13:28:50 +0000 (09:28 -0400)] 
Prefer recent Python 3 in autoconf.

Closes ticket 26372.

7 years agoFix changes file for memory leak.
Nick Mathewson [Thu, 21 Jun 2018 12:53:37 +0000 (08:53 -0400)] 
Fix changes file for memory leak.

7 years agofix memory leak in protover.c
Roger Dingledine [Wed, 20 Jun 2018 23:43:58 +0000 (19:43 -0400)] 
fix memory leak in protover.c

Fix a memory leak where directory authorities would leak a chunk of
memory for every router descriptor every time they considered voting.

This bug was taking down directory authorities in the live network due
to out-of-memory issues.

Fixes bug 26435; bugfix on 0.3.3.6.

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Sun, 17 Jun 2018 23:24:48 +0000 (19:24 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Sun, 17 Jun 2018 23:24:48 +0000 (19:24 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Sun, 17 Jun 2018 23:24:48 +0000 (19:24 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoAdd .editorconfig to follow coding standards style
juga0 [Sun, 3 Jun 2018 10:44:02 +0000 (10:44 +0000)] 
Add .editorconfig to follow coding standards style

7 years agoFix a bug in my fix for #26258
Nick Mathewson [Sat, 16 Jun 2018 17:08:40 +0000 (13:08 -0400)] 
Fix a bug in my fix for #26258

The fix here is use a different bourne shell subsitution for
CARGO_ONLINE, so that an empty string counts as set.

7 years agoMerge remote-tracking branch 'public/bug26258_033' into maint-0.3.3
Nick Mathewson [Thu, 14 Jun 2018 16:47:09 +0000 (12:47 -0400)] 
Merge remote-tracking branch 'public/bug26258_033' into maint-0.3.3

7 years agosquash! Make sure that the test_rust.sh script fails when a test fails
Nick Mathewson [Wed, 13 Jun 2018 16:21:25 +0000 (12:21 -0400)] 
squash! Make sure that the test_rust.sh script fails when a test fails

Also make sure that we're actually running the test from within the right
cwd, like we do when we're building.  This seems necessary to avoid
an error when running offline.

Amusingly, it appears that we had this bug before: we just weren't
noticing it, because of bug 26258.

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Wed, 13 Jun 2018 13:59:28 +0000 (09:59 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Wed, 13 Jun 2018 13:59:28 +0000 (09:59 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoFix an extra space in a changes file
Nick Mathewson [Wed, 13 Jun 2018 13:59:26 +0000 (09:59 -0400)] 
Fix an extra space in a changes file

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Wed, 13 Jun 2018 13:58:05 +0000 (09:58 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Wed, 13 Jun 2018 13:58:04 +0000 (09:58 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'bug26158_031' into maint-0.3.1
Nick Mathewson [Wed, 13 Jun 2018 13:58:01 +0000 (09:58 -0400)] 
Merge branch 'bug26158_031' into maint-0.3.1

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Wed, 13 Jun 2018 13:57:10 +0000 (09:57 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'bug25686_diagnostic_032' into maint-0.3.2
Nick Mathewson [Wed, 13 Jun 2018 13:56:17 +0000 (09:56 -0400)] 
Merge branch 'bug25686_diagnostic_032' into maint-0.3.2

7 years agobump to 0.3.3.7-dev
Nick Mathewson [Tue, 12 Jun 2018 16:05:09 +0000 (12:05 -0400)] 
bump to 0.3.3.7-dev

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Tue, 12 Jun 2018 13:44:17 +0000 (09:44 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Tue, 12 Jun 2018 13:44:17 +0000 (09:44 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Tue, 12 Jun 2018 13:44:17 +0000 (09:44 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'dannenberg_ipv6_029' into maint-0.2.9
Nick Mathewson [Tue, 12 Jun 2018 13:44:13 +0000 (09:44 -0400)] 
Merge branch 'dannenberg_ipv6_029' into maint-0.2.9

7 years agoAdd a changelog entry.
Linus Nordberg [Sun, 10 Jun 2018 11:09:38 +0000 (13:09 +0200)] 
Add a changelog entry.

7 years agoAdd IPv6 orport address for dannenberg.
Linus Nordberg [Sun, 10 Jun 2018 09:07:00 +0000 (11:07 +0200)] 
Add IPv6 orport address for dannenberg.

7 years agoBump to 0.3.3.7
Nick Mathewson [Tue, 12 Jun 2018 12:57:09 +0000 (08:57 -0400)] 
Bump to 0.3.3.7

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Tue, 12 Jun 2018 12:18:56 +0000 (08:18 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Tue, 12 Jun 2018 12:18:56 +0000 (08:18 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge remote-tracking branch 'teor/bug26272-031' into maint-0.3.1
Nick Mathewson [Tue, 12 Jun 2018 12:18:53 +0000 (08:18 -0400)] 
Merge remote-tracking branch 'teor/bug26272-031' into maint-0.3.1

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Tue, 12 Jun 2018 12:11:20 +0000 (08:11 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Tue, 12 Jun 2018 12:11:20 +0000 (08:11 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Tue, 12 Jun 2018 12:11:19 +0000 (08:11 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoSeveral attempts to diagnose ticket 25686
Nick Mathewson [Mon, 11 Jun 2018 20:14:57 +0000 (16:14 -0400)] 
Several attempts to diagnose ticket 25686

There are a few reasons that relays might be uploading desciptors
without saying X-Desc-Gen-Reason:
  1. They are running an old version of our software, before 0.3.2.stable.
  2. They are not running our software, but they are claiming they
     are.
  3. They are uploading through a proxy that strips X-Desc-Gen-Reason.
  4. They somehow had a bug in their software.

According to the 25686 data, 1 is the most common reason.  This
ticket is an attempt to diagnose case 4, or prove that case 4
doesn't actually happen.

7 years agoUpdate geoip and geoip6 to the June 7 2018 database.
Karsten Loesing [Mon, 11 Jun 2018 19:58:55 +0000 (21:58 +0200)] 
Update geoip and geoip6 to the June 7 2018 database.

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Fri, 8 Jun 2018 14:12:57 +0000 (10:12 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Fri, 8 Jun 2018 14:11:57 +0000 (10:11 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Fri, 8 Jun 2018 14:11:57 +0000 (10:11 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoAvoid out-of-bounds smartlist access in protover_compute_vote()
rl1987 [Mon, 4 Jun 2018 09:27:10 +0000 (12:27 +0300)] 
Avoid out-of-bounds smartlist access in protover_compute_vote()
and contract_protocol_list()

7 years agoSilence unused-const-variable warnings in zstd.h on some gcc versions
teor [Sat, 2 Jun 2018 21:08:01 +0000 (14:08 -0700)] 
Silence unused-const-variable warnings in zstd.h on some gcc versions

Fixes bug 26272; bugfix on 0.3.1.1-alpha.

7 years agoMerge branch 'bug26121-033-squashed' into maint-0.3.3
Nick Mathewson [Sat, 2 Jun 2018 17:36:44 +0000 (10:36 -0700)] 
Merge branch 'bug26121-033-squashed' into maint-0.3.3

7 years agoBug 26121: Improve BUILDTIMEOUT_SET accuracy.
Mike Perry [Wed, 16 May 2018 06:42:41 +0000 (06:42 +0000)] 
Bug 26121: Improve BUILDTIMEOUT_SET accuracy.

We were miscounting the total number of circuits for the TIMEOUT_RATE and
CLOSE_RATE fields of this event.

7 years agoMake sure that the test_rust.sh script fails when a test fails
Nick Mathewson [Fri, 1 Jun 2018 00:15:57 +0000 (17:15 -0700)] 
Make sure that the test_rust.sh script fails when a test fails

Exit codes from find(1) seem not to be so reliable as we had hoped.

Closes ticket 26258; bugfix on 0.3.3.4-alpha when we fixed #25560

7 years agoMerge remote-tracking branch 'public/bug25691_033_again_squashed' into maint-0.3.3
Nick Mathewson [Sun, 27 May 2018 14:03:11 +0000 (10:03 -0400)] 
Merge remote-tracking branch 'public/bug25691_033_again_squashed' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Thu, 24 May 2018 13:40:06 +0000 (09:40 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Thu, 24 May 2018 13:40:06 +0000 (09:40 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Thu, 24 May 2018 13:40:06 +0000 (09:40 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'bug26116_033' into maint-0.3.3
Nick Mathewson [Thu, 24 May 2018 13:40:00 +0000 (09:40 -0400)] 
Merge branch 'bug26116_033' into maint-0.3.3

7 years agoMerge branch 'bug26116_029' into maint-0.2.9
Nick Mathewson [Thu, 24 May 2018 13:39:46 +0000 (09:39 -0400)] 
Merge branch 'bug26116_029' into maint-0.2.9

7 years agoAdd a unit test for PEM-encrypted documents.
Nick Mathewson [Thu, 24 May 2018 13:36:33 +0000 (09:36 -0400)] 
Add a unit test for PEM-encrypted documents.

7 years agoUpdate version to 0.3.3.6-dev
Nick Mathewson [Tue, 22 May 2018 22:05:28 +0000 (18:05 -0400)] 
Update version to 0.3.3.6-dev

7 years agoMerge branch 'trove-2018-005_032' into maint-0.3.3
Nick Mathewson [Tue, 22 May 2018 18:13:23 +0000 (14:13 -0400)] 
Merge branch 'trove-2018-005_032' into maint-0.3.3

7 years agoavoid a signed/unsigned comparison.
Nick Mathewson [Tue, 22 May 2018 18:12:44 +0000 (14:12 -0400)] 
avoid a signed/unsigned comparison.

7 years agoMake the TROVE-2018-005 fix work with rust.
Nick Mathewson [Tue, 22 May 2018 17:35:20 +0000 (13:35 -0400)] 
Make the TROVE-2018-005 fix work with rust.

7 years agoMerge branch 'trove-2018-005_032' into maint-0.3.3
Nick Mathewson [Tue, 22 May 2018 16:54:26 +0000 (12:54 -0400)] 
Merge branch 'trove-2018-005_032' into maint-0.3.3

7 years agouint breaks compilation on windows
Nick Mathewson [Tue, 22 May 2018 16:54:05 +0000 (12:54 -0400)] 
uint breaks compilation on windows

7 years agoversion bump to 0.3.3.6
Nick Mathewson [Tue, 22 May 2018 16:40:18 +0000 (12:40 -0400)] 
version bump to 0.3.3.6

7 years agorust: Mirror TROVE-2018-005 fix in Rust protover implementation.
Isis Lovecruft [Wed, 21 Mar 2018 02:22:54 +0000 (02:22 +0000)] 
rust: Mirror TROVE-2018-005 fix in Rust protover implementation.

 * REFACTORS `UnvalidatedProtoEntry::from_str` to place the bulk of the
   splitting/parsing logic in to a new
   `UnvalidatedProtoEntry::parse_protocol_and_version_str()` method (so that
   both `from_str()` and `from_str_any_len()` can call it.)
 * ADD a new `UnvalidatedProtoEntry::from_str_any_len()` method in order to
   maintain compatibility with consensus methods older than 29.
 * ADD a limit on the number of characters in a protocol name.
 * FIXES part of #25517: https://bugs.torproject.org/25517

7 years agoMerge branch 'trove-2018-005_032' into trove-2018-005_033
Nick Mathewson [Tue, 22 May 2018 16:27:15 +0000 (12:27 -0400)] 
Merge branch 'trove-2018-005_032' into trove-2018-005_033

7 years agochanges file for TROVE-2018-005
Nick Mathewson [Tue, 22 May 2018 16:21:00 +0000 (12:21 -0400)] 
changes file for TROVE-2018-005

7 years agoAdd stdbool to protover.h. Only needed for the 032 backport
Nick Mathewson [Tue, 22 May 2018 16:15:52 +0000 (12:15 -0400)] 
Add stdbool to protover.h. Only needed for the 032 backport

7 years agovote: TROVE-2018-005 Make DirAuths omit misbehaving routers from their vote.
Isis Lovecruft [Mon, 7 May 2018 23:59:06 +0000 (23:59 +0000)] 
vote: TROVE-2018-005 Make DirAuths omit misbehaving routers from their vote.

7 years agoprotover: TROVE-2018-005 Fix potential DoS in protover protocol parsing.
Isis Lovecruft [Thu, 29 Mar 2018 01:54:05 +0000 (01:54 +0000)] 
protover: TROVE-2018-005 Fix potential DoS in protover protocol parsing.

In protover.c, the `expand_protocol_list()` function expands a `smartlist_t` of
`proto_entry_t`s to their protocol name concatenated with each version number.
For example, given a `proto_entry_t` like so:

    proto_entry_t *proto = tor_malloc(sizeof(proto_entry_t));
    proto_range_t *range = tor_malloc_zero(sizeof(proto_range_t));

    proto->name = tor_strdup("DoSaaaaaaaaaaaaaaaaaaaaaa[19KB]aaa");
    proto->ranges = smartlist_new();

    range->low = 1;
    range->high = 65536;

    smartlist_add(proto->ranges, range);

(Where `[19KB]` is roughly 19KB of `"a"` bytes.)  This would expand in
`expand_protocol_list()` to a `smartlist_t` containing 65536 copies of the
string, e.g.:

    "DoSaaaaaaaaaaaaaaaaaaaaaa[19KB]aaa=1"
    "DoSaaaaaaaaaaaaaaaaaaaaaa[19KB]aaa=2"
    […]
    "DoSaaaaaaaaaaaaaaaaaaaaaa[19KB]aaa=65535"

Thus constituting a potential resource exhaustion attack.

The Rust implementation is not subject to this attack, because it instead
expands the above string into a `HashMap<String, HashSet<u32>` prior to #24031,
and a `HashMap<UnvalidatedProtocol, ProtoSet>` after).  Neither Rust version is
subject to this attack, because it only stores the `String` once per protocol.
(Although a related, but apparently of too minor impact to be usable, DoS bug
has been fixed in #24031. [0])

[0]: https://bugs.torproject.org/24031

 * ADDS hard limit on protocol name lengths in protover.c and checks in
   parse_single_entry() and expand_protocol_list().
 * ADDS tests to ensure the bug is caught.
 * FIXES #25517: https://bugs.torproject.org/25517

7 years agoAdd a missing "return -1" when checking for Ed25519 ID loops
Nick Mathewson [Tue, 22 May 2018 12:54:17 +0000 (08:54 -0400)] 
Add a missing "return -1" when checking for Ed25519 ID loops

Fixes bug 26158; bugfix on 0.3.0.1-alpha.

7 years agoFix a crash bug when testing reachability
Nick Mathewson [Sun, 4 Mar 2018 15:31:17 +0000 (10:31 -0500)] 
Fix a crash bug when testing reachability

Fixes bug 25415; bugfix on 0.3.3.2-alpha.

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Wed, 16 May 2018 16:11:45 +0000 (12:11 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3

7 years agoMerge branch 'maint-0.3.1' into maint-0.3.2
Nick Mathewson [Wed, 16 May 2018 16:11:45 +0000 (12:11 -0400)] 
Merge branch 'maint-0.3.1' into maint-0.3.2

7 years agoMerge branch 'maint-0.2.9' into maint-0.3.1
Nick Mathewson [Wed, 16 May 2018 16:11:45 +0000 (12:11 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.1

7 years agoMerge branch 'bug26072_029' into maint-0.2.9
Nick Mathewson [Wed, 16 May 2018 16:11:40 +0000 (12:11 -0400)] 
Merge branch 'bug26072_029' into maint-0.2.9

7 years agoMerge branch 'bug26116_029' into bug26116_033
Nick Mathewson [Wed, 16 May 2018 15:43:53 +0000 (11:43 -0400)] 
Merge branch 'bug26116_029' into bug26116_033

7 years agoReturn -1 from our PEM password callback
Nick Mathewson [Wed, 16 May 2018 15:39:42 +0000 (11:39 -0400)] 
Return -1 from our PEM password callback

Apparently, contrary to its documentation, this is how OpenSSL now
wants us to report an error.

Fixes bug 26116; bugfix on 0.2.5.16.

7 years agoMerge branch 'maint-0.3.2' into maint-0.3.3
Nick Mathewson [Tue, 15 May 2018 13:32:44 +0000 (09:32 -0400)] 
Merge branch 'maint-0.3.2' into maint-0.3.3