aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-netdoc/src/doc/netstatus/rs.rs
Commit message (Collapse)AuthorAgeFilesLines
* tor-netdoc: Make RouterStatus.port_policy use Intern, not ArcIan Jackson2026-07-271-1/+0
| | | | We intern these in Microdesc, and should be consistent.
* tor-netdoc: Make the str in a SoftwareVersion be Intern (fmt)Ian Jackson2026-07-271-3/+1
|
* tor-netdoc: Make the str in a SoftwareVersion be InternIan Jackson2026-07-271-3/+3
| | | | Rather than converting it to an Arc. This is the new idiom for Intern.
* tor-netdoc: Stabilise votes and encoding of authcerts (formatting)Ian Jackson2026-07-151-2/+1
|
* tor-netdoc: Stabilise votes and encoding of authcertsIan Jackson2026-07-151-2/+1
|
* tor-netdoc: Fix rs.rs cache commentsClara Engler2026-06-241-1/+1
| | | | Removes a blocking comment and replaces it with a TODO DIRAUTH.
* Use Intern<T> (fmt)Clara Engler2026-06-241-1/+3
| | | | No functional change.
* Use Intern<T>Clara Engler2026-06-241-1/+2
| | | | | This commit modifies the codebase to actually return Intern<T> in InternCache<T> and adds calls to .into() accordingly.
* tor-netdoc: rs.rs: tidy importsIan Jackson2026-06-151-2/+3
|
* tor-netdoc: routerstatus entries: Add `stats` item (votes only)Ian Jackson2026-06-151-1/+1
|
* tor-netdoc: routerstatus entries: Add `p` itemIan Jackson2026-06-111-0/+1
|
* tor-netdoc: impl EncodeOrd for RouterStatusIan Jackson2026-06-091-1/+2
| | | | This defines ordering of routerstatus items.
* tor-netdoc: SoftwareVersion: fix Display implIan Jackson2026-06-031-0/+1
| | | | Now it round-trips.
* tor-netdoc: implement encoding for votes' `m` itemsIan Jackson2026-05-281-0/+1
|
* tor-netdoc: derive Ord for RouterStatusMdDigestsVoteIan Jackson2026-05-281-1/+1
| | | | | | | | 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.
* tor-netdoc: Rename RelayWeights to RelayWeightsItemIan Jackson2026-05-271-1/+1
| | | | | Prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/3991#note_3413168
* tor-netdoc: Introduce RelayWeights and use it in RouterStatusIan Jackson2026-05-271-1/+1
| | | | | | | | 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.
* tor-netdoc: Implement encoding for md rs digestIan Jackson2026-05-181-1/+2
| | | | | This is not tested yet. It will be tested when we add round-trip tests for votes.
* tor-netdoc: rs referenced doc digests: Use FixedB64Ian Jackson2026-05-181-0/+1
| | | | | | | 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.
* tor-netdoc: Gate vote-related incomplete code with "incomplete"Ian Jackson2026-04-281-1/+1
| | | | | | | | | | | Change "ns-vote" gates to "incomplete": * `vote` modules, and in the variety macro. (And make a TODO more likely to be found.) Change "parse2" gates to "incomplete": * VoteAuthoritySection
* tor-netdoc: Un-gate RouterStatusMdDigestsVote and SoftwareVersionIan Jackson2026-04-281-1/+0
| | | | | These are complete. Un-gate the RouterStatusMdDigestsVote implementation, and the export of both.
* tor-netdoc: Un-gate "plain-consensus" cargo featureIan Jackson2026-04-281-1/+0
| | | | As per #2492.
* tor-netdoc: Un-gate parse2 and encode loose impls under doc/netstatus (tidy)Ian Jackson2026-04-281-9/+4
|
* tor-netdoc: Un-gate parse2 and encode loose impls under doc/netstatusIan Jackson2026-04-281-6/+3
| | | | | | | | | | | | | | | 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.
* tor-netdoc: parse2/encode derive: Use unquoted attributes at call sitesIan Jackson2026-04-071-1/+1
|
* Fix word duplicate typosTobias Stoeckmann2026-03-151-1/+1
|
* tor-netdoc: Rename Version and expose it as netstatus::SoftwareVersionIan Jackson2026-01-151-5/+5
| | | | | | | 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.
* netdoc: Remove protocol interning.Nick Mathewson2025-12-031-1/+0
| | | | (It's now done in tor_protover.)
* Move intern from tor-netdir to tor-basic-utils and make it pubNick Mathewson2025-12-031-1/+1
|
* tor-netdoc: Rename RelayFlagsParser to relay_flags::ParserIan Jackson2025-11-241-1/+1
| | | | | | | 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.)
* tor-netdoc: relay_flags: Remove two now-not-needed type aliasesIan Jackson2025-11-241-2/+1
| | | | The generic parser type is easy enough to name now.
* RelayFlags: Use the singular RelayFlag for naming individual flagsIan Jackson2025-11-181-1/+1
| | | | | | | | | | | | | | 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.
* tor-netdoc: Introduce DocRelayFlags for relay flags in a network documentIan Jackson2025-11-181-1/+2
| | | | This will have space for unknown flags.
* tor-netdoc: Separate ConsensusRelayFlagsParser and VoteRelayFlagsParserIan Jackson2025-11-181-0/+1
| | | | | Provide a per-variety alias and use it for parsing; no longer impl ItemValueParseable for RelayFlags.
* tor-netdoc: Add a lot of spec cross-references and tidy docsIan Jackson2025-10-151-0/+2
| | | | | | | | | | | | | 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`.
* tor-netdoc: Type for parsing `m` lines in votesIan Jackson2025-10-151-1/+36
|
* tor-netdoc: RouterStatus: Add `publication` argument fieldIan Jackson2025-10-151-1/+1
|
* tor-netdoc: RouterStatus: Split out the `r` item's fieldsIan Jackson2025-10-151-0/+1
| | | | | | | | | This makes the Rust structure closer to the document structure. Arguably, this makes the Rust structure worse. But: I'm really very keen on avoiding handwritten parsing and printing code. And, in the longer term, having this linkage will hopefully apply pressure to avoid further protocol complexity/variation/chaos.
* tor-netdoc: No longer impl Sealed for RouterStatus (fmt)Ian Jackson2025-08-261-1/+1
|
* tor-netdoc: No longer impl Sealed for RouterStatusIan Jackson2025-08-261-1/+1
| | | | | We don't need this since RouterStatus no longer implements any sealed traits.
* tor-netdoc: Fix some visibilitiesIan Jackson2025-08-261-6/+3
|
* tor-netdoc: Apply much rustfmt churnIan Jackson2025-08-261-9/+7
|
* tor-netdoc: Provide some Vote thingsIan Jackson2025-08-261-4/+0
| | | | And export *RouterStatus with the macro, and *Header.
* tor-netdoc: rs: centralise some includesIan Jackson2025-08-261-1/+8
| | | | This will allow them to be shared between each_flavor and each_variety.
* tor-netdoc: Introduce experimental ns-vote featureIan Jackson2025-08-261-0/+3
| | | | | | Now we can start actually having code to do with votes. This feature doesn't actually contain any new API surface yet.
* tor-netdoc: ns variety: Provide for flavour-only itemsIan Jackson2025-08-261-1/+1
|
* tor-netdoc: Combine ConsensusRouterStatus and GenericRouterStatusIan Jackson2025-08-261-1/+1
| | | | Now we only need one type.
* tor-netdoc: Abolish RouterStatus trait in favour of generic methodsIan Jackson2025-08-261-1/+1
| | | | | Our approach to sharing code between md and plain consensuses is now the new "variety" system, not generics.
* tor-netdoc: No longer try to export trait FromRdStringIan Jackson2025-08-261-1/+0
| | | | | This doesn't appear in a tor-netdoc rustdoc build from arti 1.4.6. Shortly, clippy is about to start complaining that it's unreachable pub.
* tor-netdoc: netstatus: Move GenericRouterStatusIan Jackson2025-08-261-148/+2
| | | | | | More code motion. We're going to get rid of this type completely eventually.