mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-09-19 20:46:21 +02:00
prop350: Stop accepting CREATE and EXTEND.
This commit is contained in:
parent
ef05979587
commit
a696559d78
@ -331,6 +331,14 @@ command_process_create_cell(cell_t *cell, channel_t *chan)
|
||||
return;
|
||||
}
|
||||
|
||||
/* We no longer accept TAP, for any reason. */
|
||||
if (create_cell->handshake_type == ONION_HANDSHAKE_TYPE_TAP) {
|
||||
tor_free(create_cell);
|
||||
/* TODO: Should we collect statistics here? Should we log? */
|
||||
circuit_mark_for_close(TO_CIRCUIT(circ), END_CIRC_REASON_TORPROTOCOL);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Mark whether this circuit used TAP in case we need to use this
|
||||
* information for onion service statistics later on. */
|
||||
if (create_cell->handshake_type == ONION_HANDSHAKE_TYPE_FAST ||
|
||||
|
@ -443,6 +443,12 @@ circuit_extend(struct cell_t *cell, struct circuit_t *circ)
|
||||
|
||||
relay_header_unpack(&rh, cell->payload);
|
||||
|
||||
/* We no longer accept EXTEND messages; only EXTEND2. */
|
||||
if (rh.command == RELAY_COMMAND_EXTEND) {
|
||||
/* TODO: Should we log this? */
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (extend_cell_parse(&ec, rh.command,
|
||||
cell->payload+RELAY_HEADER_SIZE,
|
||||
rh.length) < 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user