summaryrefslogtreecommitdiff
path: root/crates/tor-guardmgr
Commit message (Collapse)AuthorAgeFilesLines
* Update unstable `tor/arti-*` crates to 0.17.0.Nick Mathewson2024-04-021-19/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Done with: ``` CRATES=" tor-basic-utils tor-async-utils tor-error tor-config tor-events tor-units tor-geoip tor-rtcompat tor-rtmock tor-log-ratelim tor-rpcbase tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-hspow tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-congestion tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-bench arti-testing " for crate in $CRATES; do cargo set-version -p "$crate" 0.17.0 done ```
* Bump patchlevel versions on non-{tor/arti} crates.Nick Mathewson2024-04-021-1/+1
| | | | | | | | | | | | | | | | These have all had backward-compatible changes. Generated with: ``` cargo set-version --bump patch -p fs-mistrust cargo set-version --bump patch -p test-temp-dir cargo set-version --bump patch -p fslock-guard cargo set-version --bump patch -p hashx cargo set-version --bump patch -p equix cargo set-version --bump patch -p caret cargo set-version --bump patch -p safelog cargo set-version --bump patch -p retry-error ```
* Run "fixup-features" in preparation for next release.Nick Mathewson2024-03-281-1/+1
|
* tor-guardmgr: Replace From impl with from_net_parameter constructor.Gabriela Moldovan2024-03-261-2/+8
|
* tor-guardmgr: Implement From<BoundedInt32> for VanguardMode.Gabriela Moldovan2024-03-261-0/+13
| | | | | We'll need this to convert the `vanguard_enabled` and `vanguard_hs_service` net params to a `VanguardMode.
* tor-circmgr: Fix a clippy warning.Gabriela Moldovan2024-03-212-2/+2
|
* tor-guardmgr: Explain what neighbor_exclusion is for.Gabriela Moldovan2024-03-212-3/+25
|
* tor-guardmgr: Make Vanguard::select_relay take a RelayExclusion.Gabriela Moldovan2024-03-212-2/+9
| | | | | | | This enables us to prevent the same relay from being picked in consecutive positions in a path. Part of #1340
* tor-circmgr: Unconditionally define VanguardMode.Gabriela Moldovan2024-03-203-20/+36
|
* tor-guardmgr: Derive getters for Vanguard.Gabriela Moldovan2024-03-201-2/+1
|
* tor-guardmgr: Add a function for getting the current VanguardMode.Gabriela Moldovan2024-03-201-0/+5
|
* Run maint/add_warning.Nick Mathewson2024-03-1310-0/+10
|
* Annotate usage of low_level_predicate_permits_relayNick Mathewson2024-03-121-1/+7
|
* Rename the RelayPredicate trait to discourage its being used directly.Nick Mathewson2024-03-121-2/+2
| | | | Everybody who can, should instead use a RelaySelector.
* Add comments about "unaccompanied" use of Relay{Usage,Exclusion}Nick Mathewson2024-03-121-0/+2
| | | | | | 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.
* 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
|
* tor-guardmgr: Return an error if VanguardMode does not support the specified ↵Gabriela Moldovan2024-03-112-6/+29
| | | | Layer.
* 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-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: Re-export VanguardsConfig from vanguards module.Gabriela Moldovan2024-03-111-1/+1
|
* tor-circmgr: Give CircMgr a VanguardMgr.Gabriela Moldovan2024-03-111-0/+4
| | | | Closes #1277
* tor-guardmgr: Add vanguards API skeleton.Gabriela Moldovan2024-03-116-1/+297
| | | | Part of #1275
* Fix typos in doc commentsTobias Stoeckmann2024-03-061-1/+1
|
* Merge branch 'deny-unchecked-duration-substraction' into 'main'Ian Jackson2024-03-051-0/+1
|\ | | | | | | | | | | | | deny clippy::unchecked_duration_subtraction Closes #1304 See merge request tpo/core/arti!2008
| * deny clippy::unchecked_duration_subtractiontrinity-1686a2024-02-291-0/+1
| |
* | Bump the minor version, for crates with breaking changes.Gabriela Moldovan2024-03-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | APIs were broken in these pre-1.0.0 crates: ``` tor-keymgr tor-config tor-checkable tor-circmgr tor-dirmgr tor-hsclient tor-hsservice tor-hsrproxy ``` Done with: ``` cargo set-version --bump minor -p tor-keymgr cargo set-version --bump minor -p tor-config cargo set-version --bump minor -p tor-checkable cargo set-version --bump minor -p tor-circmgr cargo set-version --bump minor -p tor-dirmgr cargo set-version --bump minor -p tor-hsclient cargo set-version --bump minor -p tor-hsservice cargo set-version --bump minor -p tor-hsrproxy ```
* | Bump patchlevel of pre-1.0.0 crates with new APIs.Gabriela Moldovan2024-03-041-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | APIs were added: ``` tor-units tor-cell tor-proto tor-netdir arti-client ``` Done with: ``` cargo set-version --bump patch -p tor-units cargo set-version --bump patch -p tor-cell cargo set-version --bump patch -p tor-proto cargo set-version --bump patch -p tor-netdir cargo set-version --bump patch -p arti-client ```
* | Bump patchlevel of crates with functional changes.Gabriela Moldovan2024-03-041-5/+5
|/ | | | | | | | | | | | | | | | | | | | | | Functional changes were made, but no APIs were added or broken: ``` tor-events (async_broadcast 0.6.0 -> 0.7.0) tor-netdoc (signature 1 -> 2) tor-guardmgr arti-testing (config 0.13.4 -> 0.14.0) tor-persist (breaking changes gated behind experimental feature) fslock-guard (fix lockfile_has_path compilation on Windows) ``` Done with: ``` cargo set-version --bump patch -p tor-events cargo set-version --bump patch -p tor-netdoc cargo set-version --bump patch -p tor-guardmgr cargo set-version --bump patch -p arti-testing cargo set-version --bump patch -p tor-persist cargo set-version --bump patch -p fslock-guard ```
* Mark code with "TODO #504" and "TODO #789".Nick Mathewson2024-02-222-0/+4
| | | | | | | | I've done this by looking for every non-test instance of pick_relays or pick_n_relays, and for every non-test usage of any non-ID-related method on Relay or UncheckedRelay. Part of #504.
* Merge branch 'fast_and_stable' into 'main'Nick Mathewson2024-02-202-4/+7
|\ | | | | | | | | | | | | Require the Fast and Stable flags as appropriate. Closes #1100 See merge request tpo/core/arti!1976
| * Add and use "UncheckedRelay::is_suitable_as_guard"Nick Mathewson2024-02-201-1/+1
| |
| * Require that guards are Fast and Stable.Nick Mathewson2024-02-202-3/+6
| | | | | | | | | | | | This matches the behavior of C tor. Part of #1100.
* | tor-guardmgr: Fix README typo.Gabriela Moldovan2024-02-121-1/+1
| |
* | tor-guardmgr: Fix spec link in README.Gabriela Moldovan2024-02-121-1/+1
|/ | | | The old link now 404s, so let's link to spec.torproject.org instead.
* educe: Use std's default for enums where default variant is unitIan Jackson2024-02-122-14/+8
| | | | | | | | | | | | | Since Rust 1.66, std's default works properly for enums, provided that the default variant is a unit. Review all uses of `#[educe(default)]` on enums and replace them with std where possible, which is most of them. In 1.66 and later, std's `#[derive(Default)]` doesn't infer any generic bounds on the derived impl, where it's an enum - since the unit variant can always be constructed. So this change doesn't add any generic bounds and is not API-visible.
* Bump minor versionsIan Jackson2024-02-051-13/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bump the minor version of these crates, and update the in-tree dependencies. Recently published as fresh crates, let's just assume there are breaking changes: fslock-guard test-temp-dir Breaking API change affecting many many downstream crates: tor-rtcompat Downstream crates which we're (conservatively) assuming have tor-rtcompat types in their APIs: tor-rtmock tor-log-ratelim tor-rpcbase tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-hspow tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-congestion tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-bench arti-testing
* Upgrade to strum 0.26Nick Mathewson2024-01-301-1/+1
|
* Followup minor version bumps.Nick Mathewson2024-01-091-1/+1
| | | | | | | | These crates had no changes previously, but they depend on crates that had breaking changes themselves. tor-linkspec tor-hspow
* Patchlevel version bumps in preparation for 1.1.12.Nick Mathewson2024-01-091-3/+3
| | | | | | | | | | | | | This crate doesn't have a meaningful public API, so it just gets a patchlevel bump: arti These crates had nonbreaking changes, and get a patchlevel bump: tor-rtcompat fs-mistrust tor-llcrypto tor-cert
* Breaking version bumps in preparation for 1.1.12.Nick Mathewson2024-01-091-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These crates have breaking changes on their own: tor-error tor-netdoc tor-dirmgr tor-keymgr Because of the breaking change in tor-error, and the fact that basically every crate publicly depends on tor-error (by implementing ErrorKind), we need to call this a breaking change on all of the following: tor-config tor-geoip tor-rtmock tor-log-ratelim tor-rpcbase tor-bytes tor-hscrypto tor-socksproto tor-cell tor-proto tor-netdoc tor-netdir tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-testing
* upgrade to toml 0.8.8Nick Mathewson2023-12-051-1/+1
|
* Merge branch 'msrv-followup' into 'main'Nick Mathewson2023-12-043-12/+4
|\ | | | | | | | | Followups from MSRV 1.70 upgrade See merge request tpo/core/arti!1785
| * guardmgr: Stop using now-needless retain_mut crate.Nick Mathewson2023-11-303-12/+4
| |
* | Bump minor versions in preparation for releaseNick Mathewson2023-12-041-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This crate is new, and gets a bump to 0.1.0. tor-log-ratelim This crate had a breaking change: tor-persist tor-llcrypto had a breaking change. These crates _are_ tor-llcrypto, or (transitively) depend on it. I am assuming that they all re-expose something from it in a way that matters: tor-llcrypto tor-bytes tor-hscrypto tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-hyper
* | Bump patchlevel versions in preparation for releaseNick Mathewson2023-12-041-4/+4
|/ | | | | | | | | | | | | | | These crates had backward-compatible changes, and get a patchlevel bump only: fs-mistrust tor-error tor-config tor-rtcompat tor-rtmock This crate exposes no non-CLI APIs, and gets a patchlevel bump only: arti
* In every crate, change rust-version to 1.70.Nick Mathewson2023-11-281-1/+1
|
* Upgrade to itertools 0.12.0Nick Mathewson2023-11-151-1/+1
|