aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-chanmgr/src
Commit message (Collapse)AuthorAgeFilesLines
...
* tor-chanmgr: fix type inference in handshakeNihal2026-03-182-6/+6
|
* tor-chanmgr: refactor handshake into helper functionsNihal2026-03-181-30/+53
|
* tor-chanmgr: implement HTTP CONNECT proxy handshake and wire transportNihal2026-03-182-20/+186
|
* tor-chanmgr: add ProxyProtocol::HttpConnect variant and URI parsingNihal2026-03-181-36/+205
|
* Merge branch 'cargo-update' into 'main'gabi-2502026-03-041-0/+1
|\ | | | | | | | | Run cargo update post-release See merge request tpo/core/arti!3740
| * rtmock, chanmgr: Allow use of deprecated try_next() in testsGabriela Moldovan2026-03-031-0/+1
| | | | | | | | | | | | | | | | futures 0.3.32 has deprecated UnboundedReceiver::try_next() in favor of UnboundedReceiver::try_recv(), but try_recv() was only introduced in 0.3.32, so using it would cause our minimal versions checks to fail (rightfully so, because our code wouldn't build with futures 0.3.x for x < 32).
* | tor-proto: send an AUTH_CHALLENGE during testsSteven Engler2026-03-031-0/+5
|/ | | | | | | As far as I know, a responder will always send an AUTH_CHALLENGE cell since it doesn't yet know if the initiator is a client or relay. The spec also doesn't have any mention about the AUTH_CHALLENGE being optional. So we should send it in our tests as well.
* safelog: Rename MaybeSensitive::hidden/visible()David Goulet2026-03-031-3/+4
| | | | | | Rename them to respectively sensitive() and not_sensitive(). Signed-off-by: David Goulet <[email protected]>
* chanmgr: Safely log the peer in the channel builderDavid Goulet2026-03-032-18/+24
| | | | | | | | | On I/O error, we safely log the peer address that was used that lead to this error. Closes #2375 Signed-off-by: David Goulet <[email protected]>
* proto: Make channel PeerAddr sensitiveDavid Goulet2026-03-031-1/+6
| | | | | | | Only the R2R channel that the PeerAddr becomes unsensitive. The rest, we keep it sensitive as it can be a client or a client's guard/bridge. Signed-off-by: David Goulet <[email protected]>
* chanmgr: Rename function parameterDavid Goulet2026-02-261-3/+3
| | | | | | | It was _target before because we had it in the function with a cfg_if!(). Now don't so no need. Signed-off-by: David Goulet <[email protected]>
* chanmgr: The validate_relay_target() had its logic inversedDavid Goulet2026-02-261-4/+6
| | | | Signed-off-by: David Goulet <[email protected]>
* tor-proto: change channel selection fns to take `HasChanMethod`Steven Engler2026-02-252-13/+15
|
* Merge branch 'chanbuilder-my-addrs' into 'main'David Goulet2026-02-246-26/+41
|\ | | | | | | | | chanmgr: Store our relay addresses in the builder See merge request tpo/core/arti!3716
| * chanmgr: Responder relay channel now use the builder my_addrsDavid Goulet2026-02-246-21/+11
| | | | | | | | | | | | No need to pass from the arti relay binary our addresses when handling an incoming channel, use the one in the channel builder that an initiator channel uses.
| * chanmgr: Store our relay addresses in the builderDavid Goulet2026-02-243-5/+30
| | | | | | | | | | | | | | | | | | | | We need those addresses when we build a relay channel in order to send them into our NETINFO cell. This adds the `with_my_addrs()` on the `ChanMgrConfig` object. Next commit will make arti-relay use it. Signed-off-by: David Goulet <[email protected]>
* | chanmgr: Don't allow to build relay channel to ourselfDavid Goulet2026-02-241-3/+33
|/ | | | | | | | | | The validate_relay_target() is meant to probably have more checks in the future hence the vagueness of it instead of being specific to the goal of this patch. Closes #1699 Signed-off-by: David Goulet <[email protected]>
* chanmgr: Add a set_relay_identities() to update the RelayIdentitiesDavid Goulet2026-02-245-2/+42
| | | | | | | | | | The arti-relay crate rotates the keys at regular interval which we need to give to the ChanMgr to update its builder. This function boldly replace the default factory with the new identities including the TLS acceptor can pick up the new key. Signed-off-by: David Goulet <[email protected]>
* proto: Modify RelayIdentities to have encodable certDavid Goulet2026-02-231-1/+1
| | | | | | | This commit also adds the TlsKeyAndCert to the identities so the TLS acceptor can set it up. Signed-off-by: David Goulet <[email protected]>
* Merge branch 'config-migrate-part1' into 'main'gabi-2502026-02-201-13/+13
|\ | | | | | | | | Port several crates to derive_deftly(TorConfig) See merge request tpo/core/arti!3691
| * chanmgr: migrate to derive_deftly(TorConfig)Nick Mathewson2026-02-171-13/+13
| |
* | proto: Pass PeerAddr at the channel handshake finish for initiatorsDavid Goulet2026-02-191-4/+2
| | | | | | | | | | | | | | | | | | | | Responder relay handshake requires the peer address at the very start as it sends its NETINFO right away. For initiators, we only need it during the finalization process which is when the NETINFO is sent and the Channel is created. Signed-off-by: David Goulet <[email protected]>
* | chanmgr: Add a TODO() for logging PeerAddr instaed of ChanTargetDavid Goulet2026-02-191-0/+4
| | | | | | | | Signed-off-by: David Goulet <[email protected]>
* | chanmgr: Fix channel builder commentDavid Goulet2026-02-191-6/+1
| | | | | | | | Signed-off-by: David Goulet <[email protected]>
* | proto: Use the PeerAddr accross channel handshakeDavid Goulet2026-02-194-43/+38
| | | | | | | | | | | | | | This is a large change but it is basically using PeerAddr in the channel builder through the channel handshake code and into the Channel itself. Signed-off-by: David Goulet <[email protected]>
* | proto: Remove unused ChannelBuilderDavid Goulet2026-02-191-2/+1
|/ | | | Signed-off-by: David Goulet <[email protected]>
* Merge branch 'mr_3616_rebased' into 'main'Nick Mathewson2026-02-165-17/+502
|\ | | | | | | | | | | | | Mr 3616 rebased Closes #1800 See merge request tpo/core/arti!3681
| * tor-chanmgr: minor chore adjustments for CINihal2026-02-161-4/+5
| |
| * tor-chanmgr: Use url crate userinfo encodingNihal2026-02-161-36/+51
| |
| * tor-chanmgr: use url crate for proxy URIs and error for socks4 passwordsNihal2026-02-161-44/+62
| |
| * tor-chanmgr: allow option_option for outbound proxy deserializerNihal2026-02-161-0/+1
| |
| * tor-chanmgr: fix outbound_proxy deserialization for builderNihal2026-02-161-3/+6
| |
| * tor-chanmgr: fix builder serde attrNihal2026-02-161-1/+1
| |
| * tor-chanmgr: fix proxy config parsing and clippy lintNihal2026-02-162-1/+23
| |
| * deps: add percent_encoding and remove serdeNihal2026-02-161-1/+1
| |
| * tor-chanmgr: improve ProxyProtocol documentationNihal2026-02-161-42/+159
| |
| * tor-chanmgr: remove SocketAddr and improve errorNihal2026-02-162-22/+15
| |
| * tor-chanmgr: add URI-style parsing for ProxyProtocol outbound_proxy configNihal2026-02-163-10/+263
| |
| * tor-chanmgr: integrate outbound proxy into DefaultTransportNihal2026-02-163-15/+41
| |
| * tor-chanmgr: add From<ProxyError> for io::Error conversionNihal2026-02-161-0/+6
| |
| * tor-chanmgr: add ProxyProtocol config type for outbound proxyNihal2026-02-161-0/+30
| |
* | Merge branch 'msrv-1.89' into 'main'Nick Mathewson2026-02-161-0/+1
|\ \ | | | | | | | | | | | | Bump MSRV to 1.89 See merge request tpo/core/arti!3684
| * | Allow clippy::collapsible_if to triggerGabriela Moldovan2026-02-161-0/+1
| |/ | | | | | | | | | | | | | | | | `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.
* | Merge branch 'relay-own-cert' into 'main'David Goulet2026-02-161-1/+6
|\ \ | | | | | | | | | | | | relay: Pass our TLS cert to the responder verify process See merge request tpo/core/arti!3665
| * | relay: Pass our TLS cert to the responder verify processDavid Goulet2026-02-121-1/+6
| |/ | | | | | | | | | | | | | | | | | | For the responder to build the authentication data, it needs its own certificate of the TLS handshake that it is responding to (as a TLS server). This resolves an important TODO(relay) in the code. Signed-off-by: David Goulet <[email protected]>
* | Merge branch 'chan-target-addr' into 'main'David Goulet2026-02-162-2/+33
|\ \ | |/ |/| | | | | | | | | tor-chanmgr: Add additional `get_or_launch()` tests and update doc comment Closes #2344 See merge request tpo/core/arti!3676
| * tor-chanmgr: add doc comment to `ChanMgr::get_or_launch()`Steven Engler2026-02-121-0/+6
| |
| * tor-chanmgr: add `get_or_launch()` tests using different addrsSteven Engler2026-02-121-2/+27
| | | | | | | | | | When there are two channel requests with the same identities and different socket addresses, we return the same channel.
* | Merge branch 'channel-canonical' into 'main'David Goulet2026-02-124-19/+71
|\ \ | |/ |/| | | | | Implement channel canonicity See merge request tpo/core/arti!3668
| * chan: Use Canonicity when choosing a channelDavid Goulet2026-02-124-3/+49
| | | | | | | | Signed-off-by: David Goulet <[email protected]>