summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-packet.c
diff options
context:
space:
mode:
authorTom Gundersen <teg@jklm.no>2015-07-23 13:28:09 +0200
committerTom Gundersen <teg@jklm.no>2015-07-23 18:06:50 +0200
commit0bbd72b2f3d79b5f15ae1fa7d1fea6e579eeef97 (patch)
treec6e170b73d3743ec5aeb6d7a22873e4717567f8b /src/resolve/resolved-dns-packet.c
parent89492aaf99a59b2858e71ebc30f3e123e7c6734c (diff)
resolved: rr - fix parsing of NSEC3
We were appending rather than reading the bitmap.
Diffstat (limited to 'src/resolve/resolved-dns-packet.c')
-rw-r--r--src/resolve/resolved-dns-packet.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c
index 25035ed7ee..b76f981906 100644
--- a/src/resolve/resolved-dns-packet.c
+++ b/src/resolve/resolved-dns-packet.c
@@ -1712,10 +1712,12 @@ int dns_packet_read_rr(DnsPacket *p, DnsResourceRecord **ret, size_t *start) {
if (r < 0)
goto fail;
- r = dns_packet_append_types(p, rr->nsec3.types, NULL);
+ r = dns_packet_read_type_windows(p, &rr->nsec.types, offset + rdlength - p->rindex, NULL);
if (r < 0)
goto fail;
+ /* empty non-terminals can have NSEC3 records, so empty bitmaps are allowed */
+
break;
}
default: