| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
We intern these in Microdesc, and should be consistent.
|
| | |
|
| | |
|
| |
|
|
| |
torspec!499 is merged.
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
This was simply missing.
|
| | |
|
| |
|
|
| |
This defines ordering of routerstatus items.
|
| | |
|
| |
|
|
|
|
| |
This is a nontrivial type with much weirdness to do with publication
times etc., so let's mark this as incomplete until we have a round
trip test.
|
| |
|
|
|
| |
Prompted by
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3991#note_3413168
|
| |
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
| |
This is not tested yet. It will be tested when we add round-trip
tests for votes.
|
| |
|
|
| |
This doesn't parse the keyword, only the value.
|
| |
|
|
|
|
|
|
|
| |
* Rename it so that it doesn't mention parse2, because we're going to
want to encode too.
* Remove the indirection: rename the one in md.rs to be the name
that's used in `with = `. (Previously, things were more complicated
so the extra layer of indirection was helpful.)
|
| | |
|
| |
|
|
|
|
|
| |
FixedB64 is the right type for these, when they are present.
This abolishes some ad-hoc boilerplate. Sadly we still need a bit of
that for Reasons.
|
| |
|
|
|
|
|
|
| |
Previously, this was't possible because derive-deftly wanted a string.
But now it can take a type, and types can contain macro calls inside
their generics etc.
This makes the code much more local and direct.
|
| |
|
|
| |
This is router *status* not router *descriptor*.
|
| | |
|
| |
|
|
| |
As per #2492.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This stabilises the parse2 and encode impls of consensus tyepe:
* {plain, md}::{Preamble, RouterStatus, RouterStatusIntroItem}
It also un-gates the parse2 and encode impls of some vote types.
* VoteAuthorityEntry - this type has been completed.
* RouterStatusMdDigestsVote - whole type still gated with ns-vote
Re the remaining vote types (vote::*): although each_variety.rs
doesn't have a cfg itself, there is a feature gate in the variety
macrology.
|
| | |
|
| |
|
|
| |
This is going to be used for encoding too.
|
| |
|
|
|
|
|
|
| |
This will let us use it in more places, more sensibly.
Sadly it means a lot of syntactic vinegar at many of the call sites in
the old parser, which has very janky ideas about how errors should
work.
|
| | |
|
| |
|
|
| |
Typos found with codespell
|
| | |
|
| |
|
|
|
|
|
| |
This struct is still a bit odd, and there's a todo saying we may
change it again, but at least now it's now available.
While we're here, rename the variant Tor to CTor.
|
| |
|
|
| |
(It's now done in tor_protover.)
|
| |
|
|
|
|
|
| |
Since we expose the relay_flags module, it makes sense to give this a
shorter name.
(It had a longer name when it was part of the netstatus module.)
|
| |
|
|
| |
The generic parser type is easy enough to name now.
|
| |
|
|
|
|
|
| |
Abolish the constants with the transitional names.
This also abolishes the controversial name `H_S_DIR`, which Rust case
transformation rules generated from `HSDir`.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
We're going to separate RelayFlag from RelayFlags.
We could continue to provide a bunch of constant values for
RelayFlags, for each individual type, but that would involve an ad-hoc
derive, and would still be a bit of an unusual API.
Instead, we're going to make ``RelayFlag` a normal enum.
In this commit, we change everyone to refer to it by its singular
name. Hopefully separating out this bulk change makes both this, and
the core commit, easier to review.
|
| |
|
|
|
|
|
|
| |
Many call sites pass one flag. We're going to have a type-level
distinction between a single flag and a set. But that's annoying at
many of the call sites which want to specify a fixed single flag.
Note that `set_flags` doesn't only set flags. It replaces them.
|
| |
|
|
|
|
|
|
| |
Implement this on DocRelayFlags instead, since that's what it returns.
And change the name to from_item_consensus to highlight its semantic
restriction. (It's not generic over the implied flags, so it can only
do one thing.)
|
| | |
|
| |
|
|
| |
This will have space for unknown flags.
|
| |
|
|
|
| |
Provide a per-variety alias and use it for parsing; no longer impl
ItemValueParseable for RelayFlags.
|
| |
|
|
|
| |
Add underscores so that the spec keywords and the flag constants
correspond (according to `paste`'s case-changing rules).
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Add links to torspec, and other cross-references.
Change heading fof `IgnoredPublicationTimeSp` to `publication` to
match spec and distinguish it from the `published` item in netstatus
docs.
Align several descriptions with the wording from torspec.
Remove a restatement of a fact from the spec, on the `valid_until`
field in `Lifetime`.
|
| | |
|
| | |
|
| | |
|