| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Closes #2617.
We've lucked out this time, and it turns out that every one of our
published crates gets a minor bump. So this was generated with:
```
for cr in $(./maint/list-crates); do
cargo set-version -p $cr --bump minor
done
```
|
| |
|
|
|
| |
We don't use this anymore, and it can lead to subtle bugs since we lose
the original channel message command.
|
| |\
| |
| |
| |
| | |
Bump MSRV to 1.91
See merge request tpo/core/arti!4105
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This commit bumps the MSRV to 1.91 which was released on 2025-10-30.
The Cargo.toml files were updated as follows:
```sh
git ls-files | \
grep ".*Cargo\.toml$" | \
xargs sed -i '' 's/^rust-version = "1\.89"$/rust-version = "1\.91"/g'
```
The following files were updated manually:
```
modified: .gitlab-ci.yml
modified: README.md
modified: flake.nix
modified: maint/docker-android/Dockerfile
```
|
| |\ \
| |/
|/|
| |
| | |
tor-proto: Add unit test for `XonXoffReader`
See merge request tpo/core/arti!4093
|
| | | |
|
| |/
|
|
|
|
|
| |
The spec was recently updated in [1],
so we should make this clearer in our code comments.
[1]: https://gitlab.torproject.org/tpo/core/torspec/-/merge_requests/490
|
| |\
| |
| |
| |
| | |
Lint for clippy::string_slice
See merge request tpo/core/arti!4086
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This commit executes maint/add_warning with the just added change to
deny string slices except in tests.
I recommend auditing this by checking out the previous commit followed
by running the script yourself and then verifying that the diff is
identical to this commit.
This commit makes cargo clippy fail. We will add exceptions in the next
commit.
|
| |/
|
|
| |
New beta semver policy means we should pin the patchlevel.
|
| |
|
|
|
|
|
|
|
|
| |
Done using:
```
for crate in $(./maint/list-crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.43.0
done
```
|
| |
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
cargo set-version -p arti-client 0.42.0
cargo set-version -p arti-config 0.42.0
cargo set-version -p arti-relay 0.42.0
cargo set-version -p arti-rpc-client-core 0.42.0
cargo set-version -p arti-rpcserver 0.42.0
cargo set-version -p arti-testing 0.42.0
cargo set-version -p arti-ureq 0.42.0
cargo set-version -p tor-async-utils 0.42.0
cargo set-version -p tor-basic-utils 0.42.0
cargo set-version -p tor-bytes 0.42.0
cargo set-version -p tor-cell 0.42.0
cargo set-version -p tor-cert 0.42.0
cargo set-version -p tor-cert-x509 0.42.0
cargo set-version -p tor-chanmgr 0.42.0
cargo set-version -p tor-checkable 0.42.0
cargo set-version -p tor-circmgr 0.42.0
cargo set-version -p tor-config 0.42.0
cargo set-version -p tor-config-path 0.42.0
cargo set-version -p tor-consdiff 0.42.0
cargo set-version -p tor-dirclient 0.42.0
cargo set-version -p tor-dircommon 0.42.0
cargo set-version -p tor-dirmgr 0.42.0
cargo set-version -p tor-dirserver 0.42.0
cargo set-version -p tor-error 0.42.0
cargo set-version -p tor-events 0.42.0
cargo set-version -p tor-general-addr 0.42.0
cargo set-version -p tor-geoip 0.42.0
cargo set-version -p tor-guardmgr 0.42.0
cargo set-version -p tor-hsclient 0.42.0
cargo set-version -p tor-hscrypto 0.42.0
cargo set-version -p tor-hsrproxy 0.42.0
cargo set-version -p tor-hsservice 0.42.0
cargo set-version -p tor-key-forge 0.42.0
cargo set-version -p tor-keymgr 0.42.0
cargo set-version -p tor-linkspec 0.42.0
cargo set-version -p tor-llcrypto 0.42.0
cargo set-version -p tor-log-ratelim 0.42.0
cargo set-version -p tor-memquota 0.42.0
cargo set-version -p tor-memquota-cost 0.42.0
cargo set-version -p tor-netdir 0.42.0
cargo set-version -p tor-netdoc 0.42.0
cargo set-version -p tor-persist 0.42.0
cargo set-version -p tor-proto 0.42.0
cargo set-version -p tor-protover 0.42.0
cargo set-version -p tor-ptmgr 0.42.0
cargo set-version -p tor-relay-crypto 0.42.0
cargo set-version -p tor-relay-selection 0.42.0
cargo set-version -p tor-rpcbase 0.42.0
cargo set-version -p tor-rpc-connect 0.42.0
cargo set-version -p tor-rtcompat 0.42.0
cargo set-version -p tor-rtmock 0.42.0
cargo set-version -p tor-socksproto 0.42.0
cargo set-version -p tor-units 0.42.0
|
| |
|
|
| |
This was experimental. Everything gated by it has been stabilised.
|
| | |
|
| |\
| |
| |
| |
| | |
Address post-merge comments from nickm's review in mr 3791
See merge request tpo/core/arti!3802
|
| | |
| |
| |
| |
| |
| |
| | |
We use this constant value when building the AUTHENTICATE cell to
optimize the memory allocation as this won't ever change.
Signed-off-by: David Goulet <[email protected]>
|
| | |
| |
| |
| | |
There are no breaking changes.
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As per
https://gitlab.torproject.org/tpo/core/arti/-/issues/2436#note_3384773
Made with
nailing-cargo -Eu set-version -p arti-client 0.41.0
nailing-cargo -Eu set-version -p arti-relay 0.41.0
nailing-cargo -Eu set-version -p arti-rpcserver 0.41.0
nailing-cargo -Eu set-version -p arti-ureq 0.41.0
nailing-cargo -Eu set-version -p arti-rpc-client-core 0.41.0
nailing-cargo -Eu set-version -p tor-basic-utils 0.41.0
nailing-cargo -Eu set-version -p tor-error 0.41.0
nailing-cargo -Eu set-version -p tor-general-addr 0.41.0
nailing-cargo -Eu set-version -p tor-geoip 0.41.0
nailing-cargo -Eu set-version -p tor-memquota-cost 0.41.0
nailing-cargo -Eu set-version -p tor-llcrypto 0.41.0
nailing-cargo -Eu set-version -p tor-cert-x509 0.41.0
nailing-cargo -Eu set-version -p tor-rtcompat 0.41.0
nailing-cargo -Eu set-version -p tor-rtmock 0.41.0
nailing-cargo -Eu set-version -p tor-async-utils 0.41.0
nailing-cargo -Eu set-version -p tor-config 0.41.0
nailing-cargo -Eu set-version -p tor-config-path 0.41.0
nailing-cargo -Eu set-version -p tor-rpc-connect 0.41.0
nailing-cargo -Eu set-version -p tor-log-ratelim 0.41.0
nailing-cargo -Eu set-version -p tor-rpcbase 0.41.0
nailing-cargo -Eu set-version -p tor-memquota 0.41.0
nailing-cargo -Eu set-version -p tor-units 0.41.0
nailing-cargo -Eu set-version -p tor-bytes 0.41.0
nailing-cargo -Eu set-version -p tor-protover 0.41.0
nailing-cargo -Eu set-version -p tor-checkable 0.41.0
nailing-cargo -Eu set-version -p tor-cert 0.41.0
nailing-cargo -Eu set-version -p tor-key-forge 0.41.0
nailing-cargo -Eu set-version -p tor-hscrypto 0.41.0
nailing-cargo -Eu set-version -p tor-socksproto 0.41.0
nailing-cargo -Eu set-version -p tor-linkspec 0.41.0
nailing-cargo -Eu set-version -p tor-cell 0.41.0
nailing-cargo -Eu set-version -p tor-persist 0.41.0
nailing-cargo -Eu set-version -p tor-keymgr 0.41.0
nailing-cargo -Eu set-version -p tor-relay-crypto 0.41.0
nailing-cargo -Eu set-version -p tor-proto 0.41.0
nailing-cargo -Eu set-version -p tor-netdoc 0.41.0
nailing-cargo -Eu set-version -p tor-consdiff 0.41.0
nailing-cargo -Eu set-version -p tor-netdir 0.41.0
nailing-cargo -Eu set-version -p tor-relay-selection 0.41.0
nailing-cargo -Eu set-version -p tor-chanmgr 0.41.0
nailing-cargo -Eu set-version -p tor-ptmgr 0.41.0
nailing-cargo -Eu set-version -p tor-dircommon 0.41.0
nailing-cargo -Eu set-version -p tor-guardmgr 0.41.0
nailing-cargo -Eu set-version -p tor-circmgr 0.41.0
nailing-cargo -Eu set-version -p tor-dirclient 0.41.0
nailing-cargo -Eu set-version -p tor-dirmgr 0.41.0
nailing-cargo -Eu set-version -p tor-dirserver 0.41.0
nailing-cargo -Eu set-version -p tor-hsclient 0.41.0
nailing-cargo -Eu set-version -p tor-hsservice 0.41.0
nailing-cargo -Eu set-version -p tor-hsrproxy 0.41.0
|
| | |
|
| |\
| |
| |
| |
| | |
cell, proto, cert: Simplify CERTS cell building.
See merge request tpo/core/arti!3795
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| | |
Formerly we required the caller for push_cert_body to specify the
type of the cert that they were pushing. But in nearly every case,
the certificate object that the caller is holding knows what its
own type is! This makes the tor_proto build_certs_cell function
a bit less error-prone, since we don't have to worry about mismatch.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
As a responder, we should check the AUTHENTICATE auth type and make sure
we support it. We were not doing that, we were simply putting in our max
version.
Signed-off-by: David Goulet <[email protected]>
|
| | |
| |
| |
| |
| |
| | |
Proper error to use and better code to use checked_sub().
Signed-off-by: David Goulet <[email protected]>
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Remove the is_equal_no_sig() and instead add a getter that returns a
reference to the body without the random part so it can be used to
verify the signature.
The caller now checks the equality with what it is expected.
Signed-off-by: David Goulet <[email protected]>
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This fixes two things.
1. The "is_equal_no_sig()", if true, was going into the error path.
2. The signature verification is done against the body of the
AUTHENTICATE cell that is all fields except the signature.
Next commit will change the is_equal_no_sig() to make more sense with
the "body" semantic.
Signed-off-by: David Goulet <[email protected]>
|
| |/
|
|
|
|
|
|
| |
It is now validated against the received KP_link_ed of the initiator
peer and we compare only the section of the AUTHENTICATE cell that we
can compare (minus random bytes and sig).
Signed-off-by: David Goulet <[email protected]>
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
| |
Done using:
```
for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.40.0
done
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The non-{arti-,tor-} crates are:
```
./maint/list-crates | rg -v '^(tor|arti)'
oneshot-fused-workaround
slotmap-careful
test-temp-dir
fslock-guard
hashx
equix
caret
fs-mistrust
safelog
retry-error
futures-copy
```
Because this release bumps the MSRV, I am bumping the minor version of all of
them.
MINOR="
oneshot-fused-workaround
slotmap-careful
test-temp-dir
fslock-guard
hashx
equix
caret
fs-mistrust
safelog
retry-error
futures-copy
"
for crate in $MINOR; do
cargo set-version --bump minor -p $crate;
done
```
|
| |
|
|
|
|
|
|
|
| |
`clippy::collapsible_if` started triggering after bumping the MSRV to
1.88.
Since this triggers from a lot of places, and since there even are a
couple of instances where we explicitly allow `clippy::collapsible_ifs`,
I've opened #2342 for deciding what to do about it.
|
| |
|
|
|
|
|
| |
As agreed at our last team meeting.
See
https://gitlab.torproject.org/tpo/core/arti/#minimum-supported-rust-version
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This struct will be put in a Channel and derived from the received
NETINFO cell.
This follows the C-tor implementation for which we have two indicator of
canonicity:
1. Peer is canonical: the address they advertise in the NETINFO cell
matches the one we see on the TCP connection.
2. Canonical to peer: the peer sees us as canonical.
Those flag will get used to select "the best" channel.
Signed-off-by: David Goulet <[email protected]>
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
Done via:
```
for crate in $(./maint/list-crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.39.0
done
```
|
| |\
| |
| |
| |
| | |
fix(minver): Update paste dependency to be minver compatible
See merge request tpo/core/arti!3610
|
| | | |
|
| |/
|
|
| |
This adds the lint to all our crates.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit is a bit loaded but it is coherent.
First, we set Eq and PartialEq to the channel message Authenticate so we
can compare it with the one we expected.
Second, the AuthenticationCell enum is introduced to store either an
AUTH_CHALLENGE or an AUTHENTICATE since one side of the handshake can
only have one. This allows us to store one or the other in
UnverifiedRelayChannel.
Depending on what we have, the authentication process is different as it
dictates which side we are on (initiator vs responder). Keep in mind
that the handshake code enforces receiving a AUTH_CHALLENGE along side
CERTS. And same goes for AUTHENTICATE which means that if we have an
AUTH_CHALLENGE in the UnverifiedRelayChannel, it is certain that the
other side wants to authenticate and we are the initiator.
Finally, the sending of CERTS and AUTHENTICATE by the initiator is now
in UnverifiedRelayChannel::check() done right after verifying the
channel CERTS and holding a "VerifiedChannel" object.
This means that the last piece, sending the `NETINFO` by the initiator
will be done in the check() but in a future commit. This leaves the
VerifiableChannel::finish() to send nothing and only finalize the
channel with the NETINFO (canonicity).
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
|
|
| |
Done using the following:
```bash
for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.38.0
done
```
|
| |
|
|
|
|
|
|
|
| |
Fixes part of #2193.
(Edits from nickm: I selected the cases here that I could verify
were correct from immediate context.)
Edited-by: Nick Mathewson <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
| |
We are supposed to pin whenever we enable the `beta` cargo feature,
see
https://docs.rs/derive-deftly/latest/derive_deftly/doc_changelog/index.html#beta-features
Empirically, we somehow failed to do that in tor-circmgr.
In practice not pinning makes little difference since cargo wants to
pick the same version everywhere, but we should be correct. But it is
more maintainable to pin everywhere.
|
| |
|
|
|
|
|
|
|
| |
This has:
* Fixes to hygiene spans from the new modules feature, needed for
my WIP netdoc encoder derive.
* A substantially richer `${error }` construct.
|
| |
|
|
|
|
|
|
|
| |
Done using:
```
for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do
cargo set-version -p $crate 0.37.0
done
|
| | |
|
| |\
| |
| |
| |
| |
| |
| | |
tor-llcrypto: Stop deriving Deref in CtByteArray
Closes #2172
See merge request tpo/core/arti!3432
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| | |
This has the meta attributes with optional values feature and also
hygiene rework for modules.
The breaking changes don't break arti.
|