Age | Commit message (Collapse) | Author | |
---|---|---|---|
2019-03-08 | Merge remote-tracking branch 'bug28525_029' into maint-0.3.5 | teor | |
2019-03-08 | Make tor_addr_is_internal_() RFC6598 (Carrier Grade NAT) aware | Neel Chauhan | |
Fixes 28525. | |||
2019-01-16 | Bump copyright date to 2019. | Nick Mathewson | |
2018-07-10 | Isolate resolve.h usage in the modules that really need it. | Nick Mathewson | |
(Almost none of Tor should actually need to touch the platform resolver.) | |||
2018-07-10 | Remove all users of addr_port_lookup outside of address.c | Nick Mathewson | |
This function has a nasty API, since whether or not it invokes the resolver depends on whether one of its arguments is NULL. That's a good way for accidents to happen. This patch incidentally makes tor-resolve support socks hosts on IPv6. | |||
2018-07-05 | Fix every include path changed in the previous commit (automated) | Nick Mathewson | |
I am very glad to have written this script. | |||
2018-07-01 | Remove system headers from or.h | Nick Mathewson | |
2018-06-21 | Rectify include paths (automated) | Nick Mathewson | |
2018-06-20 | Run rectify_include_paths.py | Nick Mathewson | |
2018-06-20 | Update copyrights to 2018. | Nick Mathewson | |
2018-05-08 | Fix compilation of test_addr.c | Nick Mathewson | |
This needs to include crypto_rand.h (which it didn't before it was merged). | |||
2018-05-08 | More unit tests for addressmap_get_virtual_address(). | Nick Mathewson | |
Previously the coverage on this function was mostly accidental, coming as it did from test_entryconn.c. These new tests use mocking to ensure that we actually hit the different failure and retry cases of addressmap_get_virtual_address(), and make our test coverage a bit more deterministic. Closes ticket 25993. | |||
2017-09-15 | Merge branch 'scan-build-032' | Nick Mathewson | |
2017-09-15 | Run our #else/#endif annotator on our source code. | Nick Mathewson | |
2017-09-12 | Clear up dead-assignment warnings from scan-build | Nick Mathewson | |
2017-08-24 | apply ahf's test_assert_int.cocci | Nick Mathewson | |
2017-07-05 | Merge branch 'maint-0.3.0' into maint-0.3.1 | Nick Mathewson | |
2017-07-05 | Merge branch 'maint-0.2.8' into maint-0.2.9 | Nick Mathewson | |
2017-07-05 | Merge branch 'maint-0.2.7-redux' into maint-0.2.8 | Nick Mathewson | |
2017-07-05 | Merge branch 'maint-0.2.5' into maint-0.2.6 | Nick Mathewson | |
2017-07-05 | Merge branch 'maint-0.2.4' into maint-0.2.5 | Nick Mathewson | |
2017-07-03 | Fix assertion failure related to openbsd strtol(). | Nick Mathewson | |
Fixes bug 22789; bugfix on 0.2.3.8-alpha. | |||
2017-05-26 | Mock tor_addr_lookup() during part of addr/basic test. | Nick Mathewson | |
If this function isn't mocked, then our unit tests break on stupid networks where localhost is broken or absent. Fixes bug 6298; bugfix on 0.0.9pre2. | |||
2017-03-15 | Run the copyright update script. | Nick Mathewson | |
2016-10-11 | Fix a bug in displaying IPv6 addrs in test_op_ipv6_ with --verbose | Nick Mathewson | |
The test code, if it failed, or if it was run in verbose mode, would use the wrong variable for its loop. Patch from rubiate uploaded to 19999. | |||
2016-09-06 | checkSpace.pl now forbids more identifiers. | Nick Mathewson | |
The functions it warns about are: assert, memcmp, strcat, strcpy, sprintf, malloc, free, realloc, strdup, strndup, calloc. Also, fix a few lingering instances of these in the code. Use other conventions to indicate _intended_ use of assert and malloc/realloc/etc. | |||
2016-07-28 | Fix all -Wshadow warnings on Linux | Nick Mathewson | |
This is a partial fix for 18902. | |||
2016-02-27 | Update the copyright year. | Nick Mathewson | |
2016-01-03 | Test another codepath in inet_ntop | Nick Mathewson | |
2015-01-02 | Bump copyright dates to 2015, in case someday this matters. | Nick Mathewson | |
2014-11-12 | Merge remote-tracking branch 'public/bug7484' | Nick Mathewson | |
Conflicts: src/test/test_addr.c | |||
2014-11-12 | Fix wide lines (from 13172) | Nick Mathewson | |
2014-11-12 | Replace operators used as macro arguments with OP_XX macros | Nick Mathewson | |
Part of fix for 13172 | |||
2014-10-28 | Add another year to our copyright dates. | Nick Mathewson | |
Because in 95 years, we or our successors will surely care about enforcing the BSD license terms on this code. Right? | |||
2014-09-16 | clean up eol whitespace from coccinelle-generated patches | Nick Mathewson | |
2014-09-16 | Remove the legacy_test_helper and legacy_setup wrappers | Nick Mathewson | |
These wrappers went into place when the default type for our unit test functions changed from "void fn(void)" to "void fn(void *arg)". To generate this patch, I did the same hokey-pokey as before with replacing all operators used as macro arguments, then I ran a coccinelle script, then I ran perl script to fix up everything that used legacy_test_helper, then I manually removed the legacy_test_helper functions, then I ran a final perl script to put the operators back how they were. ============================== #!/usr/bin/perl -w -i -p s/==,/_X_EQ_,/g; s/!=,/_X_NE_,/g; s/<,/_X_LT_,/g; s/>,/_X_GT_,/g; s/>=,/_X_GEQ_,/g; s/<=,/_X_LEQ_,/g; -------------------- @@ identifier func =~ "test_.*$"; statement S, S2; @@ static void func ( -void +void *arg ) { ... when != S2 +(void) arg; S ... } -------------------- #!/usr/bin/perl -w -i -p s/, *legacy_test_helper, *([^,]+), *\&legacy_setup, *([^\}]+) *}/, $2, $1, NULL, NULL }/g; -------------------- #!/usr/bin/perl -w -i -p s/_X_NEQ_/!=/g; s/_X_NE_/!=/g; s/_X_EQ_/==/g; s/_X_GT_/>/g; s/_X_LT_/</g; s/_X_GEQ_/>=/g; s/_X_LEQ_/<=/g; -------------------- | |||
2014-09-15 | Replace all uses of test_{str,}eq | Nick Mathewson | |
2014-09-15 | Replace the remaining test_assert instances | Nick Mathewson | |
2014-09-15 | Make not even macros use test_fail_msg. | Nick Mathewson | |
2014-09-15 | Use coccinelle scripts to clean up our unit tests | Nick Mathewson | |
This should get rid of most of the users of the old test_* functions. Some are in macros and will need manual cleanup, though. This patch is for 13119, and was automatically generated with these scripts. The perl scripts are there because coccinelle hates operators as macro arguments. ------------------------------ s/==,/_X_EQ_,/g; s/!=,/_X_NE_,/g; s/<,/_X_LT_,/g; s/>,/_X_GT_,/g; s/>=,/_X_GEQ_,/g; s/<=,/_X_LEQ_,/g; ------------------------------ @@ expression a; identifier func; @@ func (...) { <... -test_fail_msg +TT_DIE ( +( a +) ) ...> } @@ identifier func; @@ func (...) { <... -test_fail() +TT_DIE(("Assertion failed.")) ...> } @@ expression a; identifier func; @@ func (...) { <... -test_assert +tt_assert (a) ...> } @@ expression a, b; identifier func; @@ func (...) { <... -test_eq +tt_int_op (a, +_X_EQ_, b) ...> } @@ expression a, b; identifier func; @@ func (...) { <... -test_neq +tt_int_op (a, +_X_NEQ_, b) ...> } @@ expression a, b; identifier func; @@ func (...) { <... -test_streq +tt_str_op (a, +_X_EQ_, b) ...> } @@ expression a, b; identifier func; @@ func (...) { <... -test_strneq +tt_str_op (a, +_X_NEQ_, b) ...> } @@ expression a, b; identifier func; @@ func (...) { <... -test_eq_ptr +tt_ptr_op (a, +_X_EQ_, b) ...> } @@ expression a, b; identifier func; @@ func() { <... -test_neq_ptr +tt_ptr_op (a, +_X_NEQ_, b) ...> } @@ expression a, b, len; identifier func; @@ func (...) { <... -test_memeq +tt_mem_op (a, +_X_EQ_, b, len) ...> } @@ expression a, b, len; identifier func; @@ func (...) { <... -test_memneq +tt_mem_op (a, +_X_NEQ_, b, len) ...> } ------------------------------ @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a == b +a, _X_EQ_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a == b +a, _X_EQ_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a == b +a, _X_EQ_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a == b +a, _X_EQ_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a == b +a, _X_EQ_, b ) ...> } @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a != b +a, _X_NEQ_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a != b +a, _X_NEQ_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a != b +a, _X_NEQ_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a != b +a, _X_NEQ_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a != b +a, _X_NEQ_, b ) ...> } @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a >= b +a, _X_GEQ_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a >= b +a, _X_GEQ_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a >= b +a, _X_GEQ_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a >= b +a, _X_GEQ_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a >= b +a, _X_GEQ_, b ) ...> } @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a <= b +a, _X_LEQ_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a <= b +a, _X_LEQ_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a <= b +a, _X_LEQ_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a <= b +a, _X_LEQ_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a <= b +a, _X_LEQ_, b ) ...> } @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a > b +a, _X_GT_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a > b +a, _X_GT_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a > b +a, _X_GT_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a > b +a, _X_GT_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a > b +a, _X_GT_, b ) ...> } @@ char a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a < b +a, _X_LT_, b ) ...> } @@ int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a < b +a, _X_LT_, b ) ...> } @@ long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_int_op ( -a < b +a, _X_LT_, b ) ...> } @@ unsigned int a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a < b +a, _X_LT_, b ) ...> } @@ unsigned long a, b; identifier func; @@ func (...) { <... -tt_assert +tt_uint_op ( -a < b +a, _X_LT_, b ) ...> } ------------------------------ s/_X_NEQ_/!=/g; s/_X_NE_/!=/g; s/_X_EQ_/==/g; s/_X_GT_/>/g; s/_X_LT_/</g; s/_X_GEQ_/>=/g; s/_X_LEQ_/<=/g; s/test_mem_op\(/tt_mem_op\(/g; | |||
2014-04-19 | scan-build: avoid undef behaior in tor_inet_pton | Nick Mathewson | |
If we had an address of the form "1.2.3.4" and we tried to pass it to tor_inet_pton with AF_INET6, it was possible for our 'eow' pointer to briefly move backwards to the point before the start of the string, before we moved it right back to the start of the string. C doesn't allow that, and though we haven't yet hit a compiler that decided to nuke us in response, it's best to fix. So, be more explicit about requiring there to be a : before any IPv4 address part of the IPv6 address. We would have rejected addresses without a : for not being IPv6 later on anyway. | |||
2014-04-07 | Fix some harmless/untriggerable memory leaks found by coverity | Nick Mathewson | |
2014-04-05 | Merge remote-tracking branch 'public/bug10801_024' | Nick Mathewson | |
Conflicts: src/common/address.c src/or/config.c | |||
2014-04-05 | Make tor_addr_port_parse handle portless IPv6 addresses correctly. | Nick Mathewson | |
(Not a bugfix on any Tor release; before 10801_024, it didn't handle portless addresses at all.) | |||
2014-04-05 | Add a test for default/port conflicts in tor_addr_port_parse | Nick Mathewson | |
2014-04-01 | Merge remote-tracking branch 'public/bug4645' | Nick Mathewson | |
Conflicts: src/or/dirserv.c | |||
2014-03-27 | Don't do a DNS lookup on a bridge line address | Nick Mathewson | |
Fixes bug 10801; bugfix on 07bf274d in 0.2.0.1-alpha. | |||
2014-03-03 | Fix compilation warnings in tor_addr_make_null patch | Nick Mathewson | |
There was one "missing prototype" warning because the test function wasn't static, and one "unused parameter" warning about the "data" parameter. Also, I added a couple of tests to make sure that the "make_null" addresses really were the addresses we expected, by formatting them as strings. | |||
2014-03-03 | add test for tor_addr_make_null | Kevin Murray | |
Signed-off-by: Kevin Murray <spam@kdmurray.id.au> | |||
2014-02-12 | Disallow "*/maskbits" as an address pattern. | Nick Mathewson | |
Fixes bug 7484. We've had this bug back in a8eaa79e031ee04d44 in 0.0.2pre14, when we first started allowing address masks. |