Bug 947957

Summary: Implement support for DNAME records
Product: Red Hat Enterprise Linux 7 Reporter: Petr Spacek <pspacek>
Component: bind-dyndb-ldapAssignee: Petr Spacek <pspacek>
Status: CLOSED CURRENTRELEASE QA Contact: IDM QE LIST <seceng-idm-qe-list>
Severity: unspecified Docs Contact:
Priority: medium    
Version: 7.0CC: dpal, nsoman, pspacek
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: bind-dyndb-ldap-3.5-1.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-13 09:54:28 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Petr Spacek 2013-04-03 15:48:12 UTC
We forgot to clone upstream ticket to the Bugzilla.

Support for DNAME records is missing. The support is required for DNS 'sites'/'locations'.

The work is already done upstream.

This bug is created as a clone of upstream ticket:
https://fedorahosted.org/bind-dyndb-ldap/ticket/63

Comment 1 Namita Soman 2013-04-03 16:17:00 UTC
Please add steps to verify this

Comment 2 Petr Spacek 2013-04-04 08:55:10 UTC
See the table on page 6 in RFC 6672: http://tools.ietf.org/html/rfc6672#page-6 . The table contains all meaningful combinations and expected results.

Dictionary for RFC<->IPA terminology:
DNS zone 'example.com.' contains following DNS record:
oldname DNAME newname

1) Owner name = 'left side' DNS name in database
Owner name in the example above is 'oldname.example.com.'

2) Target = 'right side' DNS name in database
Target in the example above is 'newname.example.com.'

3) QNAME (query name) = name requested by DNS query (during the test).
E.g. command "dig somename.example.com." produces query with QNAME = 'somename.example.com.'

4) QTYPE (query type) = record type requested by DNS query (during the test).
E.g. command "dig somename.example.com. -t DNAME" produces query with QTYPE = DNAME, command "dig somename.example.com. -t TXT" produces query with QTYPE = TXT.

5) Result = CNAME record produced by DNAME substitution (i.e. owner name present in query name is substituted by target). See http://en.wikipedia.org/wiki/CNAME_record#DNAME_record and RFC for details.

Names on the 'right side' are subject of normal DNS expansion, i.e. zone origin is appended to names without trailing dot. Names with trailing dot are left intact.

Comment 4 Petr Spacek 2014-02-06 09:15:16 UTC
Replying to question how to test this (received via e-mail):
Please create a zone and add records to it as described in http://en.wikipedia.org/wiki/CNAME_record#DNAME_record . Then verify that the results match description in the Wikipedia article.

Comment 5 Petr Spacek 2014-02-06 09:42:24 UTC
Some other examples are on http://tools.ietf.org/html/rfc6672#section-6 .

Comment 6 Namita Soman 2014-02-06 21:05:35 UTC
Verified using ipa-server-3.3.3-15.el7.x86_64, bind-dyndb-ldap-3.5-3.el7.x86_64

# ipa dnsrecord-add testrelm.com dname1 --dname-rec n14k11.testrelm.com.
  Record name: dname1
  DNAME record: n14k11.testrelm.com.


# ipa dnsrecord-add testrelm.com 
Record name: n14k11 
Please choose a type of DNS resource record to be added
The most common types for this type of zone are: A, AAAA

DNS resource record type: a
A IP Address: 1.2.3.4
  Record name: n14k11
  A record: 1.2.3.4

# ipa dnsrecord-add testrelm.com 
Record name: host1.n14k11
Please choose a type of DNS resource record to be added
The most common types for this type of zone are: A, AAAA

DNS resource record type: a
A IP Address: 1.2.3.5
  Record name: host1.n14k11
  A record: 1.2.3.5


# dig host1.dname1.testrelm.com
<..snip..>
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 2, ADDITIONAL: 3
<..snip..>
;; QUESTION SECTION:
;host1.dname1.testrelm.com.	IN	A

;; ANSWER SECTION:
dname1.testrelm.com.	86400	IN	DNAME	n14k11.testrelm.com.
host1.dname1.testrelm.com. 86400 IN	CNAME	host1.n14k11.testrelm.com.
host1.n14k11.testrelm.com. 86400 IN	A	1.2.3.5

# dig dname1.testrelm.com -t DNAME
<..snip..>
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 3
<..snip..>
;; QUESTION SECTION:
;dname1.testrelm.com.		IN	DNAME

;; ANSWER SECTION:
dname1.testrelm.com.	86400	IN	DNAME	n14k11.testrelm.com.
<..snip..>

Comment 7 Ludek Smid 2014-06-13 09:54:28 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.