1<!-- 2 - Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") 3 - Copyright (C) 2000-2003 Internet Software Consortium. 4 - 5 - Permission to use, copy, modify, and/or distribute this software for any 6 - purpose with or without fee is hereby granted, provided that the above 7 - copyright notice and this permission notice appear in all copies. 8 - 9 - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH 10 - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 11 - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, 12 - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 13 - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE 14 - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 15 - PERFORMANCE OF THIS SOFTWARE. 16--> 17<!-- $Id$ --> 18<html> 19<head> 20<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> 21<title>dnssec-signzone</title> 22<meta name="generator" content="DocBook XSL Stylesheets V1.71.1"> 23</head> 24<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en"> 25<a name="man.dnssec-signzone"></a><div class="titlepage"></div> 26<div class="refnamediv"> 27<h2>Name</h2> 28<p><span class="application">dnssec-signzone</span> — DNSSEC zone signing tool</p> 29</div> 30<div class="refsynopsisdiv"> 31<h2>Synopsis</h2> 32<div class="cmdsynopsis"><p><code class="command">dnssec-signzone</code> [<code class="option">-a</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-d <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-E <em class="replaceable"><code>engine</code></em></code>] [<code class="option">-e <em class="replaceable"><code>end-time</code></em></code>] [<code class="option">-f <em class="replaceable"><code>output-file</code></em></code>] [<code class="option">-g</code>] [<code class="option">-h</code>] [<code class="option">-K <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-k <em class="replaceable"><code>key</code></em></code>] [<code class="option">-l <em class="replaceable"><code>domain</code></em></code>] [<code class="option">-i <em class="replaceable"><code>interval</code></em></code>] [<code class="option">-I <em class="replaceable"><code>input-format</code></em></code>] [<code class="option">-j <em class="replaceable"><code>jitter</code></em></code>] [<code class="option">-N <em class="replaceable"><code>soa-serial-format</code></em></code>] [<code class="option">-o <em class="replaceable"><code>origin</code></em></code>] [<code class="option">-O <em class="replaceable"><code>output-format</code></em></code>] [<code class="option">-p</code>] [<code class="option">-P</code>] [<code class="option">-r <em class="replaceable"><code>randomdev</code></em></code>] [<code class="option">-S</code>] [<code class="option">-s <em class="replaceable"><code>start-time</code></em></code>] [<code class="option">-T <em class="replaceable"><code>ttl</code></em></code>] [<code class="option">-t</code>] [<code class="option">-u</code>] [<code class="option">-v <em class="replaceable"><code>level</code></em></code>] [<code class="option">-x</code>] [<code class="option">-z</code>] [<code class="option">-3 <em class="replaceable"><code>salt</code></em></code>] [<code class="option">-H <em class="replaceable"><code>iterations</code></em></code>] [<code class="option">-A</code>] {zonefile} [key...]</p></div> 33</div> 34<div class="refsect1" lang="en"> 35<a name="id2543597"></a><h2>DESCRIPTION</h2> 36<p><span><strong class="command">dnssec-signzone</strong></span> 37 signs a zone. It generates 38 NSEC and RRSIG records and produces a signed version of the 39 zone. The security status of delegations from the signed zone 40 (that is, whether the child zones are secure or not) is 41 determined by the presence or absence of a 42 <code class="filename">keyset</code> file for each child zone. 43 </p> 44</div> 45<div class="refsect1" lang="en"> 46<a name="id2543612"></a><h2>OPTIONS</h2> 47<div class="variablelist"><dl> 48<dt><span class="term">-a</span></dt> 49<dd><p> 50 Verify all generated signatures. 51 </p></dd> 52<dt><span class="term">-c <em class="replaceable"><code>class</code></em></span></dt> 53<dd><p> 54 Specifies the DNS class of the zone. 55 </p></dd> 56<dt><span class="term">-C</span></dt> 57<dd><p> 58 Compatibility mode: Generate a 59 <code class="filename">keyset-<em class="replaceable"><code>zonename</code></em></code> 60 file in addition to 61 <code class="filename">dsset-<em class="replaceable"><code>zonename</code></em></code> 62 when signing a zone, for use by older versions of 63 <span><strong class="command">dnssec-signzone</strong></span>. 64 </p></dd> 65<dt><span class="term">-d <em class="replaceable"><code>directory</code></em></span></dt> 66<dd><p> 67 Look for <code class="filename">dsset-</code> or 68 <code class="filename">keyset-</code> files in <code class="option">directory</code>. 69 </p></dd> 70<dt><span class="term">-E <em class="replaceable"><code>engine</code></em></span></dt> 71<dd><p> 72 Uses a crypto hardware (OpenSSL engine) for the crypto operations 73 it supports, for instance signing with private keys from 74 a secure key store. When compiled with PKCS#11 support 75 it defaults to pkcs11; the empty name resets it to no engine. 76 </p></dd> 77<dt><span class="term">-g</span></dt> 78<dd><p> 79 Generate DS records for child zones from 80 <code class="filename">dsset-</code> or <code class="filename">keyset-</code> 81 file. Existing DS records will be removed. 82 </p></dd> 83<dt><span class="term">-K <em class="replaceable"><code>directory</code></em></span></dt> 84<dd><p> 85 Key repository: Specify a directory to search for DNSSEC keys. 86 If not specified, defaults to the current directory. 87 </p></dd> 88<dt><span class="term">-k <em class="replaceable"><code>key</code></em></span></dt> 89<dd><p> 90 Treat specified key as a key signing key ignoring any 91 key flags. This option may be specified multiple times. 92 </p></dd> 93<dt><span class="term">-l <em class="replaceable"><code>domain</code></em></span></dt> 94<dd><p> 95 Generate a DLV set in addition to the key (DNSKEY) and DS sets. 96 The domain is appended to the name of the records. 97 </p></dd> 98<dt><span class="term">-s <em class="replaceable"><code>start-time</code></em></span></dt> 99<dd><p> 100 Specify the date and time when the generated RRSIG records 101 become valid. This can be either an absolute or relative 102 time. An absolute start time is indicated by a number 103 in YYYYMMDDHHMMSS notation; 20000530144500 denotes 104 14:45:00 UTC on May 30th, 2000. A relative start time is 105 indicated by +N, which is N seconds from the current time. 106 If no <code class="option">start-time</code> is specified, the current 107 time minus 1 hour (to allow for clock skew) is used. 108 </p></dd> 109<dt><span class="term">-e <em class="replaceable"><code>end-time</code></em></span></dt> 110<dd><p> 111 Specify the date and time when the generated RRSIG records 112 expire. As with <code class="option">start-time</code>, an absolute 113 time is indicated in YYYYMMDDHHMMSS notation. A time relative 114 to the start time is indicated with +N, which is N seconds from 115 the start time. A time relative to the current time is 116 indicated with now+N. If no <code class="option">end-time</code> is 117 specified, 30 days from the start time is used as a default. 118 <code class="option">end-time</code> must be later than 119 <code class="option">start-time</code>. 120 </p></dd> 121<dt><span class="term">-f <em class="replaceable"><code>output-file</code></em></span></dt> 122<dd><p> 123 The name of the output file containing the signed zone. The 124 default is to append <code class="filename">.signed</code> to 125 the 126 input filename. 127 </p></dd> 128<dt><span class="term">-h</span></dt> 129<dd><p> 130 Prints a short summary of the options and arguments to 131 <span><strong class="command">dnssec-signzone</strong></span>. 132 </p></dd> 133<dt><span class="term">-i <em class="replaceable"><code>interval</code></em></span></dt> 134<dd> 135<p> 136 When a previously-signed zone is passed as input, records 137 may be resigned. The <code class="option">interval</code> option 138 specifies the cycle interval as an offset from the current 139 time (in seconds). If a RRSIG record expires after the 140 cycle interval, it is retained. Otherwise, it is considered 141 to be expiring soon, and it will be replaced. 142 </p> 143<p> 144 The default cycle interval is one quarter of the difference 145 between the signature end and start times. So if neither 146 <code class="option">end-time</code> or <code class="option">start-time</code> 147 are specified, <span><strong class="command">dnssec-signzone</strong></span> 148 generates 149 signatures that are valid for 30 days, with a cycle 150 interval of 7.5 days. Therefore, if any existing RRSIG records 151 are due to expire in less than 7.5 days, they would be 152 replaced. 153 </p> 154</dd> 155<dt><span class="term">-I <em class="replaceable"><code>input-format</code></em></span></dt> 156<dd><p> 157 The format of the input zone file. 158 Possible formats are <span><strong class="command">"text"</strong></span> (default) 159 and <span><strong class="command">"raw"</strong></span>. 160 This option is primarily intended to be used for dynamic 161 signed zones so that the dumped zone file in a non-text 162 format containing updates can be signed directly. 163 The use of this option does not make much sense for 164 non-dynamic zones. 165 </p></dd> 166<dt><span class="term">-j <em class="replaceable"><code>jitter</code></em></span></dt> 167<dd> 168<p> 169 When signing a zone with a fixed signature lifetime, all 170 RRSIG records issued at the time of signing expires 171 simultaneously. If the zone is incrementally signed, i.e. 172 a previously-signed zone is passed as input to the signer, 173 all expired signatures have to be regenerated at about the 174 same time. The <code class="option">jitter</code> option specifies a 175 jitter window that will be used to randomize the signature 176 expire time, thus spreading incremental signature 177 regeneration over time. 178 </p> 179<p> 180 Signature lifetime jitter also to some extent benefits 181 validators and servers by spreading out cache expiration, 182 i.e. if large numbers of RRSIGs don't expire at the same time 183 from all caches there will be less congestion than if all 184 validators need to refetch at mostly the same time. 185 </p> 186</dd> 187<dt><span class="term">-n <em class="replaceable"><code>ncpus</code></em></span></dt> 188<dd><p> 189 Specifies the number of threads to use. By default, one 190 thread is started for each detected CPU. 191 </p></dd> 192<dt><span class="term">-N <em class="replaceable"><code>soa-serial-format</code></em></span></dt> 193<dd> 194<p> 195 The SOA serial number format of the signed zone. 196 Possible formats are <span><strong class="command">"keep"</strong></span> (default), 197 <span><strong class="command">"increment"</strong></span> and 198 <span><strong class="command">"unixtime"</strong></span>. 199 </p> 200<div class="variablelist"><dl> 201<dt><span class="term"><span><strong class="command">"keep"</strong></span></span></dt> 202<dd><p>Do not modify the SOA serial number.</p></dd> 203<dt><span class="term"><span><strong class="command">"increment"</strong></span></span></dt> 204<dd><p>Increment the SOA serial number using RFC 1982 205 arithmetics.</p></dd> 206<dt><span class="term"><span><strong class="command">"unixtime"</strong></span></span></dt> 207<dd><p>Set the SOA serial number to the number of seconds 208 since epoch.</p></dd> 209</dl></div> 210</dd> 211<dt><span class="term">-o <em class="replaceable"><code>origin</code></em></span></dt> 212<dd><p> 213 The zone origin. If not specified, the name of the zone file 214 is assumed to be the origin. 215 </p></dd> 216<dt><span class="term">-O <em class="replaceable"><code>output-format</code></em></span></dt> 217<dd><p> 218 The format of the output file containing the signed zone. 219 Possible formats are <span><strong class="command">"text"</strong></span> (default) 220 and <span><strong class="command">"raw"</strong></span>. 221 </p></dd> 222<dt><span class="term">-p</span></dt> 223<dd><p> 224 Use pseudo-random data when signing the zone. This is faster, 225 but less secure, than using real random data. This option 226 may be useful when signing large zones or when the entropy 227 source is limited. 228 </p></dd> 229<dt><span class="term">-P</span></dt> 230<dd> 231<p> 232 Disable post sign verification tests. 233 </p> 234<p> 235 The post sign verification test ensures that for each algorithm 236 in use there is at least one non revoked self signed KSK key, 237 that all revoked KSK keys are self signed, and that all records 238 in the zone are signed by the algorithm. 239 This option skips these tests. 240 </p> 241</dd> 242<dt><span class="term">-r <em class="replaceable"><code>randomdev</code></em></span></dt> 243<dd><p> 244 Specifies the source of randomness. If the operating 245 system does not provide a <code class="filename">/dev/random</code> 246 or equivalent device, the default source of randomness 247 is keyboard input. <code class="filename">randomdev</code> 248 specifies 249 the name of a character device or file containing random 250 data to be used instead of the default. The special value 251 <code class="filename">keyboard</code> indicates that keyboard 252 input should be used. 253 </p></dd> 254<dt><span class="term">-S</span></dt> 255<dd> 256<p> 257 Smart signing: Instructs <span><strong class="command">dnssec-signzone</strong></span> to 258 search the key repository for keys that match the zone being 259 signed, and to include them in the zone if appropriate. 260 </p> 261<p> 262 When a key is found, its timing metadata is examined to 263 determine how it should be used, according to the following 264 rules. Each successive rule takes priority over the prior 265 ones: 266 </p> 267<div class="variablelist"><dl> 268<dt></dt> 269<dd><p> 270 If no timing metadata has been set for the key, the key is 271 published in the zone and used to sign the zone. 272 </p></dd> 273<dt></dt> 274<dd><p> 275 If the key's publication date is set and is in the past, the 276 key is published in the zone. 277 </p></dd> 278<dt></dt> 279<dd><p> 280 If the key's activation date is set and in the past, the 281 key is published (regardless of publication date) and 282 used to sign the zone. 283 </p></dd> 284<dt></dt> 285<dd><p> 286 If the key's revocation date is set and in the past, and the 287 key is published, then the key is revoked, and the revoked key 288 is used to sign the zone. 289 </p></dd> 290<dt></dt> 291<dd><p> 292 If either of the key's unpublication or deletion dates are set 293 and in the past, the key is NOT published or used to sign the 294 zone, regardless of any other metadata. 295 </p></dd> 296</dl></div> 297</dd> 298<dt><span class="term">-T <em class="replaceable"><code>ttl</code></em></span></dt> 299<dd><p> 300 Specifies the TTL to be used for new DNSKEY records imported 301 into the zone from the key repository. If not specified, 302 the default is the minimum TTL value from the zone's SOA 303 record. This option is ignored when signing without 304 <code class="option">-S</code>, since DNSKEY records are not imported 305 from the key repository in that case. It is also ignored if 306 there are any pre-existing DNSKEY records at the zone apex, 307 in which case new records' TTL values will be set to match 308 them. 309 </p></dd> 310<dt><span class="term">-t</span></dt> 311<dd><p> 312 Print statistics at completion. 313 </p></dd> 314<dt><span class="term">-u</span></dt> 315<dd><p> 316 Update NSEC/NSEC3 chain when re-signing a previously signed 317 zone. With this option, a zone signed with NSEC can be 318 switched to NSEC3, or a zone signed with NSEC3 can 319 be switch to NSEC or to NSEC3 with different parameters. 320 Without this option, <span><strong class="command">dnssec-signzone</strong></span> will 321 retain the existing chain when re-signing. 322 </p></dd> 323<dt><span class="term">-v <em class="replaceable"><code>level</code></em></span></dt> 324<dd><p> 325 Sets the debugging level. 326 </p></dd> 327<dt><span class="term">-x</span></dt> 328<dd><p> 329 Only sign the DNSKEY RRset with key-signing keys, and omit 330 signatures from zone-signing keys. (This is similar to the 331 <span><strong class="command">dnssec-dnskey-kskonly yes;</strong></span> zone option in 332 <span><strong class="command">named</strong></span>.) 333 </p></dd> 334<dt><span class="term">-z</span></dt> 335<dd><p> 336 Ignore KSK flag on key when determining what to sign. This 337 causes KSK-flagged keys to sign all records, not just the 338 DNSKEY RRset. (This is similar to the 339 <span><strong class="command">update-check-ksk no;</strong></span> zone option in 340 <span><strong class="command">named</strong></span>.) 341 </p></dd> 342<dt><span class="term">-3 <em class="replaceable"><code>salt</code></em></span></dt> 343<dd><p> 344 Generate an NSEC3 chain with the given hex encoded salt. 345 A dash (<em class="replaceable"><code>salt</code></em>) can 346 be used to indicate that no salt is to be used when generating the NSEC3 chain. 347 </p></dd> 348<dt><span class="term">-H <em class="replaceable"><code>iterations</code></em></span></dt> 349<dd><p> 350 When generating an NSEC3 chain, use this many interations. The 351 default is 10. 352 </p></dd> 353<dt><span class="term">-A</span></dt> 354<dd> 355<p> 356 When generating an NSEC3 chain set the OPTOUT flag on all 357 NSEC3 records and do not generate NSEC3 records for insecure 358 delegations. 359 </p> 360<p> 361 Using this option twice (i.e., <code class="option">-AA</code>) 362 turns the OPTOUT flag off for all records. This is useful 363 when using the <code class="option">-u</code> option to modify an NSEC3 364 chain which previously had OPTOUT set. 365 </p> 366</dd> 367<dt><span class="term">zonefile</span></dt> 368<dd><p> 369 The file containing the zone to be signed. 370 </p></dd> 371<dt><span class="term">key</span></dt> 372<dd><p> 373 Specify which keys should be used to sign the zone. If 374 no keys are specified, then the zone will be examined 375 for DNSKEY records at the zone apex. If these are found and 376 there are matching private keys, in the current directory, 377 then these will be used for signing. 378 </p></dd> 379</dl></div> 380</div> 381<div class="refsect1" lang="en"> 382<a name="id2544965"></a><h2>EXAMPLE</h2> 383<p> 384 The following command signs the <strong class="userinput"><code>example.com</code></strong> 385 zone with the DSA key generated by <span><strong class="command">dnssec-keygen</strong></span> 386 (Kexample.com.+003+17247). Because the <span><strong class="command">-S</strong></span> option 387 is not being used, the zone's keys must be in the master file 388 (<code class="filename">db.example.com</code>). This invocation looks 389 for <code class="filename">dsset</code> files, in the current directory, 390 so that DS records can be imported from them (<span><strong class="command">-g</strong></span>). 391 </p> 392<pre class="programlisting">% dnssec-signzone -g -o example.com db.example.com \ 393Kexample.com.+003+17247 394db.example.com.signed 395%</pre> 396<p> 397 In the above example, <span><strong class="command">dnssec-signzone</strong></span> creates 398 the file <code class="filename">db.example.com.signed</code>. This 399 file should be referenced in a zone statement in a 400 <code class="filename">named.conf</code> file. 401 </p> 402<p> 403 This example re-signs a previously signed zone with default parameters. 404 The private keys are assumed to be in the current directory. 405 </p> 406<pre class="programlisting">% cp db.example.com.signed db.example.com 407% dnssec-signzone -o example.com db.example.com 408db.example.com.signed 409%</pre> 410</div> 411<div class="refsect1" lang="en"> 412<a name="id2545020"></a><h2>SEE ALSO</h2> 413<p><span class="citerefentry"><span class="refentrytitle">dnssec-keygen</span>(8)</span>, 414 <em class="citetitle">BIND 9 Administrator Reference Manual</em>, 415 <em class="citetitle">RFC 4033</em>. 416 </p> 417</div> 418<div class="refsect1" lang="en"> 419<a name="id2545045"></a><h2>AUTHOR</h2> 420<p><span class="corpauthor">Internet Systems Consortium</span> 421 </p> 422</div> 423</div></body> 424</html> 425