Commit Graph

16928 Commits

Author SHA1 Message Date
Andrea Shepard
f93f7e331b Ignore advertised bandwidths if we have enough measured bandwidths available 2013-03-18 11:15:21 -07:00
Nick Mathewson
8b4728ebd6 Merge remote-tracking branch 'public/bug8180_023_v2' into maint-0.2.4 2013-03-15 12:38:11 -04:00
Nick Mathewson
686aaa5c4c Upgrade the warn for EntryNodes without UseEntryGuards to an error
fixes bug 8180
2013-03-15 12:34:29 -04:00
Nick Mathewson
0cf327dc78 Merge remote-tracking branch 'public/unused_stuff' into maint-0.2.4 2013-03-15 12:17:23 -04:00
Nick Mathewson
e4d2177d31 Fix some basic socket issues with tor-fw-helper-natpmp on windows
This isn't going to be the last of these issues, but we might as
well take the fixes as we find them.

Patch from Gisle Vanem, fixes bug 7280.
2013-03-15 12:11:38 -04:00
Nick Mathewson
18da1e0cf2 Remove incentives.txt from tor git; putting it into torspec. 2013-03-15 11:25:45 -04:00
David Fifield
a0b92cd800 Fix brackets in tor-fw-helper help output.
Change nesting from [(]) to [()]. Formerly it made it look to me at
first glance that "internal port" was optional.

      [Trivial change; fixes #7767  --nickm]
2013-03-15 11:23:47 -04:00
Nick Mathewson
aa051b7573 Improve asciidoc-helper's suggestion of what to install
Fixes bug #7766.

Patch by David Fifield, revised by Peter Palfrader.
2013-03-15 11:18:25 -04:00
Nick Mathewson
10fb339808 Be explicit that we want not only nacl but nacl-with-a-fast-curve25519
Resolves the user experience part of #8014.
2013-03-15 11:00:43 -04:00
Nick Mathewson
653b09e1ec Make circuit_purpose_to_string handle CIRCUIT_PURPOSE_PATH_BIAS_TESTING 2013-03-14 12:06:03 -04:00
Nick Mathewson
1b28f366b8 Apply ClientDNSRejectInternalAddresses to IPv6 in RESOLVED cells
Fixes bug 8475; bugfix on 0.2.0.7-alpha.
2013-03-14 11:19:08 -04:00
Nick Mathewson
adfc3de833 Log fname:lineno in log messages for #7164
This should help us track down #7164 at last.
2013-03-13 10:42:58 -04:00
Nick Mathewson
b9a8f8c17c Fix the warning about LearnCircuitBuildTimeout && !CircuitBuildTimeout
This is for bug 6304.

Add a changes file too
2013-03-13 09:17:43 -04:00
Nick Mathewson
7543fb61e3 Simplify the logic of circuit_build_times_get_initial_timeout. 2013-03-13 09:11:31 -04:00
Nick Mathewson
16f2e4aa8c Don't warn about not sending a socks reply if we get a write error
If we get a write error on a SOCKS connection, we can't send a
SOCKS reply, now can we?

This bug has been here since 36baf7219, where we added the "hey, I'm
closing an AP connection but I haven't finished the socks
handshake!" message.  It's bug 8427.
2013-03-12 17:36:09 -04:00
Nick Mathewson
2b22c0aeef On END_REASON_EXITPOLICY, mark circuit as unusable for that address.
Also, don't call the exit node 'reject *' unless our decision to pick
that node was based on a non-summarized version of that node's exit
policy.

rransom and arma came up with the ideas for this fix.

Fix for 7582; the summary-related part is a bugfix on 0.2.3.2-alpha.
2013-03-11 23:37:47 -04:00
Nick Mathewson
452cfaacfc Track TLS overhead: diagnostic for bug 7707 2013-03-11 22:06:07 -04:00
Nick Mathewson
805ecb8719 Make control_event_bootstrap_problem always INFO when hibernating
When we're hibernating, the main reqason we can't bootstrap will
always be that we're hibernating: reporting anything else at severity
WARN is pointless.

Fixes part of 7302.
2013-03-11 20:52:20 -04:00
Nick Mathewson
34f07ec862 When hibernating, don't heartbeat about problems.
Fixes part of 7302.
2013-03-11 20:50:02 -04:00
Nick Mathewson
8c211c3cda Fix option names in tor-fw-helper manpage
fix for bug 7768
2013-03-11 17:57:27 -04:00
Nick Mathewson
07e26005a6 Treat a changed IPv6 ORPort like an IPv4 one in retry_all_listeners()
Fix for bug 6026
2013-03-11 17:20:43 -04:00
Nick Mathewson
051b1e8ac4 Look at the right variable when warning about signed size_t.
In 81d69f4c2d (0.2.21-alpha) we added a compile-time check for
a (totally broken) signed size_t.  In 0e597471af (not yet released)
I switched to a better configure-time check, which stored its output
in a different variable.  I didn't change the code which looked at
the output, however.

This bug is not in any released version of Tor, and would not affect
anybody with a working Tor.
2013-03-11 16:29:06 -04:00
Nick Mathewson
2f98bf5c9f Warn at configure time when time_t is unsigned
Inspired by #8042.

As far as I know, OpenVMS is the only place you're likely to hit an
unsigned time_t these days, and Tor's VMS support
is... lacking. Still worth letting people know about it, though.
2013-03-11 15:33:44 -04:00
Nick Mathewson
1eebb56691 Another possible diagnostic for 8031.
This time, I'm checking whether our calculated offset matches our
real offset, in each case, as we go along.  I don't think this is
the bug, but it can't hurt to check.
2013-03-11 14:53:41 -04:00
Nick Mathewson
6905c1f60d Check more error codes when writing microdescriptors.
Possible partial fix, or diagnosis tool, for bug 8031.
2013-03-11 14:51:18 -04:00
Nick Mathewson
d54ccbe9fd Use fds, not stdio, to manage microdescriptor files
This is part of an attempt to mitigate 8031.
2013-03-11 14:37:44 -04:00
Nick Mathewson
ef4db31693 Merge remote-tracking branch 'origin/maint-0.2.3' into maint-0.2.4 2013-03-11 13:32:16 -04:00
Nick Mathewson
c6ca199888 Merge remote-tracking branch 'origin/maint-0.2.2' into maint-0.2.3 2013-03-11 13:32:01 -04:00
Nick Mathewson
fdafe11a25 Give an #error when we want threads and OpenSSL has disabled threads
Fixes ticket 6673.
2013-03-11 13:23:10 -04:00
Nick Mathewson
fca578d9b5 Increase link_proto field to 2 bytes
This should have been 2 bytes all along, since version numbers can
be 16 bits long.  This isn't a live bug, since the call to
is_or_protocol_version_known in channel_tls_process_versions_cell
will reject any version number not in the range 1..4.  Still, let's
fix this before we accidentally start supporting version 256.

Reported pseudonymously. Fixes bug 8062; bugfix on 0.2.0.10-alpha --
specifically, on commit 6fcda529, where during development I
increased the width of a version to 16 bits without changing the
type of link_proto.
2013-03-11 12:34:14 -04:00
Nick Mathewson
b9037521c6 Fix a framing bug when reading versions from a versions cell.
Our ++ should have been += 2.  This means that we'd accept version
numbers even when they started at an odd position.

This bug should be harmless in practice for so long as every version
number we allow begins with a 0 byte, but if we ever have a version
number starting with 1, 2, 3, or 4, there will be trouble here.

Fix for bug 8059, reported pseudonymously. Bugfix on 0.2.0.10-alpha
-- specifically, commit 6fcda529, where during development I
increased the width of a version to 16 bits without changing the
loop step.
2013-03-11 12:29:28 -04:00
Roger Dingledine
0196647970 start part-way through the ssl cert lifetime
also, snap the start time and end time to a day boundary, since most
certs in the wild seem to do this.
2013-03-10 23:38:18 -04:00
Roger Dingledine
edd6f02273 randomize SSLKeyLifetime by default
resolves ticket 8443.
2013-03-10 23:38:18 -04:00
Roger Dingledine
599aeef9bc parameterize SSLKeyLifetime
no actual changes in behavior yet
2013-03-10 23:38:18 -04:00
Nick Mathewson
e270a066a6 Merge remote-tracking branch 'arma/bug6783_big_hammer' into maint-0.2.4 2013-03-10 23:01:58 -04:00
Benjamin Kerensa
8b4195f021 Fix typos in a few log messages 2013-03-10 22:59:19 -04:00
Roger Dingledine
f8960ea22b set DisableV2DirectoryInfo_ off by default
since it's only enableable by authorities, nobody else would be able
to start their tor
2013-03-10 20:40:15 -04:00
Nick Mathewson
926b3d77f1 Tweak bug6783 patch. 2013-03-10 20:31:58 -04:00
Nick Mathewson
e4614d30e5 Add a DisableV2DirectoryInfo_ option to 404 all v2 ns requests
I have no idea whether b0rken clients will DoS the network if the v2
authorities all turn this on or not.  It's experimental. See #6783 for
a description of how to test it more or less safely, and please be
careful!
2013-03-10 20:31:53 -04:00
Nick Mathewson
301faf2813 Merge branch 'bug8447_squashed' into maint-0.2.4 2013-03-10 19:52:43 -04:00
Nick Mathewson
339df5df08 Fix 8447: use %u to format circid_t.
Now that circid_t is 4 bytes long, the default integer promotions will
leave it alone when sizeof(int) == 4, which will leave us formatting an
unsigned as an int.  That's technically undefined behavior.

Fixes bug 8447 on bfffc1f0fc.  Bug not
in any released Tor.
2013-03-10 19:52:06 -04:00
Nick Mathewson
d13b996d83 Fix to test for bug8444 / 6034 2013-03-09 19:56:43 -05:00
Andrea Shepard
8027ebb5fd Better comment for dirserv_query_measured_bw_cache() 2013-03-07 15:59:30 -08:00
Andrea Shepard
b522434834 Use DIGESTMAP_FOREACH_MODIFY in dirserv_expire_measured_bw_cache() for concision 2013-03-07 15:55:01 -08:00
Andrea Shepard
6e978ab829 Add unit test for dirserv measured bandwidth cache 2013-03-07 15:41:22 -08:00
Karsten Loesing
3dde6d5d29 Update to the March 2013 GeoIP database. 2013-03-07 20:58:31 +01:00
Andrea Shepard
302d1dae6c Make sure expiry check in dirserv_expire_measured_bw_cache() works if time_t is unsigned 2013-03-07 05:10:54 -08:00
Andrea Shepard
c7947619df More constness in dirserv.c 2013-03-07 05:05:56 -08:00
Andrea Shepard
75eb79a6aa Make dirserv_cache_measured_bw() use a const measured_bw_line_t * 2013-03-07 03:42:14 -08:00
Andrea Shepard
0efe96cae8 Call dirserv_clear_measured_bw_cache() from dirserv_free_all() 2013-03-05 13:11:43 -08:00