On 3 Sep 2015, at 22:11, Takae Harrington <thar...@us.ibm.com> wrote:

> When I compile postfix3.0.2 (the same issue has existed since 2.11.x) on 
> aix61 and aix71, I get this error:
> 
> [vq2ua613:/staging/Postfix-3.0.2]make
> dns_lookup.c: In function 'dns_query':
> dns_lookup.c:339: error: 'HEADER' has no member named 'ad'

It looks like the system #include files are broken or out of date. A HEADER 
typedef struct is usually defined in <arpa/nameser_compat.h> which lays out the 
headers found in a DNS query. This should include a field "unsigned ad: 1;" for 
the AD (Authentic Data) bit which is used in Secure DNS. This 1-bit field 
appears to be missing from your include files. It shouldn't.

The AD bit has been part of the DNS protocol since 2005 and is defined in 
RFC4033.

Here's what you should see in that struct definition:

typedef struct {
        unsigned        id :16;         /* query identification number */
#if BYTE_ORDER == BIG_ENDIAN
                        /* fields in third byte */
        unsigned        qr: 1;          /* response flag */
        unsigned        opcode: 4;      /* purpose of message */
        unsigned        aa: 1;          /* authoritive answer */
        unsigned        tc: 1;          /* truncated message */
        unsigned        rd: 1;          /* recursion desired */
                        /* fields in fourth byte */
        unsigned        ra: 1;          /* recursion available */
        unsigned        unused :1;      /* unused bits (MBZ as of 4.9.3a3) */
        unsigned        ad: 1;          /* authentic data from named */
        unsigned        cd: 1;          /* checking disabled by resolver */
        unsigned        rcode :4;       /* response code */
#endif
#if BYTE_ORDER == LITTLE_ENDIAN || BYTE_ORDER == PDP_ENDIAN
                        /* fields in third byte */
        unsigned        rd :1;          /* recursion desired */
        unsigned        tc :1;          /* truncated message */
        unsigned        aa :1;          /* authoritive answer */
        unsigned        opcode :4;      /* purpose of message */
        unsigned        qr :1;          /* response flag */
                        /* fields in fourth byte */
        unsigned        rcode :4;       /* response code */
        unsigned        cd: 1;          /* checking disabled by resolver */
        unsigned        ad: 1;          /* authentic data from named */
        unsigned        unused :1;      /* unused bits (MBZ as of 4.9.3a3) */
        unsigned        ra :1;          /* recursion available */
#endif
                        /* remaining bytes */
        unsigned        qdcount :16;    /* number of question entries */
        unsigned        ancount :16;    /* number of answer entries */
        unsigned        nscount :16;    /* number of authority entries */
        unsigned        arcount :16;    /* number of resource entries */
} HEADER;

Reply via email to