<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/arti.git/crates/tor-proto/src/channel/handler.rs, branch arti-v1.9.0</title>
<subtitle>mirror of https://gitlab.torproject.org/tpo/core/arti
</subtitle>
<id>http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v1.9.0</id>
<link rel='self' href='http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v1.9.0'/>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/'/>
<updated>2025-08-27T15:04:24Z</updated>
<entry>
<title>proto: Only allow VERSIONS cell for the new handshake state</title>
<updated>2025-08-27T15:04:24Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2025-08-26T17:03:34Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=afe97476d39bfb3db7387ed073e4bad350ea3c7e'/>
<id>urn:sha1:afe97476d39bfb3db7387ed073e4bad350ea3c7e</id>
<content type='text'>
Due to this, it is not possible to get a VPADDING before because it
requires a link protocol version to decideon the encoding:

https://gitlab.torproject.org/tpo/core/torspec/-/issues/366

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Remove the AUTHORIZE as a parsable cell</title>
<updated>2025-08-21T15:59:37Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2025-08-21T14:52:35Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=eabd0c0bfe703337e338403949721ce57c87f32e'/>
<id>urn:sha1:eabd0c0bfe703337e338403949721ce57c87f32e</id>
<content type='text'>
The AUTHORIZE cell command is simply reserved but not defined. The tor
specification, at this point in time, is allowing such cell before the
handshake starts but it is very unclear on what ordering is allowed nor
how many can are allowed.

C-tor silents drop them like VPADDING and so clearly unused. Instead of
dealing with it, simply remove its support but keeping its reserved
number.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Add a channel handler comment and a fix</title>
<updated>2025-08-21T15:07:32Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2025-08-20T19:52:31Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=f6f3c99c4e530a688bd99eeec5323bb1ceb15df1'/>
<id>urn:sha1:f6f3c99c4e530a688bd99eeec5323bb1ceb15df1</id>
<content type='text'>
Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Return AUTHORIZE, VPADDING and VERSIONS at handshake</title>
<updated>2025-08-21T15:07:32Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2025-08-20T19:46:47Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=b758a3e844cdec9d78dc02237bb99d534ab1bfb7'/>
<id>urn:sha1:b758a3e844cdec9d78dc02237bb99d534ab1bfb7</id>
<content type='text'>
When starting a handshake, we were only expecting a VERSIONS which is
not what the protocol say. An AUTHORIZE and VPADDING can arrive before a
VERSIONS.

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Cleanup allow(unused)</title>
<updated>2025-08-20T17:22:16Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2025-08-14T14:08:49Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=6d037f809446d624e63888f4ceb00041cf2671eb'/>
<id>urn:sha1:6d037f809446d624e63888f4ceb00041cf2671eb</id>
<content type='text'>
Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Unit tests for channel handler</title>
<updated>2025-08-20T17:22:16Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2024-10-09T18:22:06Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=41a2b3d07176f38bc1174dae1abcf8aa9b5aa5e6'/>
<id>urn:sha1:41a2b3d07176f38bc1174dae1abcf8aa9b5aa5e6</id>
<content type='text'>
Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Make the OutboundClientHandshake use new cell handler</title>
<updated>2025-08-20T17:22:16Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2024-10-03T13:16:08Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=8d52396e8f6e68859508e1f8fbef7a62458857bc'/>
<id>urn:sha1:8d52396e8f6e68859508e1f8fbef7a62458857bc</id>
<content type='text'>
Use the ChannelFrame&lt;&gt; for the entirety of the outbound client handshake
that is the ClientInitiator channel type.

With this change, the codec.rs code is not needed anymore along its
CodecError as well which has been normalized onto the crate::Error
instead in order to simplify error handling and avoid duplication of
error types.

Unit tests have been modified to reflect this change of what can be done
with a channel frame. Also renamed to focus on client behavior.

Part of #1597

Signed-off-by: David Goulet &lt;dgoulet@torproject.org&gt;
</content>
</entry>
<entry>
<title>proto: Add channel cell handler</title>
<updated>2025-08-20T17:22:16Z</updated>
<author>
<name>David Goulet</name>
<email>dgoulet@torproject.org</email>
</author>
<published>2024-10-01T17:48:00Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=26eb7fbd647f35f598de82e7b0cdf3f55214bd05'/>
<id>urn:sha1:26eb7fbd647f35f598de82e7b0cdf3f55214bd05</id>
<content type='text'>
The handler.rs file contains a generic "ChannelCellHandler" which is
split into three different handler depending of the channel state (new,
handshaking or open).

These handlers implement Encoder/Decoder so we can give a
ChannelCellHandler to a asynchronous_codec::Framed along a TLS stream.

That cell handler is also in charge of tracking the CLOG/SLOG (see
tor-spec), running digest of cells seen, which is used to authenticate a
channel for the Relay &lt;-&gt; Relay case.

This ChannelCellHandler auto transitions as the setters function are
used. The handshake code will use this to advance the handler. Each
handler uses a MessageFilter from msg.rs in order to allow or not to
return the message.

A keen eye will notice that we can avoid encoding a message if we don't
need but we will decode all possible messages and only then allow it or
not.

The channel cell handler is not used at this commit.

Part of #1597

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