aboutsummaryrefslogtreecommitdiff
path: root/crates
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | | | Upgrade rand crates to 0.10.Wesley Aptekar-Cassels2026-05-1299-254/+313
| |_|_|_|_|_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the circ-padding feature is enabled, we use maybenot, which does not yet support rand 0.10. In the meantime, enabling this feature pulls in rand 0.9. This is not ideal, but should be okay as a temporary situation. This also replaces the use of ReseedingRng (which was removed in 0.10) with the reseeding_rng crate. This is somewhat less performant, but it should be okay.
* | | | | | | | | Merge branch 'cc-buf-size' into 'main'gabi-2502026-05-123-31/+37
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | tor-proto: Reorganize error handling for `CtrlMsg::BeginStream` See merge request tpo/core/arti!3975
| * | | | | | | | tor-proto: clean up return type of `Circuit::begin_stream()`Steven Engler2026-05-112-13/+8
| | | | | | | | |
| * | | | | | | | tor-proto: indentation cleanupSteven Engler2026-05-111-20/+15
| | | | | | | | |
| * | | | | | | | tor-proto: reorg error handling for BeginStream reactor cmdSteven Engler2026-05-112-10/+26
| | | | | | | | |
* | | | | | | | | Merge branch 'nd-features-rm' into 'main'Clara Engler2026-05-125-41/+15
|\ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | tor-netdoc: Abolish some empty features, deprecate encode (which is empty), etc. See merge request tpo/core/arti!3972
| * | | | | | | | tor-netdoc: Document retain-unknown feature in READMEIan Jackson2026-05-122-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Part of #2492.
| * | | | | | | | tor-netdoc: Document hs-pow-full feature in READMEIan Jackson2026-05-122-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the docs from Cargo.toml to README, and expand them. Part of #2492.
| * | | | | | | | tor-netdoc: Deprecate encode featureIan Jackson2026-05-121-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This feature is empty already. Part of #2492. We ought to wait a release now before we remove it completely.
| * | | | | | | | tor-netdoc: Abolish empty undocumented feature dangerous-expose-struct-fieldsIan Jackson2026-05-121-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was all un-cfg-gated previously.
| * | | | | | | | tor-netdoc: Tidy Cargo.toml features section a bitIan Jackson2026-05-121-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove some otiose and leftover docs ("Testing only" related to `hs-inner-docs`, now gone) and now-redundant blank lines.
| * | | | | | | | tor-netdoc: Document the `testing` featureIan Jackson2026-05-122-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't need to say it doesn't adhere to semver since every release of tor-netdoc is uses a semver-breaking version. But we do need to say we don't take any care about compatibility.
| * | | | | | | | tor-netdoc: Abolish empty undocumented feature ns-voteIan Jackson2026-05-122-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was never documented. The relevant code is now part of "incomplete". Part of #2492.
| * | | | | | | | tor-netdoc: Abolish empty undocumented feature parse2Ian Jackson2026-05-122-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was never documented. The relevant code is now either unconditional, or part of "incomplete". Part of #2492.
| * | | | | | | | tor-netdoc: Abolish deprecated features plain-consensus, routerdescIan Jackson2026-05-124-19/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were deprecated in the last release. Now we can remove them. Also remove ns_consensus which was never really documented. Part of #2492.
* | | | | | | | | Merge branch 'publish' into 'main'Nick Mathewson2026-05-1217-87/+2153
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a generic `tor-dirpublish` for documents that have to be uploaded to multiple places Closes #2499 See merge request tpo/core/arti!3924
| * | | | | | | | | dirpublish: Extract the larger part of the select_biased body.Nick Mathewson2026-05-121-60/+87
| | | | | | | | | |
| * | | | | | | | | dirpublish: Turn TaskResult into a struct.Nick Mathewson2026-05-121-19/+22
| | | | | | | | | |
| * | | | | | | | | dirpublish: import span and Level for clarity.Nick Mathewson2026-05-121-2/+2
| | | | | | | | | |
| * | | | | | | | | dirpublish: Rename and clarify "permanent failure" error.Nick Mathewson2026-05-122-8/+8
| | | | | | | | | |
| * | | | | | | | | dirclient: improve macro documentationNick Mathewson2026-05-121-6/+16
| | | | | | | | | |
| * | | | | | | | | dirclient: Split EncodedRequest and RequestBody.Nick Mathewson2026-05-124-101/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RequestBody is now just an `Option<Arc<str>>` internally, and EncodedRequest is much simpler.
| * | | | | | | | | grammar fix from @gabi-250Nick Mathewson2026-05-121-1/+1
| | | | | | | | | |
| * | | | | | | | | New `tor-dirpublish` crate to handle uploading documents.Nick Mathewson2026-05-126-0/+1830
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This crate is a generalization of the logic for uploading we currently have in tor-hsservice to handle uploading a (possibly changing) document to a (possibly changing) list of targets. It supports different kinds of documents, different kinds of document targets, and different ways to upload. Currently only direct HTTP uploads are supported; we can add others in the future (and we'll have to, for bridges and onion services.) Closes #2499.
| * | | | | | | | | tor-error: New ErrorKind for rejected documents.Nick Mathewson2026-05-122-3/+17
| | | | | | | | | |
| * | | | | | | | | dirclient: Add a request to upload routerdescsNick Mathewson2026-05-122-34/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (Also refactor the code for POST requests into a new macro, since it would otherwise get quite duplicated.)
| * | | | | | | | | dirclient: Add accessor for status message.Nick Mathewson2026-05-121-0/+5
| | | | | | | | | |
| * | | | | | | | | dirclient: Implement Requestable for Arc<dyn Requestable>.Nick Mathewson2026-05-121-1/+17
| | | | | | | | | |
| * | | | | | | | | dirclient, hsservice: Use Arc<str> for hsdesc publishing.Nick Mathewson2026-05-122-4/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This saves a little memory, but the technique will help save more memory for other uploads.
| * | | | | | | | | tor-dirclient: Avoid copying bytes that we want to POST.Nick Mathewson2026-05-125-31/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This required a change to the hsservice tests, which previously assumed that we'd perform one write per request.
| * | | | | | | | | tor-dirclient: Introduce a new RequestBody type.Nick Mathewson2026-05-125-28/+139
| | |/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I'm going to use this to avoid copying when uploading large documents.
* | | | | | | | | tor-netdoc: Rename RouterDesc real items to their real nameClara Engler2026-05-122-19/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit changes the name of all (except accept/reject) real items in RouterDesc to their proper name as found in the spec. This is a breaking change and semver.md has been updated properly. In the instanciation of RouterDesc in the legacy parser, we now use a "weird" syntax of some fields using a different name throughout the code, but that is ok. Changing this would make the diff way larger at the risk of breaking things, especially because many variables such as identity_cert get shadowed countless times within the function, making it harder and error prone to change.
* | | | | | | | | tor-netdoc: Add fancy rustdoc to real RouterDesc itemsClara Engler2026-05-121-22/+64
| | | | | | | | |
* | | | | | | | | tor-netdoc: Reorder real RouterDesc itemsClara Engler2026-05-121-41/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit reorders the real RouterDesc items according to the spec. Unfortunately, the names of those are not real yet, meaning that verifying this is somewhat hard. Personally, I recommend to verify that this commit does not add/remove lines using --color-moved. The correct order is probably easier to verify with the next commit applied that adds nice rustdoc comments explaining to which fields in the spec the respective items belong. This is a bit of a chicken egg situation but if I would have added the nice rustdoc comments first, this diff would have been awful to review, because the hunks of reordering the nice rustdoc comments included are awful to review, so please bear with me for the next commit.
* | | | | | | | | tor-netdoc: Reorder RouterDesc into virtual and real itemsClara Engler2026-05-121-10/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit reorders the RouterDesc struct into virtual and real items, with real items being items that actually exist (although potentially under a different name) in router descriptors. Virtual items on the other hand do not exist this way in router descriptors and have to be removed at one point or another.
* | | | | | | | | tor-netdoc: Add spacing to RouterDescClara Engler2026-05-121-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Makes this much nicer to read.
* | | | | | | | | Merge branch 'combine-hex' into 'main'Clara Engler2026-05-121-11/+11
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | tor-netdoc: Combine two hex encoding loops into a function See merge request tpo/core/arti!3947
| * | | | | | | | tor-netdoc: Combine two hex encoding loops into a functionIan Jackson2026-05-051-11/+11
| | | | | | | | |
* | | | | | | | | Merge branch 'fslock-redux' into 'main'Nick Mathewson2026-05-118-138/+173
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | Update code to actually eliminate fslock *and* the LockFile type. See merge request tpo/core/arti!3954
| * | | | | | | | fslock-guard: add a fileapi feature dep for winapiNick Mathewson2026-05-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With dropping the fslock crate, we lost this feature flag from _its_ use of winapi.
| * | | | | | | | fslock-guard: Fix up documentation a bit.Nick Mathewson2026-05-062-7/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This mainly amounts to clarifying some of our windows desiderata, and removing the final refrences to fslock.
| * | | | | | | | fslock-guard: Compile on wasm.Nick Mathewson2026-05-061-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can't actually open a file on wasm-unknown-unknown, but it's more convenient for us if we don't have to conditionally compile this crate every place that uses it.
| * | | | | | | | fslock-guard: Remove fslock dependency.Nick Mathewson2026-05-062-25/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can do this since our msrv is now 1.89.0, where File::lock is supported.
| * | | | | | | | Remove users of fslock other than fslock-guard.Nick Mathewson2026-05-065-106/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were two that relied on the the ability to have a lock in an unlocked state. Instead, we replace those with Option<LockFileGuard> or its equivalent.
* | | | | | | | | hsclient: s/cur_revision/stored_revision for clarityGabriela Moldovan2026-05-071-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "Stored" is more accurate than "current".
* | | | | | | | | hsclient: Compare the time periods instead of the blinded HsIdsGabriela Moldovan2026-05-071-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The blinded HsIds were used a proxy for the time periods, but it's better to just compare the TPs directly. Part of #966
* | | | | | | | | hsclient: Store the current time period in a variable (fmt)Gabriela Moldovan2026-05-071-2/+1
| | | | | | | | |
* | | | | | | | | hsclient: Store the current time period in a variableGabriela Moldovan2026-05-071-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will soon need to be copied into `HsDescForTp`.
* | | | | | | | | hsclient: Fix an off-by-one checkGabriela Moldovan2026-05-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We no longer consider the HsDir rate-limited if its `requery == now`. This was caught by the new tests.
* | | | | | | | | hsclient: Add test for introduction retries after intro NACKGabriela Moldovan2026-05-071-5/+113
| | | | | | | | |