]> git.ipfire.org Git - thirdparty/ldns.git/commitdiff
fix private key write and read
authorWouter Wijngaards <wouter@NLnetLabs.nl>
Mon, 10 Aug 2009 14:10:03 +0000 (14:10 +0000)
committerWouter Wijngaards <wouter@NLnetLabs.nl>
Mon, 10 Aug 2009 14:10:03 +0000 (14:10 +0000)
host2str.c
keys.c

index c7d52c288d5d05796aa3df8dabc81489a0388701..09593961af13f897669e1f5e5c818f1f14dd3257 100644 (file)
@@ -1665,7 +1665,7 @@ ldns_key2buffer_str(ldns_buffer *output, const ldns_key *k)
                                /* no format defined, use blob */
 #if defined(HAVE_SSL) && defined(USE_GOST)
                                ldns_buffer_printf(output, "Private-key-format: v1.2\n");
-                               ldns_buffer_printf(output, "Algorithm: 11 (GOST)\n");
+                               ldns_buffer_printf(output, "Algorithm: 211 (GOST)\n");
                                status = ldns_gost_key2buffer_str(output, k->_key.key);
 #endif
                                break;
diff --git a/keys.c b/keys.c
index cf1a99f29090fbd054ed64f2d149422333a5520d..2c5172a8673be0ea6cd788ef9d86bd4aaa7311b2 100644 (file)
--- a/keys.c
+++ b/keys.c
@@ -260,7 +260,7 @@ ldns_key_new_frm_fp_l(ldns_key **key, FILE *fp, int *line_nr)
                fprintf(stderr, "version of ldns\n");
 #endif
        }
-       if (strncmp(d, "11 GOST", 3) == 0) {
+       if (strncmp(d, "211 GOST", 4) == 0) {
 #ifdef USE_GOST
                alg = LDNS_SIGN_GOST;
 #else