ddns.xml 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [
  4. <!ENTITY mdash "&#x2014;" >
  5. ]>
  6. <chapter id="dhcp-ddns-server">
  7. <title>The DHCP-DDNS Server</title>
  8. <para>
  9. The DHCP-DDNS Server (kea-dhcp-ddns, known informally as D2) conducts the client side of
  10. the DDNS protocol (defined in RFC 2136) on behalf of the DHCPv4 and DHCPv6
  11. servers (kea-dhcp4 and kea-dhcp6 respectively). The DHCP servers construct
  12. DDNS update requests, known as NameChangeRequests (NCRs), based upon DHCP
  13. lease change events and then post these to D2. D2 attempts to match
  14. each such request to the appropriate DNS server(s) and carry out the
  15. necessary conversation with those servers to update the DNS data.
  16. </para>
  17. <para>
  18. In order to match a request to appropriate DNS servers, D2 must have a
  19. catalog of servers from which to select. In fact, D2 has two such catalogs,
  20. one for forward DNS and one for reverse DNS; these catalogs are referred
  21. to as DDNS Domain Lists. Each list consists of one or more named DDNS
  22. Domains. Further, each DDNS Domain has a list of one or more DNS
  23. servers that publish the DNS data for that domain.
  24. </para>
  25. <para>
  26. When conducting forward domain matching, D2 will compare the FQDN in
  27. the request against the name of each forward DDNS Domain. The domain
  28. whose name matches the longest portion of the FQDN is considered the
  29. best match. For example, if the FQDN is "myhost.sample.example.com.",
  30. and there are two forward domains in the catalog: "sample.example.com."
  31. and "example.com.", the former is regarded as the best match. In some
  32. cases, it may not be possible to find a suitable match. Given the same two
  33. forward domains there would be no match for the FQDN, "bogus.net", so the
  34. request would be rejected. Finally, if there are no forward DDNS Domains
  35. defined, D2 will simply disregard the forward update portion of requests.
  36. </para>
  37. <para>
  38. When conducting reverse domain matching, D2 constructs a reverse
  39. FQDN from the lease address in the request and compare that against
  40. the name of each reverse DDNS Domain. Again, the domain whose name matches
  41. the longest portion of the FQDN is considered the best match. For instance,
  42. if the lease address is "172.16.1.40" and there are two reverse domains in
  43. the catalog: "1.16.172.in-addr.arpa." and "16.172.in-addr.arpa", the
  44. former is the best match. As with forward matching, it is possible to not
  45. find a suitable match. Given the same two domains, there would be no
  46. match for the lease address, "192.168.1.50", and the request would be
  47. rejected. Finally, if there are no reverse DDNS Domains defined, D2 will
  48. simply disregard the reverse update portion of requests.
  49. </para>
  50. <section id="dhcp-ddns-server-start-stop">
  51. <title>Starting and Stopping the DHCP-DDNS Server</title>
  52. <para>
  53. <command>kea-dhcp-ddns</command> is the Kea DHCP-DDNS server
  54. and, due to the nature of DDNS, it is run alongside either the
  55. DHCPv4 or DHCPv6 components (or both). Like other parts of
  56. Kea, is a separate binary that can be run on its own or through
  57. <command>keactrl</command> (see <xref linkend="keactrl"/>). In
  58. normal operation, controlling <command>kea-dhcp-ddns</command>
  59. with <command>keactrl</command> is recommended. However, it is also
  60. possible to run the DHCP-DDNS server directly. It accepts the
  61. following command-line switches:
  62. </para>
  63. <itemizedlist>
  64. <listitem>
  65. <simpara>
  66. <command>-c <replaceable>file</replaceable></command> -
  67. specifies the configuration file. This is the only mandatory
  68. switch.</simpara>
  69. </listitem>
  70. <listitem>
  71. <simpara>
  72. <command>-d</command> - specifies whether the server
  73. logging should be switched to debug/verbose mode. In verbose mode,
  74. the logging severity and debuglevel specified in a configuration
  75. file are ignored and "debug" severity and the maximum debuglevel
  76. (99) are assumed. The flag is convenient, for temporarily
  77. switching the server into maximum verbosity, e.g. when
  78. debugging.</simpara>
  79. </listitem>
  80. <listitem>
  81. <simpara>
  82. <command>-v</command> - prints out Kea version and exits.
  83. </simpara>
  84. </listitem>
  85. <listitem>
  86. <simpara>
  87. <command>-V</command> - prints out Kea extended version with
  88. additional parameters and exits.
  89. </simpara>
  90. </listitem>
  91. </itemizedlist>
  92. <para>
  93. Upon start up the module will load its configuration and begin listening
  94. for NCRs based on that configuration.
  95. </para>
  96. </section> <!-- end start-stop -->
  97. <section id="d2-configuration">
  98. <title>Configuring the DHCP-DDNS Server</title>
  99. <para>
  100. Before starting <command>kea-dhcp-ddns</command> module for the
  101. first time, a configuration file needs to be created. The following default
  102. configuration is a template that can be customised to your requirements.
  103. <screen>
  104. <userinput>"DhcpDdns": {
  105. "ip_address": "127.0.0.1",
  106. "port": 53001,
  107. "dns_server_timeout": 100,
  108. "ncr_protocol": "UDP",
  109. "ncr_format": "JSON",
  110. "tsig_keys": [ ],
  111. "forward_ddns": {
  112. "ddns_domains": [ ]
  113. },
  114. "reverse_ddns": {
  115. "ddns_domains": [ ]
  116. }
  117. }</userinput>
  118. </screen>
  119. </para>
  120. <para>
  121. The configuration can be divided as follows, each of which is described
  122. in its own section:
  123. </para>
  124. <itemizedlist>
  125. <listitem>
  126. <simpara>
  127. <command>Global Server Parameters</command> -
  128. values which control connectivity and global server behavior
  129. </simpara>
  130. </listitem>
  131. <listitem>
  132. <simpara>
  133. <command>TSIG Key Info</command> -
  134. defines the TSIG keys used for secure traffic with DNS servers
  135. </simpara>
  136. </listitem>
  137. <listitem>
  138. <simpara>
  139. <command>Forward DDNS</command> -
  140. defines the catalog of Forward DDNS Domains
  141. </simpara>
  142. </listitem>
  143. <listitem>
  144. <simpara>
  145. <command>Reverse DDNS</command> -
  146. defines the catalog of Forward DDNS Domains
  147. </simpara>
  148. </listitem>
  149. </itemizedlist>
  150. <section id="d2-server-parameter-config">
  151. <title>Global Server Parameters</title>
  152. <itemizedlist>
  153. <listitem><simpara>
  154. <command>ip_address</command> - IP address on which D2
  155. listens for requests. The default is the local loopback interface at
  156. address 127.0.0.1. You may specify either an IPv4 or IPv6 address.
  157. </simpara></listitem>
  158. <listitem><simpara>
  159. <command>port</command> - Port on which D2 listens for requests. The default value
  160. is 53001.
  161. </simpara></listitem>
  162. <listitem><simpara>
  163. <command>dns_server_timeout</command> - The maximum amount
  164. of time in milliseconds, that D2 will wait for a response from a
  165. DNS server to a single DNS update message.
  166. </simpara></listitem>
  167. <listitem><simpara>
  168. <command>ncr_protocol</command> - Packet format to use when sending requests to D2.
  169. Currently only JSON format is supported. Other formats may be available
  170. in future releases.
  171. </simpara></listitem>
  172. <listitem><simpara>
  173. <command>ncr_format</command> - Socket protocol to use when sending requests to D2.
  174. Currently only UDP is supported. TCP may be available in an upcoming
  175. release.
  176. </simpara></listitem>
  177. </itemizedlist>
  178. <para>
  179. D2 must listen for change requests on a known address and port. By
  180. default it listens at 127.0.0.1 on port 53001. The following example
  181. illustrates how to change D2's global parameters so it will listen
  182. at 192.168.1.10 port 900:
  183. <screen>
  184. "DhcpDdns": {
  185. <userinput>"ip_address": "192.168.1.10",
  186. "port": 900,</userinput>
  187. ...
  188. }
  189. }</screen>
  190. </para>
  191. <warning>
  192. <simpara>
  193. It is possible for a malicious attacker to send bogus
  194. NameChangeRequests to the DHCP-DDNS server. Addresses
  195. other than the IPv4 or IPv6 loopback addresses (127.0.0.1
  196. or ::1) should only be used for testing purposes, but
  197. note that local users may still communicate with the
  198. DHCP-DDNS server. A future version of Kea will implement
  199. authentication to guard against such attacks.
  200. </simpara>
  201. <!-- see ticket #3514 -->
  202. </warning>
  203. <note>
  204. <simpara>
  205. If the ip_address and port are changed, it will be necessary to change the
  206. corresponding values in the DHCP servers' "dhcp-ddns" configuration section.
  207. </simpara>
  208. </note>
  209. </section> <!-- "d2-server-parameter-config" -->
  210. <section id="d2-tsig-key-list-config">
  211. <title>TSIG Key List</title>
  212. <para>
  213. A DDNS protocol exchange can be conducted with or without TSIG
  214. (defined in <ulink url="http://tools.ietf/org/html/rfc2845">RFC
  215. 2845</ulink>). This configuration section allows the administrator
  216. to define the set of TSIG keys that may be used in such
  217. exchanges.</para>
  218. <para>To use TSIG when updating entries in a DNS Domain,
  219. a key must be defined in the TSIG Key List and referenced by
  220. name in that domain's configuration entry. When D2 matches a
  221. change request to a domain, it checks whether the domain has
  222. a TSIG key associated with it. If so, D2 will use that key to
  223. sign DNS update messages sent to and verify responses received
  224. from the domain's DNS server(s). For each TSIG key required by
  225. the DNS servers that D2 will be working with there must be a
  226. corresponding TSIG key in the TSIG Key list.</para>
  227. <para>
  228. As one might gather from the name, the tsig_key section of the
  229. D2 configuration lists the TSIG keys. Each entry describes a
  230. TSIG key used by one or more DNS servers to authenticate requests
  231. and sign responses. Every entry in the list has three parameters:
  232. <itemizedlist>
  233. <listitem>
  234. <simpara>
  235. <command>name</command> -
  236. a unique text label used to identify this key within the
  237. list. This value is used to specify which key (if any) should be
  238. used when updating a specific domain. So long as it is unique its
  239. content is arbitrary, although for clarity and ease of maintenance
  240. it is recommended that it match the name used on the DNS server(s).
  241. It cannot be blank.
  242. </simpara>
  243. </listitem>
  244. <listitem>
  245. <simpara>
  246. <command>algorithm</command> -
  247. specifies which hashing algorithm should be used with this
  248. key. This value must specify the same algorithm used for the
  249. key on the DNS server(s). The supported algorithms are listed below:
  250. <itemizedlist>
  251. <listitem>
  252. <command>HMAC-MD5</command>
  253. </listitem>
  254. <listitem>
  255. <command>HMAC-SHA1</command>
  256. </listitem>
  257. <listitem>
  258. <command>HMAC-SHA224</command>
  259. </listitem>
  260. <listitem>
  261. <command>HMAC-SHA256</command>
  262. </listitem>
  263. <listitem>
  264. <command>HMAC-SHA384</command>
  265. </listitem>
  266. <listitem>
  267. <command>HMAC-SHA512</command>
  268. </listitem>
  269. </itemizedlist>
  270. This value is not case sensitive.
  271. </simpara>
  272. </listitem>
  273. <listitem>
  274. <simpara>
  275. <command>secret</command> -
  276. is used to specify the shared secret key code for this key. This value is
  277. case sensitive and must exactly match the value specified on the DNS server(s).
  278. It is a base64-encoded text value.
  279. </simpara>
  280. </listitem>
  281. </itemizedlist>
  282. </para>
  283. <para>
  284. As an example, suppose that a domain D2 will be updating is
  285. maintained by a BIND9 DNS server which requires dynamic updates
  286. to be secured with TSIG. Suppose further that the entry for
  287. the TSIG key in BIND9's named.conf file looks like this:
  288. <screen>
  289. :
  290. key "key.four.example.com." {
  291. algorithm hmac-sha224;
  292. secret "bZEG7Ow8OgAUPfLWV3aAUQ==";
  293. };
  294. :
  295. </screen>
  296. By default, the TSIG Key list is empty:
  297. <screen>
  298. "DhcpDdns": {
  299. <userinput>"tsig_keys": [ ]</userinput>,
  300. ...
  301. }
  302. </screen>
  303. We must extend the list with a new key:
  304. <screen>
  305. "DhcpDdns": {
  306. "tsig_keys": [
  307. <userinput> {
  308. "name": "key.four.example.com",
  309. "algorithm": "HMAC-SHA224",
  310. "secret": "bZEG7Ow8OgAUPfLWV3aAUQ=="
  311. }</userinput>
  312. ],
  313. ...
  314. }
  315. </screen>
  316. </para>
  317. <para>These steps would be repeated for each TSIG key needed. Note that
  318. the same TSIG key can be used with more than one domain.</para>
  319. </section>
  320. <!-- "d2-tsig-key-list-config" -->
  321. <section id="d2-forward-ddns-config">
  322. <title>Forward DDNS</title>
  323. <para>
  324. The Forward DDNS section is used to configure D2's forward update
  325. behavior. Currently it contains a single parameter, the catalog of
  326. forward DDNS Domains, which is a list of structures.
  327. <screen>
  328. "DhcpDdns": {
  329. <userinput>"forward_ddns": {
  330. "ddns_domains": [ ]
  331. }</userinput>,
  332. ...
  333. }
  334. </screen>
  335. By default, this list is empty, which will cause the server to ignore
  336. the forward update portions of requests.
  337. </para>
  338. <section id="add-forward-ddns-domain">
  339. <title>Adding Forward DDNS Domains</title>
  340. <para>
  341. A forward DDNS Domain maps a forward DNS zone to a set of
  342. DNS servers which maintain the forward DNS data (i.e. name to
  343. address mapping) for that zone. You will need one forward DDNS
  344. Domain for each zone you wish to service. It may very well
  345. be that some or all of your zones are maintained by the same
  346. servers. You will still need one DDNS Domain per zone. Remember
  347. that matching a request to the appropriate server(s) is done
  348. by zone and a DDNS Domain only defines a single zone.
  349. </para>
  350. <para>
  351. The section describes how to add Forward DDNS Domains. Repeat these
  352. steps for each Forward DDNS Domain desired. Each Forward DDNS Domain
  353. has the following parameters:
  354. <itemizedlist>
  355. <listitem>
  356. <simpara>
  357. <command>name</command> -
  358. The fully qualified domain name (or zone) that this DDNS Domain
  359. can update. This is value used to compare against the request
  360. FQDN during forward matching. It must be unique within the
  361. catalog.
  362. </simpara>
  363. </listitem>
  364. <listitem>
  365. <simpara>
  366. <command>key_name</command> -
  367. If TSIG is used with this domain's servers, this
  368. value should be the name of the key from within the TSIG Key List
  369. to use. If the value is blank (the default), TSIG will not be
  370. used in DDNS conversations with this domain's servers.
  371. </simpara>
  372. </listitem>
  373. <listitem>
  374. <simpara>
  375. <command>dns_servers</command> -
  376. A list of one or more DNS servers which can conduct the server
  377. side of the DDNS protocol for this domain. The servers
  378. are used in a first to last preference. In other words, when D2
  379. begins to process a request for this domain it will pick the
  380. first server in this list and attempt to communicate with it.
  381. If that attempt fails, it will move to next one in the list and
  382. so on until the it achieves success or the list is exhausted.
  383. </simpara>
  384. </listitem>
  385. </itemizedlist>
  386. To create a new forward DDNS Domain, one must add a new domain
  387. element and set its parameters:
  388. <screen>
  389. "DhcpDdns": {
  390. "forward_ddns": {
  391. "ddns_domains": [
  392. <userinput>{
  393. "name": "other.example.com",
  394. "key_name": "",
  395. "dns_servers": [
  396. ]
  397. }</userinput>
  398. ]
  399. }
  400. }
  401. </screen>
  402. It is permissible to add a domain without any servers. If that domain
  403. should be matched to a request, however, the request will fail. In
  404. order to make the domain useful though, we must add at least one DNS
  405. server to it.
  406. </para>
  407. <section id="add-forward-dns-servers">
  408. <title>Adding Forward DNS Servers</title>
  409. <para>
  410. The section describes how to add DNS servers to a Forward DDNS Domain.
  411. Repeat them for as many servers as desired for a each domain.
  412. </para>
  413. <para>
  414. Forward DNS Server entries represent actual DNS servers which
  415. support the server side of the DDNS protocol. Each Forward DNS Server
  416. has the following parameters:
  417. <itemizedlist>
  418. <listitem>
  419. <simpara>
  420. <command>hostname</command> -
  421. The resolvable host name of the DNS server. This value is not
  422. yet implemented.
  423. </simpara>
  424. </listitem>
  425. <listitem>
  426. <simpara>
  427. <command>ip_address</command> -
  428. The IP address at which the server listens for DDNS requests.
  429. This may be either an IPv4 or an IPv6 address.
  430. </simpara>
  431. </listitem>
  432. <listitem>
  433. <simpara>
  434. <command>port</command> -
  435. The port on which the server listens for DDNS requests. It
  436. defaults to the standard DNS service port of 53.
  437. </simpara>
  438. </listitem>
  439. </itemizedlist>
  440. To create a new forward DNS Server, one must add a new server
  441. element to the domain and fill its parameters. If for
  442. example the service is running at "172.88.99.10", then set it as
  443. follows:
  444. <screen>
  445. "DhcpDdns": {
  446. "forward_ddns": {
  447. "ddns_domains": [
  448. {
  449. "name": "other.example.com",
  450. "key_name": "",
  451. "dns_servers": [
  452. <userinput>{
  453. "hostname": "",
  454. "ip_address": "172.88.99.10",
  455. "port": 53
  456. }</userinput>
  457. ]
  458. }
  459. ]
  460. }
  461. }
  462. </screen>
  463. </para>
  464. <note><simpara>
  465. As stated earlier, "hostname" is not yet supported so, the parameter
  466. "ip_address" must be set to the address of the DNS server.
  467. </simpara></note>
  468. </section> <!-- "add-forward-dns-servers" -->
  469. </section> <!-- "add-forward-ddns-domains" -->
  470. </section> <!-- "d2-forward-ddns-config" -->
  471. <section id="d2-reverse-ddns-config">
  472. <title>Reverse DDNS</title>
  473. <para>
  474. The Reverse DDNS section is used to configure D2's reverse update
  475. behavior, and the concepts are the same as for the forward DDNS
  476. section. Currently it contains a single parameter, the catalog of
  477. reverse DDNS Domains, which is a list of structures.
  478. <screen>
  479. "DhcpDdns": {
  480. <userinput>"reverse_ddns": {
  481. "ddns_domains": [ ]
  482. }</userinput>
  483. ...
  484. }
  485. </screen>
  486. By default, this list is empty, which will cause the server to ignore
  487. the reverse update portions of requests.
  488. </para>
  489. <section id="add-reverse-ddns-domain">
  490. <title>Adding Reverse DDNS Domains</title>
  491. <para>
  492. A reverse DDNS Domain maps a reverse DNS zone to a set of DNS
  493. servers which maintain the reverse DNS data (address to name
  494. mapping) for that zone. You will need one reverse DDNS Domain
  495. for each zone you wish to service. It may very well be that
  496. some or all of your zones are maintained by the same servers;
  497. even then, you will still need one DDNS Domain entry for each
  498. zone. Remember that matching a request to the appropriate
  499. server(s) is done by zone and a DDNS Domain only defines a
  500. single zone.
  501. </para>
  502. <para>
  503. The section describes how to add Reverse DDNS Domains. Repeat these
  504. steps for each Reverse DDNS Domain desired. Each Reverse DDNS Domain
  505. has the following parameters:
  506. <itemizedlist>
  507. <listitem>
  508. <simpara>
  509. <command>name</command> -
  510. The fully qualified reverse zone that this DDNS Domain
  511. can update. This is the value used during reverse matching
  512. which will compare it with a reversed version of the request's
  513. lease address. The zone name should follow the appropriate
  514. standards: for example, to to support the IPv4 subnet 172.16.1,
  515. the name should be. "1.16.172.in-addr.arpa.". Similarly,
  516. to support an IPv6 subent of 2001:db8:1, the name should be
  517. "1.0.0.0.8.B.D.0.1.0.0.2.ip6.arpa."
  518. Whatever the name, it must be unique within the catalog.
  519. </simpara>
  520. </listitem>
  521. <listitem>
  522. <simpara>
  523. <command>key_name</command> -
  524. If TSIG should be used with this domain's servers, then this
  525. value should be the name of that key from the TSIG Key List.
  526. If the value is blank (the default), TSIG will not be
  527. used in DDNS conversations with this domain's servers. Currently
  528. this value is not used as TSIG has not been implemented.
  529. </simpara>
  530. </listitem>
  531. <listitem>
  532. <simpara>
  533. <command>dns_servers</command> -
  534. a list of one or more DNS servers which can conduct the server
  535. side of the DDNS protocol for this domain. Currently the servers
  536. are used in a first to last preference. In other words, when D2
  537. begins to process a request for this domain it will pick the
  538. first server in this list and attempt to communicate with it.
  539. If that attempt fails, it will move to next one in the list and
  540. so on until the it achieves success or the list is exhausted.
  541. </simpara>
  542. </listitem>
  543. </itemizedlist>
  544. To create a new reverse DDNS Domain, one must add a new domain element
  545. and set its parameters. For example, to support subnet 2001:db8:1::,
  546. the following configuration could be used:
  547. <screen>
  548. "DhcpDdns": {
  549. "reverse_ddns": {
  550. "ddns_domains": [
  551. <userinput>{
  552. "name": "1.0.0.0.8.B.D.0.1.0.0.2.ip6.arpa.",
  553. "key_name": "",
  554. "dns_servers": [
  555. ]
  556. }</userinput>
  557. ]
  558. }
  559. }
  560. </screen>
  561. It is permissible to add a domain without any servers. If that domain
  562. should be matched to a request, however, the request will fail. In
  563. order to make the domain useful though, we must add at least one DNS
  564. server to it.
  565. </para>
  566. <section id="add-reverse-dns-servers">
  567. <title>Adding Reverse DNS Servers</title>
  568. <para>
  569. The section describes how to add DNS servers to a Reverse DDNS Domain.
  570. Repeat them for as many servers as desired for a each domain.
  571. </para>
  572. <para>
  573. Reverse DNS Server entries represents a actual DNS servers which
  574. support the server side of the DDNS protocol. Each Reverse DNS Server
  575. has the following parameters:
  576. <itemizedlist>
  577. <listitem>
  578. <simpara>
  579. <command>hostname</command> -
  580. The resolvable host name of the DNS server. This value is
  581. currently ignored.
  582. </simpara>
  583. </listitem>
  584. <listitem>
  585. <simpara>
  586. <command>ip_address</command> -
  587. The IP address at which the server listens for DDNS requests.
  588. </simpara>
  589. </listitem>
  590. <listitem>
  591. <simpara>
  592. <command>port</command> -
  593. The port on which the server listens for DDNS requests. It
  594. defaults to the standard DNS service port of 53.
  595. </simpara>
  596. </listitem>
  597. </itemizedlist>
  598. To create a new reverse DNS Server, one must first add a new server
  599. element to the domain and fill its parameters. If for
  600. example the service is running at "172.88.99.10", then set it as
  601. follows:
  602. <screen>
  603. "DhcpDdns": {
  604. "reverse_ddns": {
  605. "ddns_domains": [
  606. {
  607. "name": "1.0.0.0.8.B.D.0.1.0.0.2.ip6.arpa.",
  608. "key_name": "",
  609. "dns_servers": [
  610. <userinput>{
  611. "hostname": "",
  612. "ip_address": "172.88.99.10",
  613. "port": 53
  614. }</userinput>
  615. ]
  616. }
  617. ]
  618. }
  619. }
  620. </screen>
  621. </para>
  622. <note>
  623. <simpara>
  624. As stated earlier, "hostname" is not yet supported so, the parameter
  625. "ip_address" must be set to the address of the DNS server.
  626. </simpara>
  627. </note>
  628. </section> <!-- "add-reverse-dns-servers" -->
  629. </section> <!-- "add-reverse-ddns-domains" -->
  630. </section> <!-- "d2-reverse-ddns-config" -->
  631. <section id="d2-exmaple-config">
  632. <title>Example DHCP-DDNS Server Configuration</title>
  633. <para>
  634. This section provides an example DHCP-DDNS server configuration based
  635. on a small example network. Let's suppose our example network has
  636. three domains, each with their own subnet.
  637. <table>
  638. <title>Our example network</title>
  639. <tgroup cols='4' align='left'>
  640. <colspec colname='domain'/>
  641. <colspec colname='subnet'/>
  642. <colspec colname='fservers'/>
  643. <colspec colname='rservers'/>
  644. <thead>
  645. <row>
  646. <entry>Domain</entry>
  647. <entry>Subnet</entry>
  648. <entry>Forward DNS Servers</entry>
  649. <entry>Reverse DNS Servers</entry>
  650. </row>
  651. </thead>
  652. <tbody>
  653. <row>
  654. <entry>four.example.com</entry>
  655. <entry>192.0.2.0/24</entry>
  656. <entry>172.16.1.5, 172.16.2.5</entry>
  657. <entry>172.16.1.5, 172.16.2.5</entry>
  658. </row>
  659. <row>
  660. <entry>six.example.com</entry>
  661. <entry>2001:db8:1::/64</entry>
  662. <entry>3001:1::50</entry>
  663. <entry>3001:1::51</entry>
  664. </row>
  665. <row>
  666. <entry>example.com</entry>
  667. <entry>192.0.0.0/16</entry>
  668. <entry>172.16.2.5</entry>
  669. <entry>172.16.2.5</entry>
  670. </row>
  671. </tbody>
  672. </tgroup>
  673. </table>
  674. </para>
  675. <para>
  676. We need to construct three forward DDNS Domains:
  677. <table>
  678. <title>Forward DDNS Domains Needed</title>
  679. <tgroup cols='3' align='left'>
  680. <colspec colname='num'/>
  681. <colspec colname='name'/>
  682. <colspec colname='servers'/>
  683. <thead>
  684. <row>
  685. <entry>#</entry>
  686. <entry>DDNS Domain Name</entry>
  687. <entry>DNS Servers</entry>
  688. </row>
  689. </thead>
  690. <tbody>
  691. <row>
  692. <entry>1.</entry>
  693. <entry>four.example.com.</entry>
  694. <entry>172.16.1.5, 172.16.2.5</entry>
  695. </row>
  696. <row>
  697. <entry>2.</entry>
  698. <entry>six.example.com.</entry>
  699. <entry>3001:1::50</entry>
  700. </row>
  701. <row>
  702. <entry>3.</entry>
  703. <entry>example.com.</entry>
  704. <entry>172.16.2.5</entry>
  705. </row>
  706. </tbody>
  707. </tgroup>
  708. </table>
  709. As discussed earlier, FQDN to domain matching is based on the longest
  710. match. The FQDN, "myhost.four.example.com.", will match the first
  711. domain ("four.example.com") while "admin.example.com." will match the
  712. third domain ("example.com"). The
  713. FQDN, "other.example.net." will fail to match any domain and would
  714. be rejected.
  715. </para>
  716. <para>
  717. The following example configuration specified the Forward DDNS Domains.
  718. <screen><userinput>
  719. "DhcpDdns": {
  720. "forward_ddns": {
  721. "ddns_domains": [
  722. {
  723. "name": "four.example.com.",
  724. "key_name": "",
  725. "dns_servers": [
  726. { "ip_address": "172.16.1.5" },
  727. { "ip_address": "172.16.2.5" }
  728. ]
  729. },
  730. {
  731. "name": "six.example.com.",
  732. "key_name": "",
  733. "dns_servers": [
  734. { "ip_address": "2001:db8::1" }
  735. ]
  736. },
  737. {
  738. "name": "example.com.",
  739. "key_name": "",
  740. "dns_servers": [
  741. { "ip_address": "172.16.2.5" }
  742. ]
  743. },
  744. ]
  745. }
  746. }</userinput>
  747. </screen>
  748. </para>
  749. <para>
  750. Similarly, we need to construct the three reverse DDNS Domains:
  751. <table>
  752. <title>Reverse DDNS Domains Needed</title>
  753. <tgroup cols='3' align='left'>
  754. <colspec colname='num'/>
  755. <colspec colname='DDNS Domain name'/>
  756. <colspec colname='DDNS Domain DNS Servers'/>
  757. <thead>
  758. <row>
  759. <entry>#</entry>
  760. <entry>DDNS Domain Name</entry>
  761. <entry>DNS Servers</entry>
  762. </row>
  763. </thead>
  764. <tbody>
  765. <row>
  766. <entry>1.</entry>
  767. <entry>2.0.192.in-addr.arpa.</entry>
  768. <entry>172.16.1.5, 172.16.2.5</entry>
  769. </row>
  770. <row>
  771. <entry>2.</entry>
  772. <entry>1.0.0.0.8.d.b.0.1.0.0.2.ip6.arpa.</entry>
  773. <entry>3001:1::50</entry>
  774. </row>
  775. <row>
  776. <entry>3.</entry>
  777. <entry>0.182.in-addr.arpa.</entry>
  778. <entry>172.16.2.5</entry>
  779. </row>
  780. </tbody>
  781. </tgroup>
  782. </table>
  783. An address of "192.0.2.150" will match the first domain,
  784. "2001:db8:1::10" will match the second domain, and "192.0.50.77"
  785. the third domain.
  786. </para>
  787. <para>
  788. These Reverse DDNS Domains are specified as follows:
  789. <screen><userinput>
  790. "DhcpDdns": {
  791. "reverse_ddns": {
  792. "ddns_domains": [
  793. {
  794. "name": "2.0.192.in-addr.arpa.",
  795. "key_name": "",
  796. "dns_servers": [
  797. { "ip_address": "172.16.1.5" },
  798. { "ip_address": "172.16.2.5" }
  799. ]
  800. }
  801. {
  802. "name": "1.0.0.0.8.B.D.0.1.0.0.2.ip6.arpa.",
  803. "key_name": "",
  804. "dns_servers": [
  805. { "ip_address": "2001:db8::1" }
  806. ]
  807. }
  808. {
  809. "name": "0.192.in-addr.arpa.",
  810. "key_name": "",
  811. "dns_servers": [
  812. { "ip_address": "172.16.2.5" }
  813. ]
  814. }
  815. ]
  816. }
  817. }</userinput>
  818. </screen>
  819. </para>
  820. </section> <!-- end of "d2-example" -->
  821. </section> <!-- end of section "d2-configuration" -->
  822. <section>
  823. <title>DHCP-DDNS Server Limitations</title>
  824. <para>The following are the current limitations of the DHCP-DDNS Server.</para>
  825. <itemizedlist>
  826. <listitem>
  827. <simpara>
  828. Requests received from the DHCP servers are placed in a
  829. queue until they are processed. Currently all queued requests
  830. are lost when the server shuts down.
  831. </simpara>
  832. </listitem>
  833. </itemizedlist>
  834. </section>
  835. </chapter> <!-- DHCP-DDNS Server -->