]> git.ipfire.org Git - thirdparty/tor.git/log
thirdparty/tor.git
6 years agoMerge branch 'tor-github/pr/943'
David Goulet [Wed, 24 Apr 2019 13:51:14 +0000 (09:51 -0400)] 
Merge branch 'tor-github/pr/943'

6 years agoMerge branch 'tor-github/pr/955'
David Goulet [Wed, 24 Apr 2019 13:45:32 +0000 (09:45 -0400)] 
Merge branch 'tor-github/pr/955'

6 years agoMerge branch 'tor-github/pr/939'
David Goulet [Wed, 24 Apr 2019 13:43:28 +0000 (09:43 -0400)] 
Merge branch 'tor-github/pr/939'

6 years agoMerge branch 'tor-github/pr/930'
David Goulet [Wed, 24 Apr 2019 13:39:32 +0000 (09:39 -0400)] 
Merge branch 'tor-github/pr/930'

6 years agoMerge remote-tracking branch 'tor-github/pr/944'
Nick Mathewson [Tue, 23 Apr 2019 19:39:23 +0000 (15:39 -0400)] 
Merge remote-tracking branch 'tor-github/pr/944'

6 years agoRename outvar to follow _out convention.
Nick Mathewson [Tue, 23 Apr 2019 18:14:17 +0000 (14:14 -0400)] 
Rename outvar to follow _out convention.

6 years agoMerge remote-tracking branch 'tor-github/pr/935'
Nick Mathewson [Tue, 23 Apr 2019 18:11:04 +0000 (14:11 -0400)] 
Merge remote-tracking branch 'tor-github/pr/935'

6 years agoMerge remote-tracking branch 'tor-github/pr/971'
Nick Mathewson [Tue, 23 Apr 2019 16:52:54 +0000 (12:52 -0400)] 
Merge remote-tracking branch 'tor-github/pr/971'

6 years agoMerge branch 'ticket30051_take2_squashed'
Nick Mathewson [Tue, 23 Apr 2019 16:51:44 +0000 (12:51 -0400)] 
Merge branch 'ticket30051_take2_squashed'

6 years agoAdd changes file
rl1987 [Fri, 19 Apr 2019 06:51:04 +0000 (09:51 +0300)] 
Add changes file

6 years agoCall practracker from pre-push and pre-commit hooks
rl1987 [Fri, 19 Apr 2019 06:46:36 +0000 (09:46 +0300)] 
Call practracker from pre-push and pre-commit hooks

6 years agoMerge remote-tracking branch 'tor-github/pr/962'
Nick Mathewson [Tue, 23 Apr 2019 16:48:37 +0000 (12:48 -0400)] 
Merge remote-tracking branch 'tor-github/pr/962'

6 years agoTravis: Show stem's tor log after failure
teor [Mon, 22 Apr 2019 01:48:07 +0000 (11:48 +1000)] 
Travis: Show stem's tor log after failure

Closes ticket 30234.

6 years agoInitialize rate_limited in hs_pick_hsdir() to false
Neel Chauhan [Fri, 19 Apr 2019 13:50:54 +0000 (09:50 -0400)] 
Initialize rate_limited in hs_pick_hsdir() to false

6 years agoOnly set rate_limited in hs_pick_hsdir() if rate_limited_count or responsible_dirs_co...
Neel Chauhan [Fri, 19 Apr 2019 13:21:20 +0000 (09:21 -0400)] 
Only set rate_limited in hs_pick_hsdir() if rate_limited_count or responsible_dirs_count is greater than 0

6 years agoInitialize rate_limited to false in directory_get_from_hs_dir()
Neel Chauhan [Fri, 19 Apr 2019 13:17:29 +0000 (09:17 -0400)] 
Initialize rate_limited to false in directory_get_from_hs_dir()

6 years agoMake rate_limited and is_rate_limited a bool
Neel Chauhan [Fri, 19 Apr 2019 12:33:00 +0000 (08:33 -0400)] 
Make rate_limited and is_rate_limited a bool

6 years agoMerge branch 'maint-0.4.0'
teor [Fri, 19 Apr 2019 02:00:59 +0000 (12:00 +1000)] 
Merge branch 'maint-0.4.0'

6 years agoMerge branch 'maint-0.3.5' into maint-0.4.0
teor [Fri, 19 Apr 2019 02:00:50 +0000 (12:00 +1000)] 
Merge branch 'maint-0.3.5' into maint-0.4.0

6 years agoMerge branch 'maint-0.3.4' into maint-0.3.5
teor [Fri, 19 Apr 2019 02:00:41 +0000 (12:00 +1000)] 
Merge branch 'maint-0.3.4' into maint-0.3.5

6 years agoMerge branch 'maint-0.2.9' into maint-0.3.4
teor [Fri, 19 Apr 2019 01:59:18 +0000 (11:59 +1000)] 
Merge branch 'maint-0.2.9' into maint-0.3.4

"ours" merge, to avoid taking any changes from PR 792 in 0.3.4.
(We already merged PR 791 for 29665 into 0.3.4.)

6 years agoMerge remote-tracking branch 'tor-github/pr/710' into maint-0.3.5
teor [Fri, 19 Apr 2019 01:52:48 +0000 (11:52 +1000)] 
Merge remote-tracking branch 'tor-github/pr/710' into maint-0.3.5

6 years agoMerge remote-tracking branch 'tor-github/pr/726' into maint-0.3.5
teor [Fri, 19 Apr 2019 01:51:05 +0000 (11:51 +1000)] 
Merge remote-tracking branch 'tor-github/pr/726' into maint-0.3.5

6 years agoMerge remote-tracking branch 'tor-github/pr/745' into maint-0.3.5
teor [Fri, 19 Apr 2019 01:48:41 +0000 (11:48 +1000)] 
Merge remote-tracking branch 'tor-github/pr/745' into maint-0.3.5

6 years agoMerge remote-tracking branch 'tor-github/pr/947' into maint-0.3.5
teor [Fri, 19 Apr 2019 01:47:50 +0000 (11:47 +1000)] 
Merge remote-tracking branch 'tor-github/pr/947' into maint-0.3.5

6 years agoMerge remote-tracking branch 'tor-github/pr/946' into maint-0.3.4
teor [Fri, 19 Apr 2019 01:47:10 +0000 (11:47 +1000)] 
Merge remote-tracking branch 'tor-github/pr/946' into maint-0.3.4

6 years agoMerge remote-tracking branch 'tor-github/pr/638' into maint-0.3.4
teor [Fri, 19 Apr 2019 01:44:38 +0000 (11:44 +1000)] 
Merge remote-tracking branch 'tor-github/pr/638' into maint-0.3.4

6 years agoMerge remote-tracking branch 'tor-github/pr/791' into maint-0.3.4
teor [Fri, 19 Apr 2019 01:43:46 +0000 (11:43 +1000)] 
Merge remote-tracking branch 'tor-github/pr/791' into maint-0.3.4

6 years agoMerge remote-tracking branch 'tor-github/pr/792' into maint-0.2.9
teor [Fri, 19 Apr 2019 01:42:09 +0000 (11:42 +1000)] 
Merge remote-tracking branch 'tor-github/pr/792' into maint-0.2.9

6 years agoMerge branch 'maint-0.2.9' into maint-0.3.4
teor [Fri, 19 Apr 2019 01:39:17 +0000 (11:39 +1000)] 
Merge branch 'maint-0.2.9' into maint-0.3.4

"ours" merge, to avoid taking any changes from PR 772 in 0.3.4.
(We already merged a different fix for 23790 into 0.3.2 and later.)

6 years agoMerge remote-tracking branch 'tor-github/pr/772' into maint-0.2.9
teor [Fri, 19 Apr 2019 01:38:52 +0000 (11:38 +1000)] 
Merge remote-tracking branch 'tor-github/pr/772' into maint-0.2.9

6 years agopractracker: accept more lines in microdescs_parse_from_string()
teor [Fri, 19 Apr 2019 00:34:16 +0000 (10:34 +1000)] 
practracker: accept more lines in microdescs_parse_from_string()

Part of 28223.

6 years agoMerge branch 'tor-github/pr/938'
George Kadianakis [Thu, 18 Apr 2019 10:23:32 +0000 (13:23 +0300)] 
Merge branch 'tor-github/pr/938'

6 years agoMerge branch 'tor-github/pr/925'
George Kadianakis [Thu, 18 Apr 2019 10:22:54 +0000 (13:22 +0300)] 
Merge branch 'tor-github/pr/925'

6 years agoMerge branch 'maint-0.4.0'
George Kadianakis [Thu, 18 Apr 2019 10:22:23 +0000 (13:22 +0300)] 
Merge branch 'maint-0.4.0'

6 years agoMerge branch 'tor-github/pr/891' into maint-0.4.0
George Kadianakis [Thu, 18 Apr 2019 10:21:59 +0000 (13:21 +0300)] 
Merge branch 'tor-github/pr/891' into maint-0.4.0

6 years agoGrammar fixes for IPv6Exit in tor.1.txt
Neel Chauhan [Thu, 18 Apr 2019 01:41:31 +0000 (21:41 -0400)] 
Grammar fixes for IPv6Exit in tor.1.txt

6 years agoUpdate tor.1 man page for IPv6Exit
Neel Chauhan [Wed, 17 Apr 2019 11:26:55 +0000 (07:26 -0400)] 
Update tor.1 man page for IPv6Exit

6 years agopractracker: accept the extra 25 line string from 27821
teor [Wed, 17 Apr 2019 08:44:26 +0000 (18:44 +1000)] 
practracker: accept the extra 25 line string from 27821

6 years agoconnection_edge: remove an extra ;
teor [Wed, 17 Apr 2019 08:43:20 +0000 (18:43 +1000)] 
connection_edge: remove an extra ;

6 years agoconnection_edge: Return a web page when HTTPTunnelPort is misconfigured
teor [Wed, 17 Apr 2019 07:58:40 +0000 (17:58 +1000)] 
connection_edge: Return a web page when HTTPTunnelPort is misconfigured

Return an informative web page when the HTTPTunnelPort is used as an
HTTP proxy.

Closes ticket 27821, patch by "eighthave".

6 years agoMerge branch 'maint-0.4.0'
teor [Wed, 17 Apr 2019 06:46:47 +0000 (16:46 +1000)] 
Merge branch 'maint-0.4.0'

6 years agoMerge branch 'maint-0.3.5' into maint-0.4.0
teor [Wed, 17 Apr 2019 06:46:40 +0000 (16:46 +1000)] 
Merge branch 'maint-0.3.5' into maint-0.4.0

6 years agoUpdate practracker exceptions.txt for policies.c
Neel Chauhan [Tue, 16 Apr 2019 13:16:52 +0000 (09:16 -0400)] 
Update practracker exceptions.txt for policies.c

6 years agoClarify comment about IPv6Exit in policies_parse_exit_policy_from_options()
Neel Chauhan [Tue, 16 Apr 2019 12:22:17 +0000 (08:22 -0400)] 
Clarify comment about IPv6Exit in policies_parse_exit_policy_from_options()

6 years agoClarify torrc comment for IPv6Exit
Neel Chauhan [Tue, 16 Apr 2019 12:20:48 +0000 (08:20 -0400)] 
Clarify torrc comment for IPv6Exit

6 years agoAdd policy_using_default_exit_options() to determine if we're using the default exit...
Neel Chauhan [Tue, 16 Apr 2019 12:19:44 +0000 (08:19 -0400)] 
Add policy_using_default_exit_options() to determine if we're using the default exit options

6 years agoMerge remote-tracking branch 'tor-github/pr/910'
Nick Mathewson [Tue, 16 Apr 2019 12:09:20 +0000 (08:09 -0400)] 
Merge remote-tracking branch 'tor-github/pr/910'

6 years agoMerge remote-tracking branch 'tor-github/pr/884'
Nick Mathewson [Tue, 16 Apr 2019 12:08:06 +0000 (08:08 -0400)] 
Merge remote-tracking branch 'tor-github/pr/884'

6 years agoIn warn_if_nul_found, log surrounding context.
Nick Mathewson [Mon, 15 Apr 2019 19:33:09 +0000 (15:33 -0400)] 
In warn_if_nul_found, log surrounding context.

We need to encode here instead of doing escaped(), since fwict
escaped() does not currently handle NUL bytes.

Also, use warn_if_nul_found in more cases to avoid duplication.

6 years agofixup! Even more diagnostic messages for bug 28223.
Nick Mathewson [Mon, 15 Apr 2019 19:21:18 +0000 (15:21 -0400)] 
fixup! Even more diagnostic messages for bug 28223.

Use TOR_PRIuSZ in place of %zu.

6 years agoDocument check for 30176, since it's a bit subtle.
Nick Mathewson [Mon, 15 Apr 2019 18:52:08 +0000 (14:52 -0400)] 
Document check for 30176, since it's a bit subtle.

6 years agoClear memory in smartlist_remove_keeporder.
Tobias Stoeckmann [Sat, 13 Apr 2019 14:55:36 +0000 (16:55 +0200)] 
Clear memory in smartlist_remove_keeporder.

The smartlist functions take great care to reset unused pointers inside
the smartlist memory to NULL.

The function smartlist_remove_keeporder does not clear memory in such
way when elements have been removed. Therefore call memset after the
for-loop that removes elements. If no element is removed, it is
effectively a no-op.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
6 years agoAdd test to verify that unused pointers are NULL.
Tobias Stoeckmann [Sat, 13 Apr 2019 14:54:05 +0000 (16:54 +0200)] 
Add test to verify that unused pointers are NULL.

The smartlist code takes great care to set all unused pointers inside
the smartlist memory to NULL. Check if this is also the case after
modifying the smartlist multiple times.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
6 years agoMerge branch 'tor-github/pr/941'
George Kadianakis [Mon, 15 Apr 2019 10:57:40 +0000 (13:57 +0300)] 
Merge branch 'tor-github/pr/941'

6 years agoMerge branch 'maint-0.4.0'
George Kadianakis [Mon, 15 Apr 2019 10:56:48 +0000 (13:56 +0300)] 
Merge branch 'maint-0.4.0'

6 years agoMerge branch 'tor-github/pr/948' into maint-0.4.0
George Kadianakis [Mon, 15 Apr 2019 10:56:37 +0000 (13:56 +0300)] 
Merge branch 'tor-github/pr/948' into maint-0.4.0

6 years agoMerge branch 'rust-panic1-035' into rust-panic1-040
teor [Mon, 15 Apr 2019 00:18:59 +0000 (10:18 +1000)] 
Merge branch 'rust-panic1-035' into rust-panic1-040

6 years agoMerge branch 'rust-panic1-034' into rust-panic1-035
teor [Mon, 15 Apr 2019 00:18:01 +0000 (10:18 +1000)] 
Merge branch 'rust-panic1-034' into rust-panic1-035

Trivial merge: a blank line was removed between 0.3.4 and 0.3.5.

6 years agoMerge branch 'rust-panic1' into rust-panic1-034
teor [Mon, 15 Apr 2019 00:15:02 +0000 (10:15 +1000)] 
Merge branch 'rust-panic1' into rust-panic1-034

6 years agoUpdate exceptions.txt for Bug #29613
Neel Chauhan [Sun, 14 Apr 2019 18:27:05 +0000 (14:27 -0400)] 
Update exceptions.txt for Bug #29613

6 years agoAdd changes file for Bug #29613
Neel Chauhan [Fri, 12 Apr 2019 00:22:46 +0000 (20:22 -0400)] 
Add changes file for Bug #29613

6 years agoUpdate torrc.sample.in to IPv6Exit 1 being an exit by default
Neel Chauhan [Fri, 12 Apr 2019 00:22:27 +0000 (20:22 -0400)] 
Update torrc.sample.in to IPv6Exit 1 being an exit by default

6 years agoBecome an exit relay if IPv6Exit is 1
Neel Chauhan [Fri, 12 Apr 2019 00:21:51 +0000 (20:21 -0400)] 
Become an exit relay if IPv6Exit is 1

6 years agoAdd an assertion to test_hs_cache.c to appease coverity.
Nick Mathewson [Sun, 14 Apr 2019 15:31:50 +0000 (11:31 -0400)] 
Add an assertion to test_hs_cache.c to appease coverity.

Coverity doesn't like to see a path where we test a pointer for
NULL if we have already ready dereferenced the pointer on that
path.  While in this case, the check is not needed, it's best not to
remove checks from the unit tests IMO.  Instead, I'm adding an
earlier check, so that coverity, when analyzing this function, will
think that we have always checked the pointer before dereferencing
it.

Closes ticket 30180; CID 1444641.

6 years agochanges: file for 30117
teor [Thu, 11 Apr 2019 02:17:04 +0000 (12:17 +1000)] 
changes: file for 30117

6 years agoTravis: expand "make test-stem", so timelimit can signal python on timeout
teor [Thu, 11 Apr 2019 02:11:03 +0000 (12:11 +1000)] 
Travis: expand "make test-stem", so timelimit can signal python on timeout

Unlike kill, timelimit can only signal the process it launches. So we need
timelimit to launch python, not make.

Closes ticket 30117; diagnostic for 29437.

6 years agoMerge branch 'tor-github/pr/908'
George Kadianakis [Fri, 12 Apr 2019 10:47:08 +0000 (13:47 +0300)] 
Merge branch 'tor-github/pr/908'

6 years agoMerge branch 'tor-github/pr/754'
George Kadianakis [Fri, 12 Apr 2019 10:45:53 +0000 (13:45 +0300)] 
Merge branch 'tor-github/pr/754'

6 years agocrypt_ops: Stop using a separate buffer in ed25519_signature_from_base64()
teor [Fri, 12 Apr 2019 03:00:02 +0000 (13:00 +1000)] 
crypt_ops: Stop using a separate buffer in ed25519_signature_from_base64()

Part of 29960.

6 years agoFix a memory leak in tor-resolve.c
Nick Mathewson [Thu, 11 Apr 2019 23:09:23 +0000 (19:09 -0400)] 
Fix a memory leak in tor-resolve.c

Closes bug 30151/coverity CID 1441830. Bugfix on 0.4.0.1-alpha when
we started doing trunnel parsing in tor-resolve.c.

6 years agoChanges file and practracker updates for 30149.
Nick Mathewson [Thu, 11 Apr 2019 22:58:44 +0000 (18:58 -0400)] 
Changes file and practracker updates for 30149.

6 years agoRemove an extraneous _ from __COVERITY__
Nick Mathewson [Thu, 11 Apr 2019 22:56:02 +0000 (18:56 -0400)] 
Remove an extraneous _ from __COVERITY__

We had a typo in this check, so that coverity wasn't taking the
right path.

Bug not in any released Tor.

6 years agoAdd an assertion to num_ntors_per_tap().
Nick Mathewson [Thu, 11 Apr 2019 22:38:59 +0000 (18:38 -0400)] 
Add an assertion to num_ntors_per_tap().

This should please coverity, and fix CID 1415721.  It didn't
understand that networkstatus_get_param() always returns a value
between its minimum and maximum values.

6 years agoAdd an assertion to compute_weighted_bandwidths()
Nick Mathewson [Thu, 11 Apr 2019 22:38:59 +0000 (18:38 -0400)] 
Add an assertion to compute_weighted_bandwidths()

This should please coverity, and fix CID 1415722.  It didn't
understand that networkstatus_get_param() always returns a value
between its minimum and maximum values.

6 years agoAdd an assertion to pathbias_get_scale_ratio()
Nick Mathewson [Thu, 11 Apr 2019 22:38:59 +0000 (18:38 -0400)] 
Add an assertion to pathbias_get_scale_ratio()

This should please coverity, and fix CID 1415723.  It didn't understand
that networkstatus_get_param() always returns a value between its
minimum and maximum values.

6 years agoforward-port the 0.4.0.4-rc changelog
Nick Mathewson [Thu, 11 Apr 2019 21:06:19 +0000 (17:06 -0400)] 
forward-port the 0.4.0.4-rc changelog

6 years agoMerge branch 'maint-0.4.0'
Nick Mathewson [Thu, 11 Apr 2019 21:05:45 +0000 (17:05 -0400)] 
Merge branch 'maint-0.4.0'

6 years agobump to 0.4.0.4-rc-dev
Nick Mathewson [Thu, 11 Apr 2019 21:05:38 +0000 (17:05 -0400)] 
bump to 0.4.0.4-rc-dev

6 years agoMake repeated/rate limited HSFETCH queries fail with QUERY_RATE_LIMITED
Neel Chauhan [Thu, 11 Apr 2019 19:20:31 +0000 (15:20 -0400)] 
Make repeated/rate limited HSFETCH queries fail with QUERY_RATE_LIMITED

6 years agoMerge remote-tracking branch 'tor-github/pr/913'
Nick Mathewson [Thu, 11 Apr 2019 18:30:05 +0000 (14:30 -0400)] 
Merge remote-tracking branch 'tor-github/pr/913'

6 years agoMerge remote-tracking branch 'tor-github/pr/887'
Nick Mathewson [Thu, 11 Apr 2019 18:29:16 +0000 (14:29 -0400)] 
Merge remote-tracking branch 'tor-github/pr/887'

6 years agoMerge remote-tracking branch 'tor-github/pr/741'
Nick Mathewson [Thu, 11 Apr 2019 18:27:06 +0000 (14:27 -0400)] 
Merge remote-tracking branch 'tor-github/pr/741'

6 years agoTravis: use stem backtrace signals with timelimit
teor [Wed, 10 Apr 2019 11:15:04 +0000 (21:15 +1000)] 
Travis: use stem backtrace signals with timelimit

Part of 30117.

6 years agoMerge branch 'maint-0.4.0'
Nick Mathewson [Wed, 10 Apr 2019 15:52:12 +0000 (11:52 -0400)] 
Merge branch 'maint-0.4.0'

6 years agoBump version to 0.4.0.4-rc
Nick Mathewson [Wed, 10 Apr 2019 15:51:49 +0000 (11:51 -0400)] 
Bump version to 0.4.0.4-rc

6 years agoFix pre-commit hook to correctly allow empty changes files.
Nick Mathewson [Wed, 10 Apr 2019 15:49:23 +0000 (11:49 -0400)] 
Fix pre-commit hook to correctly allow empty changes files.

Fixes bug 30120; bugfix not in any released Tor.

6 years agoMerge branch 'maint-0.4.0'
Nick Mathewson [Wed, 10 Apr 2019 15:31:44 +0000 (11:31 -0400)] 
Merge branch 'maint-0.4.0'

6 years agoMerge remote-tracking branch 'tor-github/pr/926' into maint-0.4.0
Nick Mathewson [Wed, 10 Apr 2019 15:31:33 +0000 (11:31 -0400)] 
Merge remote-tracking branch 'tor-github/pr/926' into maint-0.4.0

6 years agoAdd changes file for #30040.
George Kadianakis [Tue, 9 Apr 2019 14:30:14 +0000 (17:30 +0300)] 
Add changes file for #30040.

6 years agoPrevent double free on huge files with 32 bit.
Tobias Stoeckmann [Sun, 31 Mar 2019 10:27:55 +0000 (12:27 +0200)] 
Prevent double free on huge files with 32 bit.

The function compat_getdelim_ is used for tor_getline if tor is compiled
on a system that lacks getline and getdelim. These systems should be
very rare, considering that getdelim is POSIX.

If this system is further a 32 bit architecture, it is possible to
trigger a double free with huge files.

If bufsiz has been already increased to 2 GB, the next chunk would
be 4 GB in size, which wraps around to 0 due to 32 bit limitations.

A realloc(*buf, 0) could be imagined as "free(*buf); return malloc(0);"
which therefore could return NULL. The code in question considers
that an error, but will keep the value of *buf pointing to already
freed memory.

The caller of tor_getline() would free the pointer again, therefore
leading to a double free.

This code can only be triggered in dirserv_read_measured_bandwidths
with a huge measured bandwith list file on a system that actually
allows to reach 2 GB of space through realloc.

It is not possible to trigger this on Linux with glibc or other major
*BSD systems even on unit tests, because these systems cannot reach
so much memory due to memory fragmentation.

This patch is effectively based on the penetration test report of
cure53 for curl available at https://cure53.de/pentest-report_curl.pdf
and explained under section "CRL-01-007 Double-free in aprintf() via
unsafe size_t multiplication (Medium)".

6 years agoscripts: In git-pull-all.sh, also fetch the latest tor-github pull requests
teor [Wed, 10 Apr 2019 09:26:47 +0000 (19:26 +1000)] 
scripts: In git-pull-all.sh, also fetch the latest tor-github pull requests

Implements ticket 30114.

6 years agopractracker: accept 4 extra lines due to 30041
teor [Wed, 10 Apr 2019 08:29:11 +0000 (18:29 +1000)] 
practracker: accept 4 extra lines due to 30041

6 years agoMerge branch 'maint-0.4.0'
teor [Wed, 10 Apr 2019 08:27:11 +0000 (18:27 +1000)] 
Merge branch 'maint-0.4.0'

6 years agoMerge remote-tracking branch 'tor-github/pr/920' into maint-0.4.0
teor [Wed, 10 Apr 2019 08:26:49 +0000 (18:26 +1000)] 
Merge remote-tracking branch 'tor-github/pr/920' into maint-0.4.0

6 years agoMerge branch 'maint-0.4.0'
Nick Mathewson [Tue, 9 Apr 2019 17:51:44 +0000 (13:51 -0400)] 
Merge branch 'maint-0.4.0'

6 years agoMerge branch 'bug29922_035' into maint-0.4.0
Nick Mathewson [Tue, 9 Apr 2019 17:49:58 +0000 (13:49 -0400)] 
Merge branch 'bug29922_035' into maint-0.4.0

6 years agoActually I believe this should be an EINVAL.
Nick Mathewson [Tue, 9 Apr 2019 17:49:10 +0000 (13:49 -0400)] 
Actually I believe this should be an EINVAL.

6 years agoChanges file for bug30041
Nick Mathewson [Tue, 9 Apr 2019 16:03:22 +0000 (12:03 -0400)] 
Changes file for bug30041

6 years agoCheck return value of buf_move_to_buf for error.
Tobias Stoeckmann [Sun, 31 Mar 2019 15:33:11 +0000 (17:33 +0200)] 
Check return value of buf_move_to_buf for error.

If the concatenation of connection buffer and the buffer of linked
connection exceeds INT_MAX bytes, then buf_move_to_buf returns -1 as an
error value.

This value is currently casted to size_t (variable n_read) and will
erroneously lead to an increasement of variable "max_to_read".

This in turn can be used to call connection_buf_read_from_socket to
store more data inside the buffer than expected and clogging the
connection buffer.

If the linked connection buffer was able to overflow INT_MAX, the call
of buf_move_to_buf would have previously internally triggered an integer
overflow, corrupting the state of the connection buffer.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>