Skip to content

Commit 20ea3c1

Browse files
haochangjiuclaude
andcommitted
fix: correct DNS record type constants (A=1, AAAA=28)
The DNS type constants were incorrectly defined using iota (0, 1), but RFC 1035 defines A record as type 1 and RFC 3596 defines AAAA record as type 28. This caused AAAA queries to bypass the NHP knocking logic entirely. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 75ac57a commit 20ea3c1

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

common/constant.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ const (
88
)
99

1010
const (
11-
Type_A = iota
12-
Type_AAAA
11+
Type_A = 1 // DNS A record type (RFC 1035)
12+
Type_AAAA = 28 // DNS AAAA record type (RFC 3596)
1313
)
1414

1515
const (

0 commit comments

Comments
 (0)