Dns Namespace Reference

generic DNS API

Classes

class  CachedIp
 a CachedIps element More...
 
class  CachedIps
 
class  ConfigRr
 manage DNS internal component More...
 
class  GoodIpsIterator
 Iterates over good IPs in CachedIps, starting at the so called current one. More...
 
class  IpReceiver
 an interface for receiving IP::Addresses from nbgethostbyname() More...
 
class  IpsIterator
 Iterates over any (good and/or bad) IPs in CachedIps, in unspecified order. More...
 
class  IpsSelector
 
class  LookupDetails
 encapsulates DNS lookup results More...
 

Typedefs

using DomainName = SBuf
 

Functions

void Init (void)
 
std::ostream & operator<< (std::ostream &os, const LookupDetails &dns)
 
void nbgethostbyname (const char *name, const CbcPointer< IpReceiver > &receiver)
 initiate an (often) asynchronous DNS lookup; the receiver gets the results More...
 
std::ostream & operator<< (std::ostream &os, const CachedIps &ips)
 

Variables

bool ResolveClientAddressesAsap = false
 whether to do reverse DNS lookups for source IPs of accepted connections More...
 

Typedef Documentation

◆ DomainName

using Dns::DomainName = typedef SBuf

A DNS domain name as described in RFC 1034 and RFC 1035.

The object creator is responsible for removing any encodings (e.g., URI percent-encoding) other than ASCII Compatible Encoding (ACE; RFC 5890) prior to creating a DomainName object. Domain names are stored as dot-separated ASCII substrings, with each substring representing a domain name label. DomainName strings are suitable for creating DNS queries and byte-by-byte case-insensitive comparison with configured dstdomain ACL parameters.

Even though an empty domain name is valid in DNS, DomainName objects are never empty.

The first label of a DomainName object may be a "*" wildcard (RFC 9525 Section 6.3) if and only if the object creator explicitly allows wildcards.

Definition at line 41 of file forward.h.

Function Documentation

◆ Init()

◆ nbgethostbyname()

void Dns::nbgethostbyname ( const char *  name,
const CbcPointer< IpReceiver > &  receiver 
)

Definition at line 616 of file ipcache.cc.

References debugs, and ipcache_nbgethostbyname_().

Referenced by PeerSelector::resolveSelected().

◆ operator<<() [1/2]

std::ostream& Dns::operator<< ( std::ostream &  os,
const CachedIps ips 
)
inline

Definition at line 217 of file ipcache.h.

References Dns::CachedIps::reportCurrent().

◆ operator<<() [2/2]

std::ostream& Dns::operator<< ( std::ostream &  os,
const LookupDetails dns 
)
inline

Definition at line 44 of file LookupDetails.h.

References Dns::LookupDetails::print().

Variable Documentation

◆ ResolveClientAddressesAsap

bool Dns::ResolveClientAddressesAsap = false

 

Introduction

Documentation

Support

Miscellaneous