Commit Graph

8292 Commits

Author SHA1 Message Date
Nick Mathewson fbacbf9fd9 Set OpenSSL 0.9.8l renegotiation flag early enough for bufferevents
This seems to fix another case of bug2001.
2010-10-12 14:52:33 -04:00
Nick Mathewson a9172c87be Actually call connection_tls_finish_handshake() with bufferevents
First start of a fix for bug2001, but my test network still isn't
working: the client and the server send each other VERSIONS cells,
but never notice that they got them.
2010-10-12 14:52:33 -04:00
Steven Murdoch 06eafb3fcc Fix running unit tests from outside of the build directory (fixes bug #2051)
Currently the unit tests test_util_spawn_background_* assume that they
are run from the Tor build directory. This is not the case when running
make distcheck, so the test will fail. This problem is fixed by autoconf
setting BUILDDIR to be the root of the Tor build directory, and this
preprocessor variable being used to specify the absolute path to
test-child. Also, in test-child, do not print out argv[0] because this will
no longer be predictable. Found by Sebastian Hahn.
2010-10-11 23:29:52 +01:00
Nick Mathewson 8ecb5abbe1 Add header for tor_tls_log_one_error 2010-10-11 13:26:57 -04:00
Nick Mathewson 4cfa6fbaca Log OpenSSL errors coming from bufferevent_openssl 2010-10-11 13:25:41 -04:00
Nick Mathewson 544a8afe5a Merge remote branch 'sjmurdoch/bug1903' 2010-10-11 11:01:15 -04:00
Steven Murdoch f7338d3baa Skip running fgets_eagain test until we fix it 2010-10-11 15:56:14 +01:00
Nick Mathewson 8f76f31761 Make tor_sscanf handle %x 2010-10-11 10:50:47 -04:00
Steven Murdoch 8a12ce2cf9 Add a unit test for tor_spawn_background
- Test sucessfully starting a process
- Test failing to find the executable
2010-10-10 19:08:44 +01:00
Steven Murdoch 68e576e9f9 Update documentation for tor_spawn_background
- Include description of stdout_read, stderr_read, and argv
2010-10-10 19:08:44 +01:00
Steven Murdoch 8ee559bd63 Add a unit test for fgets (currently fails)
- For a non-blocking pipe, check that on EAGAIN fgets returns NULL
  rather than a partial line
2010-10-10 19:08:44 +01:00
Steven Murdoch 23e9f362a2 Fix issues in nickm's review of log_from_pipe for bug #1903
- Replace sscanf with tor_sscanf
- Replace use of strstr with equivalent call to strcmpstart
2010-10-10 19:08:44 +01:00
Steven Murdoch 4d694c7890 Fix nickm's comments on logging for bug #1903
- Use log_warn rather than log_err for bad but survivable events
2010-10-10 19:08:44 +01:00
Steven Murdoch 708ba8899f Note icky constructs mentioned in bug #1903
- To be dealt with as part of bug #2029
2010-10-10 19:07:40 +01:00
Nick Mathewson 9fe3cd0be3 Fix a crash bug when serving microdescs on a bufferevent. 2010-10-07 21:02:12 -04:00
Nick Mathewson d0f1f9ce9e Remove a spurious .z from microdesc fetch URLs so they no logner end with .z.z 2010-10-07 20:41:15 -04:00
Nick Mathewson 5bab9fe79e Actually add test_microdesc.c file. 2010-10-07 16:27:01 -04:00
Nick Mathewson 1dffefc907 Add more documentation to microdesc.c, plus another assert. 2010-10-07 16:25:27 -04:00
Nick Mathewson ab5b11fbb8 Add a more verbose log message to try to catch bug #2022. 2010-10-07 16:04:24 -04:00
Nick Mathewson 3061a036c8 Unit tests for microdescriptor cache
May help with tracking down bug #2022
2010-10-07 15:28:54 -04:00
Nick Mathewson 4c71be65d8 Merge remote branch 'origin/maint-0.2.2' 2010-10-04 13:56:17 -04:00
Robert Ransom 1b8c8059c7 Correct a bogus comment.
Whether or not OpenSSL reference-counts SSL_CTX objects is irrelevant;
what matters is that Tor reference-counts its wrapper objects for
SSL_CTXs.
2010-10-04 13:53:54 -04:00
Robert Ransom c70d9d77ab Correct a couple of log messages in tortls.c 2010-10-04 13:53:48 -04:00
Robert Ransom 068185eca2 Fix several comments in tortls.c 2010-10-04 13:47:57 -04:00
Nick Mathewson 3e5ada6a29 Merge remote branch 'origin/maint-0.2.2' 2010-10-04 12:32:52 -04:00
Nick Mathewson 69b4138c00 Merge remote branch 'origin/maint-0.2.1' into maint-0.2.2 2010-10-04 12:32:35 -04:00
Steven Murdoch 5a77c64834 Fix issues in nickm's review of format_helper_exit_status for bug #1903
- Responsibility of clearing hex_errno is no longer with caller
- More conservative bounds checking
- Length requirement of hex_errno documented
- Output format documented
2010-10-04 14:31:27 +01:00
Karsten Loesing bad609ae6b Update to the October 1 2010 Maxmind GeoLite Country database. 2010-10-04 11:45:53 +02:00
Nick Mathewson 80b515b85f Initialize fd values in tor_port_check_forwarding to -1 2010-10-01 18:14:17 -04:00
Roger Dingledine 165aaf560a Merge branch 'maint-0.2.2' 2010-10-01 14:12:11 -04:00
Roger Dingledine 734ba2f937 fix comment 2010-10-01 14:11:08 -04:00
Roger Dingledine 6cb5383e56 log when we guess our ip address, not just when we fail 2010-10-01 13:32:38 -04:00
Roger Dingledine 6e00877fa3 bump to 0.2.2.17-alpha-dev 2010-10-01 04:59:11 -04:00
Roger Dingledine a3f488a887 bump to 0.2.2.17-alpha 2010-09-30 17:49:11 -04:00
Nick Mathewson 495e630a49 Merge branch 'tor-fw-squashed2'
Conflicts:
	src/common/util.c
2010-09-30 16:22:39 -04:00
Nick Mathewson 0e9d969bb2 Fix space and formatting issues 2010-09-30 15:55:42 -04:00
Nick Mathewson d39e46c26d Merge remote branch 'origin/maint-0.2.2' 2010-09-30 15:30:14 -04:00
Nick Mathewson 2835dcf69f #if-out the fw-helper code in util.c when building on windows 2010-09-30 12:58:48 -04:00
Nick Mathewson 1779fee27a Turn select() usage in tor-fw-helper into a function. 2010-09-30 12:18:21 -04:00
Steven Murdoch a6dc00fa75 Start tor-fw-helper in the background, and log whatever it outputs 2010-09-30 11:40:37 -04:00
Jacob Appelbaum 3eaa9a376c Changes to tor-fw-helper, some based on Nick's review
* MINIUPNPC rather than the generic UPNP
 * Nick suggested a better abstraction model for tor-fw-helper
 * Fix autoconf to build with either natpmp or miniupnpc
 * Add AM_PROG_CC_C_O to fix automake complaint
 * update spec to address nickm's concern
 * refactor nat-pmp to match upnp state
 * we prefer tor_snprintf to snprintf
 * link properlty for tor_snprintf
 * rename test_commandline_options to log_commandline_options
 * cast this uint as an int
 * detect possible FD_SETSIZE errors
 * make note about future enhancements for natpmp
 * add upnp enhancement note
 * ChangeLog entry
 * doxygen and check-spaces cleanup
 * create tor-fw-helper.1.txt
2010-09-30 11:39:34 -04:00
Jacob Appelbaum 9cc76cf005 First implementation of tor-fw-helper.
tor-fw-helper is a command-line tool to wrap and abstract various
firewall port-forwarding tools.

This commit matches the state of Jacob's tor-fw-helper branch as of
23 September 2010.

  (commit msg by Nick)
2010-09-30 11:37:53 -04:00
Nick Mathewson 3ad43ef75f Whitespace fixes on recent merges to master. 2010-09-30 01:36:36 -04:00
Sebastian Hahn 0702429cf7 Note an XXX about potential overflow 2010-09-30 06:24:01 +02:00
Sebastian Hahn 73def430e3 Use an upper and lower bound for bridge weights
When picking bridges (or other nodes without a consensus entry (and
thus no bandwidth weights)) we shouldn't just trust the node's
descriptor. So far we believed anything between 0 and 10MB/s, where 0
would mean that a node doesn't get any use from use unless it is our
only one, and 10MB/s would be a quite siginficant weight. To make this
situation better, we now believe weights in the range from 20kB/s to
100kB/s. This should allow new bridges to get use more quickly, and
means that it will be harder for bridges to see almost all our traffic.
2010-09-30 06:17:54 +02:00
Sebastian Hahn 45c51e3238 Fix check-spaces 2010-09-30 06:17:32 +02:00
Roger Dingledine ea6ac0f0d1 Merge branch 'maint-0.2.2' 2010-09-30 00:10:14 -04:00
Roger Dingledine d17fcad3ae Merge commit 'mikeperry/bug1772' into maint-0.2.2 2010-09-30 00:00:06 -04:00
Mike Perry 7eedd0f6bc Nominaly lower the minimum timeout value to 1500.
This won't change any behavior, since it will still be rounded back
up to 2seconds, but should reduce the chances of some extra warns.
2010-09-29 20:58:09 -07:00
Roger Dingledine 3cbe463e96 Merge branch 'bug1772' into maint-0.2.2 2010-09-29 23:52:18 -04:00