Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
C
Coredns
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Railgun
Coredns
Commits
17fca596
Commit
17fca596
authored
Apr 04, 2022
by
Chris O'Haver
Committed by
GitHub
Apr 04, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Comment reason for non-exact match in direct cname loop checks (#5294)
Signed-off-by:
Chris O'Haver
<
cohaver@infoblox.com
>
parent
4d76faa4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
plugin/backend_lookup.go
plugin/backend_lookup.go
+3
-0
No files found.
plugin/backend_lookup.go
View file @
17fca596
...
@@ -30,6 +30,7 @@ func A(ctx context.Context, b ServiceBackend, zone string, state request.Request
...
@@ -30,6 +30,7 @@ func A(ctx context.Context, b ServiceBackend, zone string, state request.Request
case
dns
.
TypeCNAME
:
case
dns
.
TypeCNAME
:
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
// x CNAME x is a direct loop, don't add those
// x CNAME x is a direct loop, don't add those
// in etcd/skydns w.x CNAME x is also direct loop due to the "recursive" nature of search results
continue
continue
}
}
...
@@ -104,6 +105,7 @@ func AAAA(ctx context.Context, b ServiceBackend, zone string, state request.Requ
...
@@ -104,6 +105,7 @@ func AAAA(ctx context.Context, b ServiceBackend, zone string, state request.Requ
// Try to resolve as CNAME if it's not an IP, but only if we don't create loops.
// Try to resolve as CNAME if it's not an IP, but only if we don't create loops.
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
// x CNAME x is a direct loop, don't add those
// x CNAME x is a direct loop, don't add those
// in etcd/skydns w.x CNAME x is also direct loop due to the "recursive" nature of search results
continue
continue
}
}
...
@@ -358,6 +360,7 @@ func TXT(ctx context.Context, b ServiceBackend, zone string, state request.Reque
...
@@ -358,6 +360,7 @@ func TXT(ctx context.Context, b ServiceBackend, zone string, state request.Reque
case
dns
.
TypeCNAME
:
case
dns
.
TypeCNAME
:
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
if
Name
(
state
.
Name
())
.
Matches
(
dns
.
Fqdn
(
serv
.
Host
))
{
// x CNAME x is a direct loop, don't add those
// x CNAME x is a direct loop, don't add those
// in etcd/skydns w.x CNAME x is also direct loop due to the "recursive" nature of search results
continue
continue
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment