| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| | |
|
| |
|
|
|
|
| |
This new release checks for invalid symbols in non-padded inputs
for decoding. Therefore, we can get rid of the logic implemented
in `https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/600`
|
| |\
| |
| |
| |
| | |
Fix clippy nightly again
See merge request tpo/core/arti!603
|
| | |
| |
| |
| | |
Update all lint blocks
|
| |\ \
| | |
| | |
| | |
| | | |
Error refactoring: bytes, cert, proto.
See merge request tpo/core/arti!604
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| | |
Some of these were for decoding particular objects (we now say
what kind of objects), and some were unrelated tor_cert errors that
for some reason we had shoved into a tor_bytes::Error.
There is now a separate tor_cert::CertError type, independent from
tor_cert's use of `tor_bytes::Error` for parsing errors.
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| | |
These tests are borrowed from other parts of the `tor-netdoc`
crate.
|
| | |
| |
| |
| | |
Request for changes: `https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/600#note_2816252`
|
| | |
| |
| |
| | |
As per request, here: `https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/600#note_2816252`
|
| |/
|
|
|
|
|
| |
Note: the `base64ct` crate rejects invalid characters when the
decoding is done on padded strings. However, the `FromStr` impl
for `B64` can have both padded **and** unpadded inputs, so all
inputs are now padded first, before decoding.
|
| |
|
|
| |
(This doesn't do anything yet.)
|
| |
|
|
|
|
| |
I'm using serde_with here to just re-use the Display and FromStr
implementations, since those are what has proven easier to type in
the past.
|
| | |
|
| |
|
|
|
| |
Without this, clippy is error-free, but `cargo test` somehow gives a
warning.
|
| | |
|
| |
|
|
|
|
|
|
| |
(This is slightly different from recovering from errors in the
middle of a list of mds, since in this case we _can't_ advance to the
next md.)
Also, note that a given branch is probably not reachable.
|
| |
|
|
|
| |
The "bad-id" microdescriptor is hand-edited based on one from a
Chutney network.
|
| | |
|
| |
|
|
| |
Found via coverage.
|
| | |
|
| | |
|
| |
|
|
|
| |
The kind type was already public, but we didn't give the user any
way to get it.
|
| | |
|
| | |
|
| |
|
|
|
| |
We accidentally tried to validate (invalid) ed25519 keys
as curve25519 keys.
|
| |
|
|
| |
This is a coverage-driven test.
|
| | |
|
| | |
|
| |
|
|
|
| |
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 is ridiculous.
|
| |
|
|
|
| |
We want to supress the unused_macro_rules lint in one place but it's
new in Nightly and this triggers yet another lint.
|
| |
|
|
|
|
|
| |
The compiler can apparently tell that we aren't generating compile
errors! Also that we're not yet using a feature provided here.
(New lint in currently Nightly.)
|
| |
|
|
| |
It's a little overzealous sometimes, but it's mostly to the good.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
Relay nicknames are always between 1 and 19 characters long, and
they're always ASCII: That means that storing them in a [u8;19] will
always be possible, and always use less resources than storing them
in a String.
Fortunately, the tinystr crate already helps us with this kind of
thing.
|
| | |
|
| | |
|
| |
|
|
|
| |
Remove all `use` statements for `TryFrom` and `TryInto`. These are
now redundant in Rust 2021.
|
| | |
|
| |
|
|
|
|
|
|
| |
This commit uses the `visibility` and `visible` crates to
conditionally make certain structs and their fields public
(respectively). This is incredibly dangerous to use for anything
besides testing, and I've tried to write the documentation for the
feature accordingly.
|
| | |
|
| |\
| |
| |
| |
| |
| |
| | |
Don't use SystemTime::now()
Closes #306
See merge request tpo/core/arti!365
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| | |
Now we use NetParams. That implies making its constructor public,
which I think it fine.
This is related to #413 but is far from completing that ticket.
|
| | |
| |
| |
| |
| |
| |
| | |
The match was doing a deref coercion.
Found by current nightly's needless_match (whose suggestion doesn't
compile, https://github.com/rust-lang/rust-clippy/issues/8551 )
|