set<DNSName> authSet;
vector<DNSZoneRecord> rrset;
- bool weDone=0, weRedirected=0, weHaveUnauth=0;
+ bool weDone=0, weRedirected=0, weHaveUnauth=0, doSigs=0;
DNSName haveAlias;
uint8_t aliasScopeMask;
}
DLOG(g_log<<Logger::Error<<"We have authority, zone='"<<sd.qname<<"', id="<<sd.domain_id<<endl);
+ authSet.insert(sd.qname);
d_dnssec=(p->d_dnssecOk && d_dk.isSecuredZone(sd.qname));
- if(d_dnssec) {
- authSet.insert(sd.qname);
- }
+ doSigs |= d_dnssec;
if(!retargetcount) r->qdomainzone=sd.qname;
break;
}
}
- if(authSet.size())
+ if(doSigs)
addRRSigs(d_dk, B, authSet, r->getRRS());
r->wrapup(); // needed for inserting in cache