1<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
2               "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
3	       [<!ENTITY mdash "&#8212;">]>
4<!--
5 - Copyright (C) 2010, 2013, 2014  Internet Systems Consortium, Inc. ("ISC")
6 -
7 - Permission to use, copy, modify, and/or distribute this software for any
8 - purpose with or without fee is hereby granted, provided that the above
9 - copyright notice and this permission notice appear in all copies.
10 -
11 - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
12 - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
13 - AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
14 - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
15 - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
16 - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17 - PERFORMANCE OF THIS SOFTWARE.
18-->
19
20<refentry id="man.isc-hmac-fixup">
21  <refentryinfo>
22    <date>April 28, 2013</date>
23  </refentryinfo>
24
25  <refmeta>
26    <refentrytitle><application>isc-hmac-fixup</application></refentrytitle>
27    <manvolnum>8</manvolnum>
28    <refmiscinfo>BIND9</refmiscinfo>
29  </refmeta>
30
31  <refnamediv>
32    <refname><application>isc-hmac-fixup</application></refname>
33    <refpurpose>fixes HMAC keys generated by older versions of BIND</refpurpose>
34  </refnamediv>
35
36  <docinfo>
37    <copyright>
38      <year>2010</year>
39      <year>2013</year>
40      <year>2014</year>
41      <holder>Internet Systems Consortium, Inc. ("ISC")</holder>
42    </copyright>
43  </docinfo>
44
45  <refsynopsisdiv>
46    <cmdsynopsis>
47      <command>isc-hmac-fixup</command>
48      <arg choice="req"><replaceable class="parameter">algorithm</replaceable></arg>
49      <arg choice="req"><replaceable class="parameter">secret</replaceable></arg>
50    </cmdsynopsis>
51  </refsynopsisdiv>
52
53  <refsect1>
54    <title>DESCRIPTION</title>
55    <para>
56      Versions of BIND 9 up to and including BIND 9.6 had a bug causing
57      HMAC-SHA* TSIG keys which were longer than the digest length of the
58      hash algorithm (i.e., SHA1 keys longer than 160 bits, SHA256 keys
59      longer than 256 bits, etc) to be used incorrectly, generating a
60      message authentication code that was incompatible with other DNS
61      implementations.
62    </para>
63    <para>
64      This bug has been fixed in BIND 9.7.  However, the fix may
65      cause incompatibility between older and newer versions of
66      BIND, when using long keys.  <command>isc-hmac-fixup</command>
67      modifies those keys to restore compatibility.
68    </para>
69    <para>
70      To modify a key, run <command>isc-hmac-fixup</command> and
71      specify the key's algorithm and secret on the command line.  If the
72      secret is longer than the digest length of the algorithm (64 bytes
73      for SHA1 through SHA256, or 128 bytes for SHA384 and SHA512), then a
74      new secret will be generated consisting of a hash digest of the old
75      secret.  (If the secret did not require conversion, then it will be
76      printed without modification.)
77    </para>
78  </refsect1>
79
80  <refsect1>
81    <title>SECURITY CONSIDERATIONS</title>
82    <para>
83      Secrets that have been converted by <command>isc-hmac-fixup</command>
84      are shortened, but as this is how the HMAC protocol works in
85      operation anyway, it does not affect security.  RFC 2104 notes,
86      "Keys longer than [the digest length] are acceptable but the
87      extra length would not significantly increase the function
88      strength."
89    </para>
90  </refsect1>
91
92  <refsect1>
93    <title>SEE ALSO</title>
94    <para>
95      <citetitle>BIND 9 Administrator Reference Manual</citetitle>,
96      <citetitle>RFC 2104</citetitle>.
97    </para>
98  </refsect1>
99
100  <refsect1>
101    <title>AUTHOR</title>
102    <para><corpauthor>Internet Systems Consortium</corpauthor>
103    </para>
104  </refsect1>
105
106</refentry><!--
107 - Local variables:
108 - mode: sgml
109 - End:
110-->
111