freebsd-dev/contrib/bind/doc/notes/data
Peter Wemm 6b6ac9438f Import bind v8.2.2.p5, minus the crypto for the time being. The bind
package does have BXA export approval, but the licensing strings on the
dnssafe code are a bit unpleasant.  The crypto is easy to restore and bind
will run without it - just without full dnssec support.

Obtained from:	The Internet Software Consortium (www.isc.org)
1999-11-30 02:43:11 +00:00

52 lines
1.3 KiB
Plaintext

/*
* We need a registy of name server addresses. For each, we retain an RTT
* and a list of name server names which have used this address.
*/
tree_t *by_nsaddr;
struct by_nsaddr {
u_int32_t rtt; /* measured. */
char **names; /* NULL terminated array; strdup'd. */
};
/*
* "struct server" is a name server, which can have many addresses. There
* is no central registry of servers, since each creator can have a different
* idea of what the addresses are.
*/
struct server {
char *name; /* made with strdup. */
struct sockaddr_in *addrs; /* counted array. */
int n_addrs; /* array size. */
};
/*
* "struct zone" is a zone cut.
*/
tree_t *by_class; /* zone[class]. */
struct zone {
enum {master, slave, cache, boot}
type;
/* Servers learned from boot cache, a parent zone, or !auth answer. */
struct server *servers_notauth;
/* Servers learned from authoritative answer or local zone. */
struct server *servers_auth;
/* Root node of zone. */
struct node *root;
};
struct node {
char *label; /* made with strdup. */
tree_t *subs; /* subdomains (node[label]). */
/* really this is "data" since for the zone cut tree we have no sets.*/
tree_t *rrsets; /* rr sets (rrset[type]). */
};
struct rrset {
rrtype type;
u_int32_t ttl;
u_char data[1]; /* struct size constrains this. */
};