]> git.ipfire.org Git - thirdparty/ldns.git/commitdiff
Fix manpage & DS key generation for new HMACs
authorWillem Toorop <willem@nlnetlabs.nl>
Mon, 31 Oct 2016 13:01:08 +0000 (14:01 +0100)
committerWillem Toorop <willem@nlnetlabs.nl>
Mon, 31 Oct 2016 13:01:08 +0000 (14:01 +0100)
Thanks Harald Jenny

examples/ldns-keygen.1
examples/ldns-keygen.c

index 734ad6d163600bbf9534c1d55cc263c29737fd5d..fea30d88088b50c7d92a9599cbfd7b2ba1575fef 100644 (file)
@@ -16,7 +16,7 @@ DNSKEY record.
 
 \fBldns-keygen\fR can also be used to create symmetric keys (for TSIG) by
 selecting the appropriate algorithm: \%\fIhmac-md5.sig-alg.reg.int\fR,
-\%\fIhmac-sha1\fR or \%\fIhmac-sha256\fR.
+\%\fIhmac-sha1\fR, \%\fIhmac-sha224\fR, \%\fIhmac-sha256\fR, \%\fIhmac-sha385\fR or \%\fIhmac-sha512\fR.
 In that case no DS record will be created and no .ds file.
 
 \fBldns-keygen\fR prints the basename for the key files:
index e6088fbb316d927cb64fa8460aaa29d55410ba7d..62b8d228eda67d5177c8d92491dd2bb28be7e594 100644 (file)
@@ -345,7 +345,10 @@ main(int argc, char *argv[])
        /* print the DS to .ds */
        if (ksk && algorithm != LDNS_SIGN_HMACMD5 &&
                algorithm != LDNS_SIGN_HMACSHA1 &&
-               algorithm != LDNS_SIGN_HMACSHA256) {
+               algorithm != LDNS_SIGN_HMACSHA224 &&
+               algorithm != LDNS_SIGN_HMACSHA256 &&
+               algorithm != LDNS_SIGN_HMACSHA384 &&
+               algorithm != LDNS_SIGN_HMACSHA512) {
                filename = LDNS_XMALLOC(char, strlen(owner) + 16);
                snprintf(filename, strlen(owner) + 15, "K%s+%03u+%05u.ds", owner, algorithm, (unsigned int) ldns_key_keytag(key));
                file = fopen(filename, "w");