Nick Mathewson [Tue, 6 Nov 2012 22:15:39 +0000 (17:15 -0500)]
Fix a stupid logic-error in warnings about low ports.
Instead of warning about low ports that are advertised, we should have
been warning about low ports that we're listening on. Bug 7285, fix
on 0.2.3.9-alpha.
Nick Mathewson [Fri, 2 Nov 2012 17:14:39 +0000 (13:14 -0400)]
Avoid c99 designated initializers in circuitmux_ewma.c
We still want to build on compilers w/o c99 support, such as
(notoriously, shamefully) MSVC.
So I'm commenting out the designated initializers in
circuitmux_ewma.c. The alternative would have been to use some kind
of macros to use designated initializers only when they're
supported, but that's error-prone, and can lead to code having
different meanings under different compilers.
Bug 7286; fix on 0.2.4.4-alpha; spotted by Gisle Vanem.
Fix undefined reference to libm functions linking tor-fw-helper
When configuring tor without upnp support, ie ./configure --disable-upnp,
tor-fw-helper fails to link with undefined references to `ceil' and
`log'. This if fixed by linking to libm.
X-Gentoo-Bug: 435040
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=435040 Reported-by: Alexandre <alexandre.cortes@outlook.com> Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Nick Mathewson [Wed, 24 Oct 2012 03:04:35 +0000 (23:04 -0400)]
Fix a remotely triggerable assertion failure (CVE-2012-2250)
If we completed the handshake for the v2 link protocol but wound up
negotiating the wong protocol version, we'd become so confused about
what part of the handshake we were in that we'd promptly die with an
assertion.
This is a fix for CVE-2012-2250; it's a bugfix on 0.2.3.6-alpha.
All servers running that version or later should really upgrade.
Bug and fix from "some guy from France." I tweaked his code slightly
to make it log the IP of the offending node, and to forward-port it to
0.2.4.
Nick Mathewson [Wed, 24 Oct 2012 02:58:38 +0000 (22:58 -0400)]
Fix a remotely triggerable assertion failure (CVE-2012-2250)
If we completed the handshake for the v2 link protocol but wound up
negotiating the wong protocol version, we'd become so confused about
what part of the handshake we were in that we'd promptly die with an
assertion.
This is a fix for CVE-2012-2250; it's a bugfix on 0.2.3.6-alpha.
All servers running that version or later should really upgrade.
Bug and fix from "some guy from France." I tweaked his code slightly
to make it log the IP of the offending node.
Nick Mathewson [Wed, 24 Oct 2012 01:50:43 +0000 (21:50 -0400)]
Merge remote-tracking branch 'origin/maint-0.2.3'
This is an "ours" merge; we want a separate fix for this bug (bug7191)
in master. Rather than catching the two failing cases, we need to make
them not fail.
Nick Mathewson [Tue, 23 Oct 2012 21:12:37 +0000 (17:12 -0400)]
Fix binary search on lists of 0 or 1 element.
The implementation we added has a tendency to crash with lists of 0 or
one element. That can happen if we get a consensus vote, v2
consensus, consensus, or geoip file with 0 or 1 element. There's a
DOS opportunity there that authorities could exploit against one
another, and which an evil v2 authority could exploit against anything
downloading v2 directory information..
This fix is minimalistic: It just adds a special-case for 0- and
1-element lists. For 0.2.4 (the current alpha series) we'll want a
better patch.
Roger Dingledine [Mon, 22 Oct 2012 19:45:39 +0000 (15:45 -0400)]
Let 0.2.3 clients exit to internal addresses if they want
Clients now consider the ClientRejectInternalAddresses config option
when using a microdescriptor consensus stanza to decide whether
an exit relay would allow exiting to an internal address. Fixes
bug 7190; bugfix on 0.2.3.1-alpha.
Nick Mathewson [Mon, 22 Oct 2012 15:35:32 +0000 (11:35 -0400)]
Merge branch 'split_circuitbuild'
Conflicts:
src/or/circuitbuild.c
There was a huge-looking conflict in circuitbuild.c, but the only
change that had been made to circuitbuild.c since I forked off the
split_circuitbuild branch was 17442560c44e8093f9a. So I took the
split_circuitbuild version of the conflicting part, and manually
re-applied the change from 17442560c44e8093f9a..
Nick Mathewson [Wed, 17 Oct 2012 23:57:27 +0000 (19:57 -0400)]
Disable TLS Session Tickets, which we were apparently getting for free
OpenSSL 1.0.0 added an implementation of TLS session tickets, a
"feature" that let session resumption occur without server-side state
by giving clients an encrypted "ticket" that the client could present
later to get the session going again with the same keys as before.
OpenSSL was giving the keys to decrypt these tickets the lifetime of
the SSL contexts, which would have been terrible for PFS if we had
long-lived SSL contexts. Fortunately, we don't. Still, it's pretty
bad. We should also drop these, since our use of the extension stands
out with our non-use of session cacheing.
Found by nextgens. Bugfix on all versions of Tor when built with
openssl 1.0.0 or later. Fixes bug 7139.
Andrea Shepard [Fri, 19 Oct 2012 01:08:35 +0000 (18:08 -0700)]
Factor out common parts of channel_tls_connect() and channel_tls_handle_incoming(); fixes get_remote_addr problem with incoming connections for bug 7112
Nick Mathewson [Tue, 16 Oct 2012 17:41:55 +0000 (13:41 -0400)]
Discard extraneous renegotiation attempts in the v3 link protocol
Failure to do so left us open to a remotely triggerable assertion
failure. Fixes CVE-2012-2249; bugfix on 0.2.3.6-alpha. Reported by
"some guy from France".
This patch is a forward-port to 0.2.4, to work with the new channel
logic.
Nick Mathewson [Tue, 16 Oct 2012 16:55:50 +0000 (12:55 -0400)]
Discard extraneous renegotiation attempts in the v3 link protocol
Failure to do so left us open to a remotely triggerable assertion
failure. Fixes CVE-2012-2249; bugfix on 0.2.3.6-alpha. Reported by
"some guy from France".
Nick Mathewson [Wed, 17 Oct 2012 15:29:59 +0000 (11:29 -0400)]
Fix a bug in channel_dump_statistics
We were calling channel_get_actual_remote_descr() before we used the
output of a previous channel_get_canonical_remote_descr(), thus
invalidating its output.
Nick Mathewson [Wed, 17 Oct 2012 15:23:26 +0000 (11:23 -0400)]
Restore the 'address' value of tunneled connections
When we merged the channel code, we made the 'address' field of linked
directory connections created with begindir (and their associated edge
connections) contain an address:port string, when they should only
have contained the address part.
This patch also tweaks the interface to the get_descr method of
channels so that it takes a set of flags rather than a single flag.
Nick Mathewson [Wed, 17 Oct 2012 15:15:01 +0000 (11:15 -0400)]
Fix for bug 7112 (spewing complaints from tor_addr_is_internal)
In 4768c0efe3e9471cc367c3740d1a4ba0ab79626c (not in any released
version of Tor), we removed a little block of code that set the addr
field of an exit connection used in making a tunneled directory
request. Turns out that wasn't right.
Nick Mathewson [Wed, 17 Oct 2012 13:49:36 +0000 (09:49 -0400)]
Remove changes/bug7129
Our convention is that we use the changelog to note release-to-release
changes; we don't need to add changelog entries for bugs that didn't
appear in any released version of Tor. (By convention, we sometimes
say "this bug does not appear in any released version of Tor" or words
to that effect in the commit message so that when Roger goes to make
sure the changelog is right, he knows not to expect a changelog entry
for that part.)