DNSMSG::section

Description

DNSMSG::section takes an opaque dns_message returned from RESOLVER::name_lookup and the name of a section to extract from the DNS message. It will return that section as a list of rr_objs.
Note: DNSMSG::section does not apply any filter to the section even if one was applied when creating the opaque dns_message. For example, the answer section may contain CNAME records as well as A records even if the RESOLVER::name_lookup specified A records.

Syntax

DNSMSG::section <dns_message> (question|answer|authority|additional)

Examples

when CLIENT_ACCEPTED {
        set result [RESOLVER::name_lookup "/Common/r1" www.abc.com a]
        # extract the answer section from the result
        # this may include CNAME and A records, event though A records were requested
        # to only extract A records, use RESOLVER::summarize
        set answer [DNSMSG::section $result answer]
}