Fix private IP address filtering in DNS validation#16
Closed
Copilot wants to merge 4 commits into
Closed
Conversation
Owner
|
是解析10.x.x.x IP段 @copilot |
…s from being dropped Co-authored-by: naiba <29243953+naiba@users.noreply.github.com>
Co-authored-by: naiba <29243953+naiba@users.noreply.github.com>
Co-authored-by: naiba <29243953+naiba@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Check for logic missing in segment 10 parsing
Fix private IP address filtering in DNS validation
Dec 19, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Private IP addresses (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16) were being incorrectly rejected by primary DNS servers because they're not in the China IP list used for geographic validation.
Changes
isPrivateIP()helper to detect RFC 1918 IPv4 ranges and fc00::/7 IPv6 ULAIsValidMsg()to skip geographic validation for private IPs - they're always valid regardless of DNS sourceInternal network addresses are not subject to geographic routing restrictions and should always be accepted.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.