tor

The Tor anonymity network
git clone https://git.dasho.dev/tor.git
Log | Files | Refs | README | LICENSE

commit 63332eb3e711786f97621d03ab1989d67fad4820
parent 8a7ade95b64407fe29350f96def8782d049f4ddd
Author: Nick Mathewson <nickm@torproject.org>
Date:   Mon, 15 Sep 2025 09:20:15 -0400

Set is_relay_early to false when encoding relay msgs.

Spotted by Alex Xu.

Fixes #41123; bug not in any released Tor.

Diffstat:
Msrc/core/or/relay.c | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/core/or/relay.c b/src/core/or/relay.c @@ -626,6 +626,9 @@ relay_send_command_from_edge_,(streamid_t stream_id, circuit_t *orig_circ, msg.length = payload_len; msg.body = (const uint8_t *) payload; msg_body_len = msg.length; + // If this cell should be RELAY_EARLY, we'll change the type + // later in this function. + msg.is_relay_early = false; if (relay_msg_encode_cell(cell_format, &msg, &cell) < 0) { // We already called IF_BUG_ONCE in relay_msg_encode_cell.