Skip to content

Fix overflow in Message::canonical_name when ancount is u16::MAX - #708

Open
SebastiaanYN wants to merge 1 commit into
NLnetLabs:mainfrom
SebastiaanYN:canonical-overflow
Open

Fix overflow in Message::canonical_name when ancount is u16::MAX#708
SebastiaanYN wants to merge 1 commit into
NLnetLabs:mainfrom
SebastiaanYN:canonical-overflow

Conversation

@SebastiaanYN

Copy link
Copy Markdown
Contributor

Use saturating_add(1) for the CNAME loop bound. The +1 exists only for loop detection (one more iteration than answer records), so capping at u16::MAX is harmless.

Use `saturating_add(1)` for the CNAME loop bound. The +1 exists only
for loop detection (one more iteration than answer records), so
capping at u16::MAX is harmless.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant