[Freeipa-devel] [PATCH] 328 Process relative nameserver DNS record correctly

Martin Kosek mkosek at redhat.com
Thu Oct 25 14:01:43 UTC 2012


Nameserver hostname passed to dnszone_add command was always treated
as FQDN even though it was a relative DNS name to the new zone. All
relative names were being rejected as unresolvable.

Modify --name-server option processing in dnszone_add and dnszone_mod
to respect FQDN/relative DNS name and do the checks accordingly. With
this change, user can add a new zone "example.com" and let dnszone_add
to create NS record "ns" in it, when supplied with its IP address. IP
address check is more strict so that it is not entered when no forward
record is created. Places misusing the option were fixed.

Nameserver option now also accepts zone name, which means that NS and A
record is placed to DNS zone itself. Also "@" is accepted as a nameserver
name, BIND understand it also as a zone name. As a side-effect of this
change, other records with hostname part (MX, KX, NS, SRV) accept "@"
as valid hostname. BIND replaces it with respective zone name as well.

Unit tests were updated to test the new format.

https://fedorahosted.org/freeipa/ticket/3204

---

With this change, use cases like the following should now work as expected:

# ipa dnszone-add example.com --name-server ns --ip-address 10.0.0.1

# ipa dnszone-add example.com --name-server ns.example.com. --ip-address 10.0.0.1

# ipa dnszone-add example.com --name-server ns.other.zone. --ip-address 10.0.0.1

# ipa dnszone-add example.com --name-server example.com. --ip-address 10.0.0.1

# ipa dnszone-add example.com --name-server @ --ip-address 10.0.0.1

Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freeipa-mkosek-328-process-relative-nameserver-dns-record-correctly.patch
Type: text/x-patch
Size: 19597 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20121025/9fbb1af0/attachment.bin>


More information about the Freeipa-devel mailing list