]> git.ipfire.org Git - thirdparty/ldns.git/commitdiff
some nonworking stuff
authorMiek Gieben <miekg@NLnetLabs.nl>
Wed, 16 Mar 2005 12:12:15 +0000 (12:12 +0000)
committerMiek Gieben <miekg@NLnetLabs.nl>
Wed, 16 Mar 2005 12:12:15 +0000 (12:12 +0000)
TODO
host2str.c
rr.c
run-test17.c

diff --git a/TODO b/TODO
index a921e0b0741d495f15e5640bfd98f3cb9646f8ea..54296cd18bb8792daa24f165432bb63e2d7ee101 100644 (file)
--- a/TODO
+++ b/TODO
@@ -15,6 +15,7 @@ o DNSSEC
        - do we call random()?
 o Make a shared library and test compile some programs
 o Thread safety, strtok is used
+o NSEC cannot be converted from str to host fmt
 o ssl autoconf
 o create a bunch of small programs:
        dig
index 739457aa154769dd104550dbf2c812e31a70d5dc..0b92c19aa71b7fdb32a4a50482de019ea9860b13 100644 (file)
@@ -491,7 +491,6 @@ ldns_rdf2buffer_str_nsec(ldns_buffer *output, ldns_rdf *rdf)
                bitmap_length = data[pos+1];
                pos += 2;
                
-
                for (bit_pos = 0; bit_pos < (bitmap_length) * 8; bit_pos++) {
                        if (get_bit(&data[pos], bit_pos)) {
                                type = 256 * (uint16_t) window_block_nr + bit_pos;
diff --git a/rr.c b/rr.c
index e35205e8390f59f2961204b2cfa54bc2ea6b858a..f546c9499df976a591f0c7730fee787a2483ff20 100644 (file)
--- a/rr.c
+++ b/rr.c
@@ -157,7 +157,9 @@ ldns_rr_new_frm_str(const char *str)
        r_max = ldns_rr_descriptor_maximum(desc);
        r_min = ldns_rr_descriptor_minimum(desc);
 
+       /* this breaks with nsec */
        for(rd = strtok(rdata, "\t \0"), r_cnt =0; rd; rd = strtok(NULL, "\t \0"), r_cnt++) {
+               printf("rd found %s\n", rd);
                r = ldns_rdf_new_frm_str(
                        ldns_rr_descriptor_field_type(desc, r_cnt),
                        rd);
index 15eff94cb3f9aed6a118ea334539760514346408..92342e1852e6b9664b0f3644c1b16aa7d5881d7b 100644 (file)
@@ -13,6 +13,7 @@ main(void)
        ldns_rr *key;
        ldns_rr *ds;
        ldns_rdf *ch;
+       ldns_rr *nsec;
 
        key = ldns_rr_new_frm_str("nlnetlabs.nl.   86400   IN      DNSKEY  257 3 RSASHA1 AQPzzTWMz8qSWIQlfRnPckx2BiVmkVN6LPupO3mbz7FhLSnm26n6iG9NLby97Ji453aWZY3M5/xJBSOS2vWtco2t8C0+xeO1bc/d6ZTy32DHchpW6rDH1vp86Ll+ha0tmwyy9QP7y2bVw5zSbFCrefk8qCUBgfHm9bHzMG1UBYtEIQ==");
 
@@ -23,6 +24,8 @@ main(void)
 
        ds = ldns_key_rr2ds(key);
 
+       nsec = ldns_rr_new_frm_str("nlnetlabs.nl.   18000   IN      NSEC    _sip._udp.nlnetlabs.nl. NS SOA MX TXT RRSIG NSEC DNSKEY");
+
        printf("\nand now the DS\n");
        printf("rdata count %d\n", ldns_rr_rd_count(ds));
        ldns_rr_print(stdout, ds);