[PR #2923] [MERGED] Check offset size when compressing names #3426

Closed
opened 2026-03-16 11:43:05 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hickory-dns/hickory-dns/pull/2923
Author: @divergentdave
Created: 4/11/2025
Status: Merged
Merged: 4/11/2025
Merged by: @djc

Base: mainHead: david/name-compression-offset-limit


📝 Commits (1)

  • bf85c5c Check offset size when compressing names

📊 Changes

1 file changed (+3 additions, -3 deletions)

View changed files

📝 crates/proto/src/rr/domain/name.rs (+3 -3)

📄 Description

I noticed while reading the name compression routine that there's no check that the pointer offset is small enough to be represented in a compressed label. This PR checks that the offset is small enough, rather than masking it off.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hickory-dns/hickory-dns/pull/2923 **Author:** [@divergentdave](https://github.com/divergentdave) **Created:** 4/11/2025 **Status:** ✅ Merged **Merged:** 4/11/2025 **Merged by:** [@djc](https://github.com/djc) **Base:** `main` ← **Head:** `david/name-compression-offset-limit` --- ### 📝 Commits (1) - [`bf85c5c`](https://github.com/hickory-dns/hickory-dns/commit/bf85c5cbadc1c4379f8a41215c832ab2235a461d) Check offset size when compressing names ### 📊 Changes **1 file changed** (+3 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `crates/proto/src/rr/domain/name.rs` (+3 -3) </details> ### 📄 Description I noticed while reading the name compression routine that there's no check that the pointer offset is small enough to be represented in a compressed label. This PR checks that the offset is small enough, rather than masking it off. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-16 11:43:05 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#3426
No description provided.