| Commit message (Collapse) | Author | Age | Files | Lines |
| |\
| |
| |
| |
| |
| |
| | |
Implement proposal 360 (limit HsDesc inflation opportunities)
Closes #2046
See merge request tpo/core/arti!3070
|
| | | |
|
| | |
| |
| |
| |
| | |
It would be better to take a more sophisticated approach;
see #2048.
|
| | | |
|
| | |
| |
| |
| |
| | |
In particular, these are errors that provide an opportunity to
inflate the size of an hsdesc download.
|
| | |
| |
| |
| |
| | |
These errors are suspicious as hsdir inflation attacks, in the
context of prop360.
|
| | |
| |
| |
| | |
Part of proposal 360.
|
| | |
| |
| |
| |
| | |
Previously it didn't include end-of-line space, even though the docs
said it did.
|
| | | |
|
| |/
|
|
| |
Made with https://crates.io/crates/typos-cli
|
| |
|
|
| |
See #2060.
|
| |
|
|
|
|
| |
- Replaced `once_cell::sync::Lazy` with `std::sync::LazyLock`.
Signed-off-by: hashcatHitman <[email protected]>
|
| |
|
|
|
|
| |
> The actual impact of this patch is to prevent usage of MiddleOnly
> relays as Introduction Points. The Rendezvous Point logic isn't
> hooked up yet - nick
|
| |
|
|
|
| |
Now that our MSRV is 1.83, clippy is happy to make more
recommendations for us.
|
| |\
| |
| |
| |
| |
| |
| | |
Enforce recommended and required protocol versions in arti-client
Closes #1849 and #1923
See merge request tpo/core/arti!2929
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| | |
We'll want this so that we can expose them before we expose the rest
of the consensus (which we need to do for spec conformance).
|
| | |
| |
| |
| | |
Also, add a new ErrorKind for this sort of error.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Part of #1849.
Note that these functions are distributed across crates,
so that if (in the future) we stop doing API breaks
with every release, we will get the right outputs.
Note also that these functions build the list of protocols
out of specific symbolic features, rather than numbers:
this makes it easier to avoid errors about "which feature was
Relay=4 again", and easier to avoid accidentally referring to a
protocol that doesn't exist, like "Consensus" (should be "Cons")
or "HsDir" (case is wrong).
|
| | |
| |
| |
| | |
Whoops! Missed that.
|
| |/
|
|
| |
- [`once_cell::sync::OnceCell`] has been replaced by [`std::sync::OnceLock`].
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
```text
warning: length comparison to one
--> crates/tor-netdoc/src/parse/tokenize.rs:470:12
|
470 | if args.len() >= 1 {
| ^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!args.is_empty()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero
note: the lint level is defined here
--> crates/tor-netdoc/src/lib.rs:9:9
|
9 | #![warn(clippy::all)]
| ^^^^^^^^^^^
= note: `#[warn(clippy::len_zero)]` implied by `#[warn(clippy::all)]`
```
|
| |
|
|
| |
- The Rng::gen() functions have been renamed to Rng::random().
|
| |
|
|
| |
- `rand::thread_rng()` has been deprecated and renamed to `rand::rng()`
|
| |
|
|
|
| |
This is partly for consistency, and partly to facilitate
a global search-and-replace.
|
| |\
| |
| |
| |
| | |
Wrap x25519-dalek and ed25519-dalek types.
See merge request tpo/core/arti!2868
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
With this change, we'll no longer need to expose the types from
dalek-cryptography as part of our API, and we'll have more freedom
to switch ed25519 implementations, or to upgrade to a newer
`rand` ahead of their schedule.
Unlike with x25519-dalek, I had to tweak the API a bit: There's no
way to get a &PublicKey out of a Keypair now, and implementing the
old ed25519-dalek traits seemed unnecessary.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Per <https://spec.torproject.org/dir-spec/netdoc.html>,
our netdocs never have a BOM, and never have internal NULs.
This makes Arti reject such documents.
For arguments on why it's okay to increase parser strictness,
see the (forthcoming) proposal 356 at torspec!342,
and see older discussion at torspec#296.
Closes #1739.
|
| |/
|
|
|
|
|
| |
I'm about to make our parsers reject some strings at construction
time, so it makes sense to have these functions become fallible.
This is a breaking change.
|
| |\
| |
| |
| |
| |
| |
| | |
Client implementation for happy families
Closes #1848
See merge request tpo/core/arti!2792
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| | |
This corresponds to the entries in "family-ids" in the happy
families design.
|
| |/
|
|
| |
This fixes a warning that triggers on the latest stable release (1.85).
|
| |\
| |
| |
| |
| | |
clippy: deny `mod_module_files`
See merge request tpo/core/arti!2689
|
| | |
| |
| |
| |
| |
| | |
Denies 'mod.rs' files for consistency.
https://rust-lang.github.io/rust-clippy/master/index.html#mod_module_files
|
| |/ |
|
| |
|
|
|
|
|
|
| |
In 1.83, this warning triggers on many of our crates.
We're thinking of fixing them all, but for now,
we're going to disable the warning.
This is part of #1765.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This replaces the hs-pow, hs-pow-full, hs-pow-v1, pow-v1, and pow-full
features with a single hs-pow-full feature.
It's possible that in the future we will want to split different schemes
into different features, but we can do that when it comes up.
For now, having this as a single flag makes it clearer what's going on,
since the previous thing was not actually expressive enough to capture
some things we care about (like "at least one pow scheme is enabled"
that works in a future-compatible way).
This change is not semver breaking since it's a experimental feature.
Related: #1751
|
| | |
|
| | |
|
| |
|
|
|
|
|
| |
I'm not particularly happy with the code that does the actual writing
out of the pow-params line, in particular the error handling there seems
very verbose. However, I don't know of a better way to structure it
given that APIs I'm working with.
|
| |
|
|
| |
Fixes: #1691
|
| | |
|