Files
iroh/iroh-dns
Frando b831f4f5bf fix(iroh-dns): validate the response question against the query
The response parser only checked the transaction ID, the QR bit, the
presence of a question, and the RCODE. It then took the queried name
from the response's own question section, so a forged reply that guessed
the 16-bit ID and supplied its own question could have its answers
accepted for an arbitrary name. CNAME-following decisions were taken on
a packet whose ID was never verified, since only the final hop was
checked.

Validate every hop in send_query_following_cnames: check_response now
takes the queried name and type and rejects any response whose single
question does not echo them, alongside the existing ID, QR, and RCODE
checks. The parse_* functions become pure extractors that run on an
already-validated response, anchoring CNAME resolution on the verified
question.
2026-06-22 15:34:35 +02:00
..

iroh-dns

DNS-based endpoint discovery for Iroh.

This crate contains the core types for publishing and resolving iroh endpoint information via DNS, using the pkarr signed packet format.

License

This project is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.