<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/arti.git/crates/tor-proto/src/relay/channel/handshake.rs, branch arti-v2.0.0</title>
<subtitle>mirror of https://gitlab.torproject.org/tpo/core/arti
</subtitle>
<id>http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v2.0.0</id>
<link rel='self' href='http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v2.0.0'/>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/'/>
<updated>2026-01-22T16:16:44Z</updated>
<entry>
<title>proto: Enforce condition with type system</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-22T15:26:53Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=f07e83b2d321fcc9907413371298f683bed6ed51'/>
<id>urn:sha1:f07e83b2d321fcc9907413371298f683bed6ed51</id>
<content type='text'>
This commits returns either Some(AUTH_CELL, CERTS) or None. We future
proof ourselves against one Some and other None even if an error check
is done before.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Use the channel codec channel type</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-21T16:47:14Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=1da8fe2d546f2ad3693afeb5a13cb7b8a8ed0f13'/>
<id>urn:sha1:1da8fe2d546f2ad3693afeb5a13cb7b8a8ed0f13</id>
<content type='text'>
Remove the channel type from Unverified and Verified channels and
instead use the channel type in the underlying channel codec.

The codec requires such type in order to restrict messages sets. Instead
of duplicating it, this commit simply makes it that there is now only a
single channel type attached to a channel structure.

The resulting `struct Channel` in the end gets it copied from the
channel codec as the framed_tls gets split and given to the `Reactor`.

Down the line, we need a channel type attached to the `Channel` in order
to know if it is a client or not and authenticated or not.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Remove Option&lt;&gt; around peer_ip for build_netinfo_cell()</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-20T19:08:36Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=225918194c4938ff2717bac807296c1833817323'/>
<id>urn:sha1:225918194c4938ff2717bac807296c1833817323</id>
<content type='text'>
Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Avoid magic hardcoded value for LINK_AUTH</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-20T18:38:36Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=9299b9d4c2d100b4ef16b3035535b0ba2077eb49'/>
<id>urn:sha1:9299b9d4c2d100b4ef16b3035535b0ba2077eb49</id>
<content type='text'>
Instead, use the static AUTHTYPE_ED25519_SHA256_RFC5705 value which is
for now the only version we support.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Enforce CERTS and AUTHENTICATE are always expected together</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-20T18:34:11Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=92055192a0e33ac76d002d57f2e51bb173502bf5'/>
<id>urn:sha1:92055192a0e33ac76d002d57f2e51bb173502bf5</id>
<content type='text'>
A Responder receiving cells from the Initiator, if it gets a CERTS, an
AUTHENTICATE must also be present (and vice-versa).

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Send relay channel NETINFO in check()</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-15T16:40:38Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=038ffe345e14df3f76ed60315af00bf10b087859'/>
<id>urn:sha1:038ffe345e14df3f76ed60315af00bf10b087859</id>
<content type='text'>
Once channel is verified and authenticate if need be, send the NETINFO.
We require our advertised IP addresses for this so pass them to launch()
as well to the UnverifiedRelayChannel.

A cargo fmt change slipped in here, sorry about that.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Authenticate a relay channel</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-15T16:23:47Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=33e82e5a3a03e7d0a91d018b5e2d68edaf1c8441'/>
<id>urn:sha1:33e82e5a3a03e7d0a91d018b5e2d68edaf1c8441</id>
<content type='text'>
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 &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Add CertifiedConn to relay handshake</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-15T15:45:56Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=a91fd089f3a228b77b9698ea2df72dd426033550'/>
<id>urn:sha1:a91fd089f3a228b77b9698ea2df72dd426033550</id>
<content type='text'>
We need this trait for the underlying TLS stream in order to access data
such as the certificates or keying material.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Implement RelayResponderHandshake</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-14T20:13:59Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=0cfdd7c83ad9dd51c7bf34de7dd5fe6e3a4e04e1'/>
<id>urn:sha1:0cfdd7c83ad9dd51c7bf34de7dd5fe6e3a4e04e1</id>
<content type='text'>
This commit introduces the RelayResponderHandshake object used when
accepting an inbound connection to open a channel.

There are still TODOs pepperred in the code but the base is implemented.
The Unverified and Verified channel need to be adjusted for this new
handshake.

This will come in the next commits.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Make CERTS cell optionnable for UnverifiedChannel</title>
<updated>2026-01-22T16:16:44Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2026-01-14T15:44:26Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=0c5616e1fa0fd51b5bdbc3677ab260a1cbe2158b'/>
<id>urn:sha1:0c5616e1fa0fd51b5bdbc3677ab260a1cbe2158b</id>
<content type='text'>
This requires to make a series of cert and digest also optionnable in
the VerifiedChannel.

This change is needed because as a relay responder, you might get the
CERTS or not depending on if the other side wants to authenticate.
Client and bridges do not authenticate and thus it is expected to not
have a CERTS cell.

This leads to the UnverifiedChannel::check() function to return early
with a VerifiedChannel without any identity attached to it.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
</feed>
