| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
Done using:
```
for crate in $(./maint/list-crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.43.0
done
```
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
Just rustfmt.
|
| |
|
|
|
|
|
|
|
| |
This commit changes the tpye of `RouterDesc::identity_ed25519` to be of
EmbeddedCert.
Using the inner keys as the verified values is fine because the legacy
parser continues to verify the legacy cert, as it extracts its timestamp
and signature to the Vec it verifies in the end.
|
| |
|
|
| |
Just rustfmt.
|
| |
|
|
|
|
|
|
|
| |
This commit modifies the legacy parser code in an ugly way to also
return a copy of the KeyUnknown certificate, which will be required for
an EmbeddedCert<> construction.
This is not nice but unavoidable in a setup that makes use of the
self-consuming tor_cert certificate chain, like the legacy parser code.
|
| | |
|
| |
|
|
|
| |
The new encoding impls are feature = "incomplete" so don't need to be
here.
|
| | |
|
| |
|
|
|
| |
We will test this when we test round trip parsing/encoding of votes.
For now, mark it as incomplete.
|
| |
|
|
|
|
|
|
| |
Sorting by the applicable consensus methods set seems reasonable.
The spec doesn't state the order for this. I think that's fine.
We can't expect to repro the same consensus with different software,
and we will produce stable output.
|
| |
|
|
| |
The upshot is that we will sort digests by alg name.
|
| | |
|
| |
|
|
|
|
|
|
| |
When we are generating documents that need to be stable, we need to
generate the same document regardless of what subset of digest names
we understand.
So order DigestName by its string representation.
|
| | |
|
| |
|
|
| |
No functional change.
|
| |
|
|
|
| |
Removes a comment about the virtual/real distinguishment in RouterDesc
as there are no virtual items left anymore.
|
| |
|
|
|
|
|
| |
This item is no longer required because we can extract it from
family_cert.
Unfortunately it requires a breaking change to the getter.
|
| |
|
|
| |
We will need it in the next commit.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This commit adds the family_cert field to RouterDesc using EmbeddedCert
logic.
Unfortunately, it requires some code gymnastics similar to the (not yet
merged) identity-ed25519 certificates, which we also outlined in a
comment of a previous commit in the branch. Long story short: The
legacy parser and parse2 do not like to co-exist in the same scope due
to the self-consuming tor-cert verification chain of which the legacy
parser makes heavy use.
|
| |
|
|
|
|
| |
This commit modifies the legacy happy families extractor to also return
KeyUnknownCert while adding a comment explaining on why this will be
required.
|
| |
|
|
|
|
|
|
|
| |
This commit splits the inner .map() function of the happy families
extractor in the legacy parser.
In the next commit, we will return both of these variables separately,
but for now this change has no functional change and only looks
redundant.
|
| |
|
|
|
| |
We will change the type in the next commit and this will make auditing
the next commits easier.
|
| |\
| |
| |
| |
| | |
tor-netdoc: encoding support for `w` line in routerstatus
See merge request tpo/core/arti!3991
|
| | | |
|
| | |
| |
| |
| |
| | |
Prompted by
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3991#note_3413169
|
| | |
| |
| |
| |
| | |
Prompted by
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3991#note_3413168
|
| | | |
|
| | | |
|
| | |
| |
| |
| | |
In the form of trait impls.
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| | |
For encoding, we need to represent the raw parameters.
This change is carefully arranged so that when the retain unknown feature is
disabled (ie, in clients), the per-router data structure remains the
same.
|
| | |
| |
| |
| | |
Minor change which will make the next diff clearer.
|
| | |
| |
| |
| |
| | |
This makes the error handling a bit more regular. It will also make
the code suit our further parsing changes better.
|
| | |
| |
| |
| |
| | |
Convert the from_net_params constructor into a TryFrom. Retain the
bespoke method for the benefit of the old parser.
|
| | | |
|
| | |
| |
| |
| |
| | |
Not just NetParams<i32>. We're going to want it for NetParams<u32> in
a moment.
|
| | | |
|
| | |
| |
| |
| | |
Call the existing string encoding code.
|
| | |
| |
| |
| |
| | |
This seems trivial enough I don't feel the need to mark it
"incomplete" even though there is no test case.
|
| | | |
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit changes the data type of RouterDesc::or_address from
Option<(net::IPv6Addr, u16)> to Vec<net::SocketAddr>.
This is the correct behavior according to the spec, meaning I will not
give a lengthy explanation on why this is better.
Reviewers might now be questioning whether the spec is wrong and/or if
this is a dangerous change, as Arti used to only extract the first IPv6
address and CTor doing a similar thing.
Following an IRC discussion with nickm@, we came to the conclusion that
both implementation techniques are right. It is okay for the document
to hold multiple addresses, it is okay for the implementation to ignore
all but the first (IPv6 address). What is not okay however, is for an
implementation to reject documents with multiple addresses.
Besides, router descriptors are not used in the existing code for
selecting the address of a relay, meaning this change has very little
practical meaning.
|
| |
|
|
| |
I unwrapped this for conflict resolution.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As pointed out in
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3985#note_3413185
this was a duplicate.
The new NoFurtherArguments
* Implements encoding
* Implements more traits
* Is in the right module (types::misc - it's not just for parsing)
* Has a slightly better name
* Had an open-coded parsing impl (which we now replace)
* Had minor differences to docs (so we add a line to NoFurtherArguments)
|
| |
|
|
|
| |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3985#note_3413184
|
| |
|
|
|
| |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3985#note_3413183
|
| |
|
|
|
|
|
|
| |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3985#note_3413182
I left the word "fixed" in some of the docs and error messages, where
it seemed to make sense.
|
| | |
|