summaryrefslogtreecommitdiff
path: root/crates
Commit message (Collapse)AuthorAgeFilesLines
...
* | Add unknown-lints exception to examplesNick Mathewson2024-03-137-1/+7
| | | | | | | | | | We need this to avoid warnings when runnning non-nightly clippy on these examples.
* | Run maint/add_warning.Nick Mathewson2024-03-13235-0/+235
|/
* Merge branch 'prop340-decoding-api' into 'main'Nick Mathewson2024-03-1314-94/+364
|\ | | | | | | | | relay_cell: Update decoding API to support prop340 format See merge request tpo/core/arti!2034
| * Remove RelayMsgOuter::decode_from_readerJim Newsome2024-03-121-11/+3
| | | | | | | | | | | | The semantics of such a function that supports both the legacy V0 format and the V1 packing and fragmentation format are a bit tricky. Since it's not used outside of its module, we can simply remove it.
| * relay-cell: Update relay cell decoding API for prop340Jim Newsome2024-03-128-56/+337
| | | | | | | | | | | | | | | | | | | | | | Prop 340: https://spec.torproject.org/proposals/340-packed-and-fragmented.html This updates the decoding API to support multiple versions of the relay cell encoding, including the new encoding proposed in prop340 that supports relay message packing and fragmentation. This commit doesn't actually add support for that new encoding yet.
| * Rename UnparsedRelayCell -> UnparsedRelayMsgJim Newsome2024-03-1212-48/+45
| | | | | | | | | | For consistency with the terminology proposed in https://gitlab.torproject.org/tpo/core/torspec/-/issues/253
* | Fix some rustdoc warnings.Nick Mathewson2024-03-127-13/+14
|/ | | | | These are mostly about explicitly linking to things that were already in scope.
* tor-relay-selection: Use partition() in testing code.Nick Mathewson2024-03-121-9/+3
|
* Rename and clarify result_is_relaxed.Nick Mathewson2024-03-121-5/+5
|
* Refactor RelaySelector to make its invariants less subtle.Nick Mathewson2024-03-121-48/+61
|
* Add a comment about future extensions to RestrictionInner.Nick Mathewson2024-03-121-0/+6
|
* tor-relay-selector: Clarify "flexible" vs "relaxed" a little.Nick Mathewson2024-03-122-3/+4
|
* Annotate usage of low_level_predicate_permits_relayNick Mathewson2024-03-122-1/+15
|
* relay-selection: Remove the extension traits for Relay and NetDirNick Mathewson2024-03-122-64/+0
| | | | | | I thought we would need these, but after the latest refactoring they turned out not to have any users, and one of them had only deprecated methods. Best just to drop them.
* Rename the RelayPredicate trait to discourage its being used directly.Nick Mathewson2024-03-127-30/+48
| | | | Everybody who can, should instead use a RelaySelector.
* Add comments about "unaccompanied" use of Relay{Usage,Exclusion}Nick Mathewson2024-03-122-0/+4
| | | | | | When used outside of RelaySelector, these two types don't enforce one another's presence, and as such have a bit more risk of negligent use.
* Annotate remaining "TODO #504" comments explaining why they are there.Nick Mathewson2024-03-121-4/+14
|
* hspool: Replace TargetInfo with a RelayExclusion.Nick Mathewson2024-03-121-53/+17
|
* guardmgr: explain remaining work for #504 issues.Nick Mathewson2024-03-121-2/+4
|
* guardmgr: refactor most logic for relay selectionNick Mathewson2024-03-123-30/+57
|
* ipt_mgr: convert to use RelaySelector.Nick Mathewson2024-03-122-11/+22
|
* circmgr: Rename "any exit" code to reflect its real purposeNick Mathewson2024-03-122-8/+11
| | | | | (These functionalities are for onion service circuits, and don't actually need to go to an exit at all.)
* circmgr: Remove now-obsolete error variants.Nick Mathewson2024-03-122-48/+5
|
* circmgr: Begin porting path selection to tor-relay-selectionNick Mathewson2024-03-125-191/+160
| | | | | This covers the easy cases, where we are selecting relays at random based on a selector.
* New crate to define a high-level API for relay selectionNick Mathewson2024-03-1211-46/+1684
|
* Create a new empty tor-relay-selection crate.Nick Mathewson2024-03-123-0/+90
|
* netdir: Add additional functionality to SubnetConfigNick Mathewson2024-03-121-1/+62
| | | | We'll need this to implement restrictions more reasonably.
* Add a clear_flags function to RouterStatusBuilderNick Mathewson2024-03-121-0/+6
| | | | (For testing.)
* Merge branch 'arti_client_test' into 'main'gabi-2502024-03-111-1/+12
|\ | | | | | | | | arti-client: increase coverage in src/address.rs See merge request tpo/core/arti!2029
| * arti-client: increase coverage in src/address.rsBrady Fomegne2024-03-051-1/+12
| | | | | | | | | | | | - added test for TorAddr::enforce_config with invalid/onion hostname - added test for display Host::Onion - added test for any type &T who implement IntoTorAddr trait
* | tor-circmgr: Fix clippy warning.Gabriela Moldovan2024-03-111-1/+1
| |
* | tor-guardmgr: Return an error if VanguardMode does not support the specified ↵Gabriela Moldovan2024-03-112-6/+29
| | | | | | | | Layer.
* | tor-circmgr: Add HsCircPoolConfig, make HsCircPool::reconfigure general-purpose.Gabriela Moldovan2024-03-116-14/+54
| |
* | tor-circmgr: Rename Pool::reconfigure to Pool::reconfigure_vanguards.Gabriela Moldovan2024-03-112-2/+2
| |
* | tor-circmgr: Explain why vanguards_config is defined as an "other" accessor.Gabriela Moldovan2024-03-111-0/+5
| |
* | tor-guardmgr: Move the VanguardSets into the inner mutable state.Gabriela Moldovan2024-03-112-12/+13
| |
* | tor-guardmgr: Say more about TimeBoundVanguards.Gabriela Moldovan2024-03-111-0/+8
| |
* | tor-hsclient: Do not enable vanguards feature in dev-dependency.Gabriela Moldovan2024-03-112-1/+3
| |
* | tor-circmgr: Create the VanguardMgr in CircMgr::new.Gabriela Moldovan2024-03-114-27/+18
| |
* | tor-guardmgr: Add TODO about reading vanguards from disk.Gabriela Moldovan2024-03-111-0/+1
| |
* | tor-guardmgr: Make the VanguardMode variants serialize to lowercase.Gabriela Moldovan2024-03-111-0/+1
| |
* | arti-client: Reconfigure the HS circuit pool if needed.Gabriela Moldovan2024-03-111-0/+14
| |
* | arti-client: Keep a handle to the HsCircPool if onion-service-client is enabled.Gabriela Moldovan2024-03-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If vanguards are enabled, we will need to be able to reconfigure the HS circ pool in `TorClient::reconfigure_inner` (to handle the switch from vanguards-full to vanguards-lite etc.). The reconfiguration needs to happen even if only one of `onion-service-client` and `onion-service-service` is enabled. Without this change, in the `onion-service-client`-enabled / `onion-service-service`-disabled case, we'd need to reach into `HsClientConnector::hs_circ_pool` to reconfigure the client `HsCircPool`. By making `hs_circ_pool` part of `TorClient` in both cases, we only need to call `HsCircPool::reconfigure` from one place (in `TorClient::reconfigure_inner`).
* | tor-circmgr: Discard all circuits if VanguardMgr says so.Gabriela Moldovan2024-03-111-0/+11
| |
* | arti-client: Add vanguard_config() to CircMgrConfig.Gabriela Moldovan2024-03-113-2/+27
| |
* | arti-client: Add VanguardsConfig to TorClientConfig.Gabriela Moldovan2024-03-114-3/+23
| |
* | arti-client: Re-export VanguardsConfig from vanguards module.Gabriela Moldovan2024-03-113-1/+11
| |
* | tor-circmgr: Add functions for reconfiguring the HS circuit pool.Gabriela Moldovan2024-03-112-1/+40
| | | | | | | | | | If the vanguard "mode" (full/lite/disabled) changes, we purge all the circuits from the HS circuit pool because they are no longer suitable.
* | tor-circmgr: Store the VanguardMode in HsCircPool.Gabriela Moldovan2024-03-111-0/+11
| |
* | tor-circmgr: Give CircMgr a VanguardMgr.Gabriela Moldovan2024-03-1111-2/+76
| | | | | | | | Closes #1277