| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adjust the family value for the microdesc test to the one
actually found in testdata2/.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the microdesc test EC keys with the new ones from
testdata2/ while also changing the encoding from a byte array to the
base64 value found in the microdesc itself.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the microdesc onion key with the new one from
testdata2.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit removes the assert_eq for mds[6]. The reason for this was
to have a test case with happy families set. However, these values were
manually hacked into the respective file which is not the correct way.
Instead, we will test this in a separate test that will be added later,
as the current testdata2/ is not capable of this. This is an already
reported chutney issue.
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This removes unused imports as well as the read_b64 and to_der helper
functions which are all no longer used.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the dir_auth_cross_cert() test case with the new
constants, replacing the longclaw ones.
The replacement also involves a slight refactoring on the way how we
obtain the encoded and decoded variable, namely because we have the data
in a PEM encoded string now and no longer in separate file, making the
use of read_b64 impossible.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the invalid outer signature test case by copying the
outer signature of the alternative certificate into our test object,
which should obviously render this to a failure.
It also updates the test vectors to the constant ones because it moves
away from longclaw.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the invalid cross-cert test case by copying the
cross-cert from the alternative cert into our test object, resulting in
a failure.
Of course this also updates the other test vectors to use the constants
declared above, as this moves away from longclaw.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the inconsistent fingerprint test case that tests
whether the fingerprint matches with the identity RSA key. For this, we
load the alternative authority cert and move its identity key into the
identity key of the canonical cert.
Of course, this also replaces the other test vectors that are now
required for this change because it moves away from longclaw.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adds a new constant to the parse2 authcert unit tests,
ALTERNATIVE_AUTHCERT_RAW, with the idea being to be different than
AUTHCERT_RAW, which we will utilize in order to mix up cross-cert
objects from one authcert with the one of another one in order to see it
fail.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit updates the "trivial" test cases in the dir_auth_signature
unit tests, namely the ones concerning the outer signature as well as
the timestamp tolerance. A follow-up commit will also update the more
tricky ones, such as the ones testing inconsistent cross-certificates,
etc.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit constifies VALID_SYSTEM_TIME, a timestamp indicating a point
in time at which the certificate is valid. We will need this to test
timestamp validation.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit replaces the longclaw test vectors in dir_auth_cert with the
ones we constified previously and represent the ones found in
testdata2/.
It may look a bit odd that we replaced the file includes for the public
keys but this is because those files should have never existed in
testdata2/ in the first place and were only added by accident, meaning
that the current approach is the correct one.
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit replaces a File::open with the AUTHCERT_RAW constant in the
dir_auth_cert test because that is obviously less error prone.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adds `const AUTHCERT_RAW` which `include_str`'s the actual
raw authcert we will use for parsing test purposes. The reason for that
being that a single include_str! of the same file is obviously better
than multiple ones.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit constifies the authcert test vectors by extracting them from
testdata2/keys/authority_certificate.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adds a to_rsa_id() helper function to the authcert tests in
order to convert a hex-encoded RSA identity to an RsaIdentity. It will
be required later on for converting the test vector values to the inner
representations and this function is helpful here because it avoids us
to do repetitive unwrapping and RsaIdentity::from_hex calls, which
overall increase the length/readability.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adds the pem_to_rsa_pk helper function to the authcert tests
in order to convert a PEM encoded RSA public key to the internal data
structure. It will be required later on in order to convert the test
vector strings to internal representations.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit adds a to_system_time helper function accepting an &str in
the Iso8601TimeSp format and converting it to a SystemTime to the
authcert test cases. It will be required later on in order to
conveniently convert human readable timestamps to the test vectors
expected from parsed data.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
These tests got broken due to the replacement of the testdata.
The changes required to make them work again were trivial, namely to
increase a timestamp by two hours in a consensus, as the new consensus
has a `valid-after 2000-01-01 00:02:20` followed by a fingerprint
replacement for a directory authority because the authority identity
keys were obviously also rotated.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This updates the testdata2 directory with job 1468137 using the
following command:
./testdata2-download \
"https://gitlab.torproject.org/tpo/core/arti/-/jobs/1468137/artifacts/download"
The artifact will expire at one point, so you may not be able to
reproduce it anymore.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit patches so-called at-lines in cached-descriptors.new and
cached-microdescs.new, as ctor adds those annotations manually in order
to store metadata, which renders this to become an invalid network
document.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit embeds the message added in 509145592452a5aeca573af00579233
into the generated README.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
The data resides in `shadow.chutney.data/hosts/host` now and not at the
the top-level anymore. A fix might include to use wildcards, but I feel
this is potentially more error-prone.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This commit removes the use/dependency of relatives path by obtaining
the root path of the repository using a git command. Doing it this way
allows us to avoid things such as `../../..` which is not a good pattern
as it creates a dependency upon the directory structure.
|
| |\ \ \ \ \ \ \ \
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | | |
tor-netdoc: impl NormalItemArgument for IpAddr
See merge request tpo/core/arti!3867
|
| | | |_|_|_|/ / /
| |/| | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
I want this for `dir-source` in authority entries in netstatus docs.
According to the spec that's an "IP address" which ought to include
v6, and indeed the type in Arti right now is IpAddr.
The implication of this is that we don't think that anywhere in the
Tor netdocs has a v4 or v6 address, without port, where the v6 address
in square brackets.
|
| |\ \ \ \ \ \ \ \
| |_|_|_|_|/ / /
|/| | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
arti: Fix arti -h
Closes #2038
See merge request tpo/core/arti!3860
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
- Add regression test
- Update README
|
| | | |/ / / / /
| |/| | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Call `clap_app`'s metadata methods after `augment_subcommands`.
If `about` is set before `augment_subcommands`, the subcommand enums'
doc comment overrides it. Now, all metadata (e.g. about, version) is
set after augmentation for consistency and correct help output.
|
| |\ \ \ \ \ \ \
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Add support for handling CREATE_FAST cells and launching a circuit reactor
See merge request tpo/core/arti!3846
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This reverts commit 9c38daf2d3548feca2ff555f5bd52165add0d20c.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This is needed for the revert in the following commit.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Instead of giving the `CreateRequestHandler` to the channel after it's
constructed, we integrate it into the handshake so that we can give it
to the channel constructor.
The `ChannelType` is no longer part of the `Channel`.
Some of the tests could be cleaned up slightly now that the channel
doesn't need the `ChannelType`, but I don't want to conflict with !3853.
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
We can't pass the request handler during the `Channel` constructor since
it would require conditionally compiled function arguments, which aren't
nice.
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
for handling CREATE* messages on channels.
|
| | | | | | | | | |
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
This better fits with existing code that uses `restricted_msg!` and is a
bit more flexible.
|
| | | | | | | | | |
|
| | | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
I think it was written like this because earlier versions of rust didn't
allow references to temporaries like `&mut rand::rng()` and needed them
to be bound to a variable. But this isn't necessary anymore and so the
comment doesn't make sense.
|