Changeset 164 for trunk/pdns/pdns/packethandler.cc
- Timestamp:
- 03/20/03 14:29:29 (10 years ago)
- Files:
-
- 1 modified
-
trunk/pdns/pdns/packethandler.cc (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pdns/pdns/packethandler.cc
r161 r164 155 155 156 156 if (p->qclass == 3 && p->qtype.getName() == "HINFO") { 157 rr.content = "PowerDNS $Id: packethandler.cc,v 1.1 2 2003/03/17 13:44:53ahu Exp $";157 rr.content = "PowerDNS $Id: packethandler.cc,v 1.13 2003/03/20 13:29:29 ahu Exp $"; 158 158 rr.ttl = 5; 159 159 rr.qname=target; … … 171 171 DNSResourceRecord rr; 172 172 if(p->qtype.getCode()==QType::TXT && target=="version.bind") {// TXT 173 rr.content="Served by POWERDNS "VERSION" $Id: packethandler.cc,v 1.1 2 2003/03/17 13:44:53ahu Exp $";173 rr.content="Served by POWERDNS "VERSION" $Id: packethandler.cc,v 1.13 2003/03/20 13:29:29 ahu Exp $"; 174 174 rr.ttl=5; 175 175 rr.qname=target; … … 304 304 DLOG(L<<Logger::Warning<<"This packet needs additional processing!"<<endl); 305 305 306 vector<DNSResourceRecord > arrs=r->getAPRecords();307 for(vector<DNSResourceRecord >::const_iterator i=arrs.begin();306 vector<DNSResourceRecord *> arrs=r->getAPRecords(); 307 for(vector<DNSResourceRecord *>::const_iterator i=arrs.begin(); 308 308 i!=arrs.end(); 309 309 ++i) { 310 310 311 if( r->d.aa && i->qtype.getCode()==QType::NS && !B.getSOA(i->qname,sd))// drop AA in case of non-SOA-level NS answer311 if((*i)->qtype.getCode()==QType::NS && !B.getSOA((*i)->qname,sd)) { // drop AA in case of non-SOA-level NS answer 312 312 r->d.aa=false; 313 (*i)->d_place=DNSResourceRecord::AUTHORITY; 314 } 313 315 314 316 QType qtypes[2]; 315 317 qtypes[0]="A"; qtypes[1]="AAAA"; 316 318 for(int n=0;n < d_doIPv6AdditionalProcessing + 1; ++n) { 317 B.lookup(qtypes[n], i->content,p);319 B.lookup(qtypes[n],(*i)->content,p); 318 320 bool foundOne=false; 319 321 while(B.get(rr)) { 320 322 foundOne=true; 321 if(rr.domain_id!= i->domain_id && arg()["out-of-zone-additional-processing"]=="no") {322 DLOG(L<<Logger::Warning<<"Not including out-of-zone additional processing of "<< i->qname<<" ("<<rr.qname<<")"<<endl);323 if(rr.domain_id!=(*i)->domain_id && arg()["out-of-zone-additional-processing"]=="no") { 324 DLOG(L<<Logger::Warning<<"Not including out-of-zone additional processing of "<<(*i)->qname<<" ("<<rr.qname<<")"<<endl); 323 325 continue; // not adding out-of-zone additional data 324 326 } … … 332 334 try { 333 335 Resolver resolver; 334 resolver.resolve(arg()["recursor"], i->content.c_str(),QType::A);336 resolver.resolve(arg()["recursor"],(*i)->content.c_str(),QType::A); 335 337 Resolver::res_t res=resolver.result(); 336 338 for(Resolver::res_t::const_iterator j=res.begin();j!=res.end();++j) {