aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-proto/src/channel/msg.rs
Commit message (Collapse)AuthorAgeFilesLines
* Fix typosTobias Stoeckmann2026-03-241-1/+1
| | | | Typos found with codespell
* proto: Add 'CreateFast/CreatedFast' to relay message filterSteven Engler2026-02-261-0/+4
|
* proto: Use the channel codec channel typeDavid Goulet2026-01-221-0/+10
| | | | | | | | | | | | | | | | | 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 <[email protected]>
* proto: Allow padding in all channel message setsDavid Goulet2025-08-211-3/+13
| | | | | | | | | | | | | | First of all, VPADDING has been added in link protocol version 3 so it was missing from v4. Second, after closely looking at C-tor and the spec, it appears that we allow VPADDING at any point on a channel which should simply be silently dropped. Any number in any order. Third, couple sets were missing the PADDING cell which is only allowed on an open channel. Signed-off-by: David Goulet <[email protected]>
* tor-proto: simplify some match statementsSteven Engler2025-08-201-46/+26
|
* proto: Change (crate) to (super) for all objects in msg.rsDavid Goulet2025-08-201-25/+25
| | | | Signed-off-by: David Goulet <[email protected]>
* proto: Cleanup allow(unused)David Goulet2025-08-201-2/+0
| | | | Signed-off-by: David Goulet <[email protected]>
* proto: Add message filtering to restricted message setsDavid Goulet2025-08-201-2/+361
| | | | | | | | | | | | | | | | | This adds the code in msg.rs to be able to filter an inbound or outbound message on a channel. Each link protocol version implement a "is_allowed()" which is quite verbose and tests each possibilities for human readability. Then, we have several small struct/enum that are used to describe how a message is filtered. It is still unused at this commit. Part of #1597 Signed-off-by: David Goulet <[email protected]>
* proto: Add restricted channel message setsDavid Goulet2025-08-201-0/+207
Add the msg.rs file containing all the allowed message sets based on the channel type and direction. They are also namespaced by link protocol version. Unused at this commit. They will be used by the channel reactor along the channel type and link protocol version in order to know if the message is allowed or not. See is_allowed() helper function in this commit. Part of #1597 Signed-off-by: David Goulet <[email protected]>