aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-netdir/src/params.rs
Commit message (Collapse)AuthorAgeFilesLines
* Remove now-unneeded allow(clippy::cognitive_complexity)Jim Newsome2026-07-151-1/+0
|
* maint: Run maint/add_warning to deny string slicesClara Engler2026-06-091-0/+1
| | | | | | | | | | | | This commit executes maint/add_warning with the just added change to deny string slices except in tests. I recommend auditing this by checking out the previous commit followed by running the script yourself and then verifying that the diff is identical to this commit. This commit makes cargo clippy fail. We will add exceptions in the next commit.
* relay: Crypto task now listens for new consensusDavid Goulet2026-05-261-0/+9
| | | | Signed-off-by: David Goulet <[email protected]>
* Fix grammar typosTobias Stoeckmann2026-03-151-1/+1
|
* Fix word duplicate typosTobias Stoeckmann2026-03-151-2/+2
|
* Fix name of clippy lint to unchecked_time_subtraction (2)Ian Jackson2025-11-061-1/+1
| | | | Run maint/add_warning
* Merge branch 'xon-xoff-checker' into 'main'David Goulet2025-09-151-0/+33
|\ | | | | | | | | tor-proto,tor-netdir: add flow control consensus parameters See merge request tpo/core/arti!3249
| * tor-netdir: add flow control parameters to `NetParameters`Steven Engler2025-09-101-0/+33
| |
* | tor-netdir: change default `cc_alg` from 0 to 2Steven Engler2025-09-101-5/+1
|/ | | | | | | | This is fine because we still default to non-cc circuits unless the "flowctl-cc" feature is enabled. See `exit_circparams_from_netparams` and `onion_circparams_from_netparams` from `tor_circmgr::build`, where both will only call `build_cc_vegas()` if `cfg(feature = "flowctl-cc")`, and otherwise call `build_cc_fixedwindow()`.
* clippy: fix `clippy::duplicated_attributes` warningsSteven Engler2025-08-111-1/+0
| | | | | | | | | | ```text warning: duplicated attribute --> crates/tor-hsservice/src/timeout_track.rs:630:14 | 630 | #![allow(clippy::needless_pass_by_value)] // TODO hoist into standard lint block | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ```
* tor-hsservice: Time out RendRequests in PoW queue.Wesley Aptekar-Cassels2025-08-051-1/+0
|
* tor-hsservice: Add consensus params for Prop 362.Wesley Aptekar-Cassels2025-08-051-0/+25
| | | | | | | | | | | This adds the three new parameters specified in Prop 362 [0]. Two of these replace hardcoded defaults in the code. The third, HiddenServiceProofOfWorkV1ServiceIntroTimeoutSeconds, is not implemented yet, but will be in a future commit. [0]: https://spec.torproject.org/proposals/362-update-pow-control-loop.html
* Merge branch 'prop360-combined' into 'main'Nick Mathewson2025-07-101-0/+10
|\ | | | | | | | | | | | | Implement proposal 360 (limit HsDesc inflation opportunities) Closes #2046 See merge request tpo/core/arti!3070
| * Suggestions from @gabi-250 on prop360 implementation.Nick Mathewson2025-07-101-1/+1
| |
| * netdir: new parameters from prop360.Nick Mathewson2025-07-101-0/+10
| | | | | | | | (maxima are as amended in torspec!411)
* | Typo fixes (automatic and hand-verified)Nick Mathewson2025-07-091-1/+1
|/ | | | Made with https://crates.io/crates/typos-cli
* NetParameters::saturating_update: log when a value is out of rangeJim Newsome2025-06-231-1/+71
| | | | | | | On one hand, this can be quite noisy when something *is* out of range. On the other hand, a clamped value shouldn't normally happen, and is likely to result in surprising and otherwise difficult-to-debug behavior.
* Log unrecognized net paramsJim Newsome2025-06-231-1/+4
|
* tor-netdir: decrease minimum hsdir_interval from 30 to 5Jim Newsome2025-06-101-1/+1
| | | | | | | | This matches the spec change: <https://gitlab.torproject.org/tpo/core/torspec/-/merge_requests/406> Progress on: <https://gitlab.torproject.org/tpo/core/chutney/-/issues/40038>
* tor-netdir: remove lint allow as per TODOhashcatHitman2025-04-161-3/+0
| | | | | - https://github.com/rust-lang/rust-clippy/issues/11764 was fixed upstream, so this is no longer needed.
* netdir: Add client params related to happy families (prop321)Nick Mathewson2025-02-251-0/+10
|
* fix: fix typosDimitris Apostolou2025-01-301-1/+1
|
* netdir: Add congestion control consensus parametersDavid Goulet2025-01-161-22/+101
| | | | | | Related #534 Signed-off-by: David Goulet <[email protected]>
* tor-netdir: Add KIST consensus params.Gabriela Moldovan2025-01-151-0/+26
| | | | | | These are tentative, so I haven't added them to param-spec yet. Part of #1729
* tor-netdir: Fix broken links in NetParameters docs.Gabriela Moldovan2024-03-261-3/+3
| | | | Spotted in https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2053#note_3012632
* tor-netdir: Use IntegerSeconds for the vanguard lifetime params.Gabriela Moldovan2024-03-261-4/+4
|
* tor-netdir: Use consistent termninology in the vanguard param docs.Gabriela Moldovan2024-03-261-6/+6
|
* tor-netdir: Fix torspec links in vanguard param docs.Gabriela Moldovan2024-03-261-8/+8
|
* tor-netdir: Add the vanguard params to NetParameters.Gabriela Moldovan2024-03-261-0/+70
| | | | | | See also torspec!258 Part of #1272
* Run maint/add_warning.Nick Mathewson2024-03-131-0/+1
|
* Rename parameters for intro-point lifetime to match the spec.Nick Mathewson2024-01-311-4/+4
| | | | | | | | | | (Also, correct the comments that describe them.) We may as well match the spec names when they aren't completely bogus. We are already renaming these parameters for this release, so it isn't an additional breaking change.
* Rename our aliases for hs_intro_*_lifetime.Nick Mathewson2024-01-251-2/+2
| | | | | | The old names were somewhat inaccurate. (I would have considered keeping and deprecating the old names, but we already have breaking changes in tor-netdir.)
* clippy: Add an allow to work around a clippy bugIan Jackson2024-01-021-0/+3
| | | | | | | | | | clippy in current stable thinks |(a, b)| (a, b) is always the identity function, but due to match ergonomics, it might be an implicit copy. This is fixed in nightly by https://github.com/rust-lang/rust-clippy/pull/11792
* Improve documentation in/around DosParams extensionNick Mathewson2023-11-201-6/+13
| | | | | | It does not help that C tor has a set of parameters and a set of configuration options with exactly the same names which configure the same thing in two slightly different ways.
* Run maint/add_warning to add lint block everywhereIan Jackson2023-08-231-0/+1
|
* Run maint/add_warning to actually apply new lint allowsIan Jackson2023-07-101-0/+1
|
* Allow clippy::unchecked_duration_subtraction in testsNick Mathewson2023-01-271-0/+1
| | | | | This panics on error, and we're fine with a panic on misbehavior in tests.
* netdir: add network parameters related to onion servicesNick Mathewson2023-01-111-1/+80
| | | | | | | These are available unconditionally, since they represent comparatively little storage and processing effort. See param-spec.txt section 8 for the original information here.
* test lint blocks: Add many many automaticallyIan Jackson2022-12-121-0/+9
| | | | | This is precisely the result of running the rune in maint/adhoc-add-lint-blocks.
* tor-netdoc: if_ito: Add expansion of acronymIan Jackson2022-08-171-0/+2
|
* tor-congestion: implement the RTT estimation algorithm from prop#324eta2022-08-111-0/+21
| | | | | | | | | | | This commit implements the round-trip-time estimation algorithm from Tor proposal 324, validating the implementation against the test vectors found in C tor. (Note that at the time of writing, the new test vectors may not be committed to C tor yet, but they will be soon.) This also adds the necessary consensus parameters to `NetParameters`. Some of them have been renamed in order to (hopefully) make them more understandable.
* Finish implementation of params() for DirMgr.Nick Mathewson2022-08-021-0/+8
| | | | | | | Now it maintains an up-to-date set of default parameters to be handed out if there is no directory. Closes #528.
* channel padding: Use IntegerMilliseconds in netdirIan Jackson2022-06-211-8/+8
|
* tor-netdir: Make CHANNEL_PADDING_TIMEOUT_UPPER_BOUND pubIan Jackson2022-06-211-1/+1
| | | | We need this because it is a type parameter for the types of nf_ito_*.
* channel padding: Change timeout to match C TorIan Jackson2022-06-211-1/+6
| | | | Pending an official value from the spec.
* channel padding: Add the parameters from the spec to NetDirIan Jackson2022-06-211-0/+28
|
* Remove some outdated comments.Nick Mathewson2022-06-171-1/+1
| | | | | These all say, in one form or another, "there is no guard filtering; there is only one selection". That's now false.
* squash! Bump every crate's edition to 2021.Nick Mathewson2022-04-251-2/+0
| | | | | Remove all `use` statements for `TryFrom` and `TryInto`. These are now redundant in Rust 2021.
* tor-netdir: Resolve an XXXX about type uglinessNick Mathewson2021-12-081-1/+1
| | | | | | | | | | | | | | | We had no function to infallibly convert BoundedInt32<{0 or 1},H> into a u32, even though we could have. Because of that, we were treating weight_scale as an i32 when logically it's a u32 or a NonZeroU32. Moreover, it turns out we were using an incorrect minimum for the bwweightscale param, which would in theory have allowed the authorities to make us divide by zero. This patch introduces the necessary From<> implementation and uses it. It corrects the binimum bwweightscale, and prevents a division-by-zero issue in case weight_scale is zero.
* Remove a couple of spec-related XXXXs in tor-netdir.Nick Mathewson2021-12-081-2/+0
| | | | | I've opened torspec!54 to fill in the missing parts of the spec about these issues.