| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
and propagate to other affected crates
|
| | |
|
| |
|
|
|
|
|
|
| |
This change was a bit annoying, since most of this code _can't_ fail,
and so the only reasonable response is to wrap the input in an
internal error... except for one case where we're actually encoding
a caller-provided message, so we _do_ want to wrap the EncodeError
from tor_bytes.
|
| | |
|
| |
|
|
|
|
| |
There were only a few of these. Removing it required porting
everything to use `write_and_consume` instead, and handling its
(potential) errors.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This comprises four renames:
```
write_onto -> write_onto_infallible
write_into -> write_into_infallible
write -> write_infallible
writer_and_consume -> write_and_consume_infallible.
```
The rest of this branch will be concerned with replacing these
`_infallible` methods with ones that return a `Result`. This is
part of #513.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This implements a higher-level API for the ntor v3 handshake, in line
with that exposed by the ntor handshake. It does not, however, use the
existing `ClientHandshake` trait, due to fundamental differences in the
handshakes (namely, that the v3 handshake can include some additional
extra extension data).
Currently, the higher-level API assumes circuit extension, and copies
the (undocumented!) magic verification string from c-tor that indicates
this usage.
A rudimentary set of functions for serializing and deserializing
extensions to be sent with the handshake is also included, implementing
the protocol in proposal 332 § A.2. Currently, it only implements the
congestion control extensions specified in proposal 324 § 10.3.
part of arti#88
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
- arti#448 and arti!607 highlight an issue with upgrading `rsa`: namely,
the `x25519-dalek` version previously used has a hard dependency on
`zeroize` 1.3, which creates a dependency conflict.
- However, `x25519-dalek` version `2.0.0-pre.1` relaxes this dependency.
Reviewing the changelogs, it doesn't look like that version is
substantially different from the current one at all, so it should be
safe to use despite the "prerelease" tag.
- The new `x25519-dalek` version also bumps `rand_core`, which means we
don't have to use the RNG compat wrapper in `tor-llcrypto` as much.
closes arti#448
|
| |\
| |
| |
| |
| | |
Fix clippy nightly again
See merge request tpo/core/arti!603
|
| | |
| |
| |
| |
| |
| | |
Found these by disabling the nightly dbg macro special case. Now, we
have a mechanism for globally adding suppressions to tests, we can use
that instead.
|
| | |
| |
| |
| | |
Update all lint blocks
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
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.
|
| | |
| |
| |
| |
| |
| | |
Failing to encode is fundamentally different from failing to
decode. We now treat those separately, and describe _what_ we failed
to encode or decode.
|
| |/
|
|
|
| |
This avoids adding additional information for now; that will come on
the next commits.
|
| |\
| |
| |
| |
| | |
Do not include error source() in display() format.
See merge request tpo/core/arti!598
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
According to doc/Errors.md, and in keeping with current best
practices, we should not include display an error's `source()` as
part of that error's display method. Instead, we should let the
caller decide to call source() and display that error in turn.
Part of #323.
|
| | |
| |
| |
| | |
Consequential ordering changes.
|
| | |
| |
| |
| |
| |
| |
| | |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/586#note_2814276
Change names and comments and docs everywhere.
|
| | |
| |
| |
| |
| | |
Addresses
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/586#note_2813567
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| | |
Prompted by
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/586#note_2813565
|
| | | |
|
| | | |
|
| | |
| |
| |
| | |
Nothing geenrates config updates yet.
|
| | |
| |
| |
| | |
Nothing calls this yet.
|
| | |
| |
| |
| | |
It turns out that we are going to want this.
|
| | |
| |
| |
| |
| | |
We're about to split the main new() function off so write a separate
test for new_disabled().
|
| |/
|
|
| |
chanmgr is going to want to make one of these from a NetDir.
|
| |\
| |
| |
| |
| | |
Use impl_standard_builder more and remove manual Default/builder impls
See merge request tpo/core/arti!594
|
| | | |
|
| |/
|
|
|
| |
There is not, apparently, an eprintln equivalent for
allow-dbg-in-tests.
|
| |\
| |
| |
| |
| | |
Have channel reactor able to send channel padding
See merge request tpo/core/arti!574
|
| | | |
|
| | |
| |
| |
| | |
There aren't very many.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| |/ |
|
| |\
| |
| |
| |
| | |
Plumb a SleepProvider (now Clone + ....) into Channel
See merge request tpo/core/arti!569
|
| | |
| |
| |
| |
| | |
The channel reactor is going to want to be able to sleep so that it
can do padding, so it needs a SleepProvider.
|
| |\ \
| |/
|/| |
|
| | |
| |
| |
| |
| |
| | |
This only affects uses of thread_rng(), and affects them all more or
less indiscriminately. One test does not work with
ARTI_TEST_PRNG=deterministic; the next commit will fix it.
|
| |\ \
| |/
|/|
| |
| |
| |
| | |
lints: Make lint blocks consistent and ensure they stay that way
Closes #469
See merge request tpo/core/arti!557
|
| | |
| |
| |
| |
| |
| | |
This was the result of:
maint/add_warning crates/*/src/{lib,main}.rs
and then manually curating the results.
|