mirror of
				https://github.com/coredns/coredns.git
				synced 2025-10-30 17:53:21 -04:00 
			
		
		
		
	middleware/file: Add CNAME chain support (#400)
Up till now we would only chase 1 CNAME. Spec requires we will chase all. This PR add support for this. Up to 8 CNAMEs are chased (this could be longer, by just checking for cycles, but 8 seems enough for now). Also add RRSIG of the first CNAME for DNSSEC.
This commit is contained in:
		| @@ -54,7 +54,7 @@ var dsTestCases = []test.Case{ | ||||
| func TestLookupDS(t *testing.T) { | ||||
| 	zone, err := Parse(strings.NewReader(dbMiekNLDelegation), testzone, "stdin") | ||||
| 	if err != nil { | ||||
| 		t.Fatalf("expect no error when reading zone, got %q", err) | ||||
| 		t.Fatalf("Expected no error when reading zone, got %q", err) | ||||
| 	} | ||||
|  | ||||
| 	fm := File{Next: test.ErrorHandler(), Zones: Zones{Z: map[string]*Zone{testzone: zone}, Names: []string{testzone}}} | ||||
| @@ -66,7 +66,7 @@ func TestLookupDS(t *testing.T) { | ||||
| 		rec := dnsrecorder.New(&test.ResponseWriter{}) | ||||
| 		_, err := fm.ServeDNS(ctx, rec, m) | ||||
| 		if err != nil { | ||||
| 			t.Errorf("expected no error, got %v\n", err) | ||||
| 			t.Errorf("Expected no error, got %v\n", err) | ||||
| 			return | ||||
| 		} | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user