diff options
author | Darren Tucker <dtucker@zip.com.au> | 2012-06-28 15:21:32 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2012-06-28 15:21:32 +1000 |
commit | 8908da7dce7711af59c7f43b122f73293dca27ab (patch) | |
tree | b8e61de67b72d38b6f860fb535d98614a7e84d18 /openbsd-compat/getrrsetbyname-ldns.c | |
parent | 62dcd63f5ed39798b0201cf64223960ded766914 (diff) |
- (dtucker) [openbsd-compat/getrrsetbyname-ldns.c] bz #2022: prevent null
pointer deref in the client when built with LDNS and using DNSSEC with a
CNAME. Patch from gregdlg+mr at hochet info.
Diffstat (limited to 'openbsd-compat/getrrsetbyname-ldns.c')
-rw-r--r-- | openbsd-compat/getrrsetbyname-ldns.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/openbsd-compat/getrrsetbyname-ldns.c b/openbsd-compat/getrrsetbyname-ldns.c index 8ce5678c..19666346 100644 --- a/openbsd-compat/getrrsetbyname-ldns.c +++ b/openbsd-compat/getrrsetbyname-ldns.c @@ -205,7 +205,8 @@ getrrsetbyname(const char *hostname, unsigned int rdclass, } if (rr->_rr_class == rrset->rri_rdclass && - rr->_rr_type == LDNS_RR_TYPE_RRSIG) { + rr->_rr_type == LDNS_RR_TYPE_RRSIG && + rrset->rri_sigs) { rdata = &rrset->rri_sigs[index_sig++]; } |