Age | Commit message (Collapse) | Author |
|
Related to #40266
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
This is unfortunately massive but both functionalities were extremely
intertwined and it would have required us to actually change the HSv2 code in
order to be able to split this into multiple commits.
After this commit, there are still artefacts of v2 in the code but there is no
more support for service, intro point and HSDir.
The v2 support for rendezvous circuit is still available since that code is
the same for the v3 and we will leave it in so if a client is able to
rendezvous on v2 then it can still transfer traffic. Once the entire network
has moved away from v2, we can remove v2 rendezvous point support.
Related to #40266
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Related to #40063
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Related to #40063
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
Tor has a feature to preserve unrecognized state file entries in
order to maintain forward compatibility. But this feature, along
with some unused code that we never actually removed, led to us
keeping items that were of no use to the user, other than at worst
to preserve ancient information about them.
This commit adds a feature to remove obsolete entries when we load
the file.
Closes ticket 40137.
|
|
[This is a squashed patch for ticket 7193, based on taking a "git
diff" for the original branch, then applying it with "git apply
-3". I earlier attempted to squash the branch with "git rebase",
but there were too many conflicts. --nickm]
|
|
This is experimental and probably will break some platforms
|
|
|
|
|
|
First, we introduce a flag to teach src/test/test to split its work
into chunks. Then we replace our invocation of src/test/test in our
"make check" target with a set of 8 scripts that invoke the first
8th of the tests, the second 8th, and so on.
This change makes our "make -kj4 check" target in our hardened
gitlab build more than twice as fast, since src/test/test was taking
the longest to finish.
Closes 40098.
|
|
Tests %include with files and folders, modifying and reloading
the config file with sandbox enabled and reponse of SAVECONF and
getinfo config-can-saveconf control commmands.
|
|
Also adds generic tor_glob function to expand globs.
|
|
No probes at this point. They are per subsystem and thus in later commits.
Part of #32910
|
|
|
|
|
|
In "make test-network", add tests for single onion services v2 and v3.
In "make test-network-all", test onion services v2 and v3 in the same
network.
Part of 33334.
|
|
This network is used in make test-network-all and test-network-ipv6.
Closes 33334.
|
|
This network is used in make test-network-all and test-network-ipv4.
Part of 33334.
|
|
Use bridges+hs-v23 for "make test-network",
rather than using chutney's old default.
This change requires a recent version of chutney,
because the old bridges+hs-v23 did not work.
(See chutney's 33302 for details.)
Closes 28208.
|
|
The IPv6 test only runs if IPv6 is available.
Also, explicitly use the bridges+hs-v2 network for the IPv4-only test.
This network was chutney's default as of January 2020.
Closes 33300.
|
|
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
|
|
|
|
Some of these helpers will be needed in multiple places in the unit
tests, so we should move them now.
|
|
|
|
|
|
|
|
Part of 32213.
|
|
At this commit, 93.9% of line coverage and 95.5% of function coverage.
Closes #32196
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Fake circuits are created everywhere in the unit tests. This is an attempt at
centralizing a "fake circuit creation" API like fakechans.c does for channel.
This commit introduces fakecircs.c and changes test_relay.c and
test_circpadding.c which were using roughly the same code.
This will allow easier OR circuit creation for the future tests in
test_circuitmux.c
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
Based on examination of our tests, this mock function accepts
"localhost" and "torproject.org", and rejects everything else.
|
|
|
|
|
|
This script takes a set of example torrcs and command-lines from
src/test/conf_examples. If a success is expected, it runs "tor
--dump-config" and compares the result with the one we expect. If a
failure is expected, it runs "tor --verify-config" and greps for the
error we expect.
|
|
|
|
(This option tests our existing behavior, not necessarily the most
sensible behavior.)
|
|
|
|
This test case, at this point, only constructs the confmgr object.
More code to come.
|
|
|
|
Currently test the only available function which is hs_dos_can_send_intro2()
within the HS anti-DoS subsystem.
Closes #15516
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
This makes all of the practracker tests get run by make check, and
hence by our CI.
Closes ticket 31304.
|
|
This set of tests gets the line coverage to 100%.
|
|
Closes #30687.
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Because it invokes the Tor mainloop, it does unpredictable things to
test coverage of a lot of code that it doesn't actually test at
all. (It is more an integration test than anything else.)
|
|
|
|
|
|
This mechanism isn't perfect, and sometimes it will guess wrong,
but it will help our automation.
|