| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
This adds the lint to all our crates.
|
| |
|
|
|
| |
These are all aimed at figuring out in more detail what's going on
in #2079 and related issues.
|
| |
|
|
| |
Run maint/add_warning
|
| |
|
|
| |
Part of #1885.
|
| |
|
|
| |
This feature has been removed from nightly, in favor of doc_cfg.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
First, run
```
git grep -l "^edition =" |
xargs perl -i -pe 's/^edition *=.*/edition = "2024"/;'
```
Second, manually verify that all Cargo.toml files have changed,
and nothing else has changed.
Third, run cargo fmt again.
|
| |
|
|
|
|
| |
This entirely removes the requirement on ClientCirc.
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
| |
(This was previously called a parse error, which isn't right.)
|
| |
|
|
|
|
|
| |
1) It's the last hop that matters, not the first.
2) The last hop could conceivably be virtual, making the source anonymous.
(Though this never happens in Arti today.)
|
| |
|
|
| |
See #2060.
|
| |
|
|
|
|
|
|
| |
This suffix is redundant with "Accept-Encoding",
which all Tor directory caches have supported
since 0.3.1.1-alpha.
See torspec#342.
|
| |
|
|
|
|
|
|
| |
This is messy, because `ClientCirc::{path_ref, n_hops, ..}` become
fallible (we can't unwrap the result, because when a circuit is closed,
its state gets removed from the `TunnelSharedState`, but its
`ClientCirc` handle continues to exist, so any attempt to retrieve the
state will result in an `Err`).
|
| |
|
|
|
|
|
| |
MockSleepProvider and MockSleepRuntime have been declared deprecated
by the docs for some time. We're about to mark them `#[deprecated]`.
This commit has been split out for clarity of review.
|
| | |
|
| |
|
|
|
|
| |
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 commit is automatically generated.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
The HTTP status text is often useful for diagnosing errors. Tor
directory and hsdir caches frequently put useful messages there,
especially when rejecting an uploaded document.
Inspired by #1142.
|
| |
|
|
|
| |
As per this comment, and preceding discussion
https://gitlab.torproject.org/tpo/core/arti/-/issues/1060#note_2959187
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Since not everybody has xz and/or zstd, we don't want to admit
whether we support them when we are uploading or downloading an
onion service descriptor. Similarly, if we aren't advertising
support for an encoding, we shouldn't accept it.
Finally, while we're doing this, it made sense to have the ability
to mark requests based on how anonymized they are, and reject (some)
attempts to send those requests over a one-hop circuit.
Closes #1062
|
| | |
|
| | |
|
| |
|
|
|
|
| |
`download()` is actually a general-purpose function for sending HTTP
requests on a stream. We will soon repurpose it for `POST`-ing
descriptors, so let's rename it to `send_request`.
|
| | |
|
| | |
|
| |
|
|
| |
Closes #950.
|
| | |
|
| |
|
|
|
|
|
| |
Requring `Display` is wrong here, because if this is actually an
Error, Display would be wrong because it doesn't display causes.
As it happens, the `error` parameter is only ever `&str`.
|
| |
|
|
|
| |
This panics on error, and we're fine with a panic on misbehavior in
tests.
|
| |
|
|
|
|
|
|
| |
This warning kind of snuck up on us! (See #748) For now, let's
disable it. (I've cleaned it up in a couple of examples, since
those are meant to be more idiomatic and user-facing.)
Closes #748.
|
| |
|
|
|
| |
This is precisely the result of running the rune in
maint/adhoc-add-lint-blocks.
|
| | |
|
| | |
|
| |
|
|
| |
Split off to assist review.
|
| |
|
|
|
|
|
| |
We're going to have functions on Response that fail by returning only
one of these.
Sadly this diff is quite noisy.
|
| |
|
|
|
| |
These don't check errors and are therefore quite hazardous.
I'm going to introduce a more cooked version in a moment.
|
| |
|
|
|
|
|
| |
Apparently cargo fmt doesn't like these, which my perl rune didn't
delete.
This commit is precisely the result of `cargo fmt`.
|
| |
|
|
|
|
|
|
| |
The feature we want is `#[doc = include_str!("README.md")]`, which is
stable since 1.54 and our MSRV is now 1.56.
This commit is precisely the result of the following Perl rune:
perl -i~ -0777 -pe 's{(^//!(?!.*\@\@).*\n)+}{#![doc = include_str!("../README.md")]\n}m' crates/*/src/lib.rs
|
| | |
|
| |
|
|
| |
Update all lint blocks
|
| |
|
|
|
| |
From running add_warning, with manual picking of the right
hunks/lines.
|
| |
|
|
|
|
| |
This was the result of:
maint/add_warning crates/*/src/{lib,main}.rs
and then manually curating the results.
|
| |
|
|
| |
This will help implement #466.
|
| | |
|
| |\
| |
| |
| |
| |
| |
| | |
Don't use SystemTime::now()
Closes #306
See merge request tpo/core/arti!365
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This commit refactors the dirclient error type into two cases:
errors when constructing a circuit, and errors that occur once we
already have a one-hop circuit. The latter can usually be
attributed to the specific cache we're talking to.
This commit also adds a function to expose the information about
which directory gave us the info.
|