host2str.h
Go to the documentation of this file.
#ifndef LDNS_HOST2STR_H
#define LDNS_HOST2STR_H
#include <ldns/common.h>
#include <ldns/error.h>
#include <ldns/rr.h>
#include <ldns/rdata.h>
#include <ldns/packet.h>
#include <ldns/buffer.h>
#include <ldns/resolver.h>
#include <ldns/zone.h>
#include <ctype.h>
#include "ldns/util.h"
#ifdef __cplusplus
extern "C" {
#endif
#define LDNS_APL_IP4 1
#define LDNS_APL_IP6 2
#define LDNS_APL_MASK 0x7f
#define LDNS_APL_NEGATION 0x80
/* Flag Name Flag Nr. Has data associated
---------------------------------------------------------------------*/
#define LDNS_COMMENT_NULLS (1 << 0)
#define LDNS_COMMENT_KEY_ID (1 << 1)
#define LDNS_COMMENT_KEY_TYPE (1 << 2)
#define LDNS_COMMENT_KEY_SIZE (1 << 3)
#define LDNS_COMMENT_BUBBLEBABBLE (1 << 4)
#define LDNS_COMMENT_FLAGS (1 << 5)
#define LDNS_COMMENT_NSEC3_CHAIN (1 << 6) /* yes */
#define LDNS_COMMENT_LAYOUT (1 << 7)
#define LDNS_COMMENT_RRSIGS (1 << 8)
#define LDNS_FMT_ZEROIZE_RRSIGS (1 << 9)
#define LDNS_FMT_PAD_SOA_SERIAL (1 << 10)
#define LDNS_FMT_RFC3597 (1 << 11) /* yes */
#define LDNS_FMT_SHORT (1 << 12)
#define LDNS_FMT_FLAGS_WITH_DATA 2
#define LDNS_COMMENT_KEY (LDNS_COMMENT_KEY_ID \
|LDNS_COMMENT_KEY_TYPE\
|LDNS_COMMENT_KEY_SIZE)
struct ldns_struct_output_format
{
int flags;
void *data;
};
typedef struct ldns_struct_output_format ldns_output_format;
struct ldns_struct_output_format_storage
{ int flags;
ldns_rbtree_t* hashmap; /* for LDNS_COMMENT_NSEC3_CHAIN */
ldns_rdf* bitmap; /* for LDNS_FMT_RFC3597 */
};
typedef struct ldns_struct_output_format_storage ldns_output_format_storage;
extern const ldns_output_format *ldns_output_format_nocomments;
extern const ldns_output_format *ldns_output_format_onlykeyids;
extern const ldns_output_format *ldns_output_format_default;
extern const ldns_output_format *ldns_output_format_bubblebabble;
INLINE
ldns_output_format* ldns_output_format_init(ldns_output_format_storage* fmt) {
fmt->flags = ldns_output_format_default->flags;
fmt->hashmap = NULL;
fmt->bitmap = NULL;
return (ldns_output_format*)fmt;
}
INLINE void ldns_output_format_set(ldns_output_format* fmt, int flag) {
fmt->flags |= flag;
}
INLINE void ldns_output_format_clear(ldns_output_format* fmt, int flag) {
fmt->flags &= !flag;
}
ldns_status
ldns_output_format_set_type(ldns_output_format* fmt, ldns_rr_type type);
ldns_status
ldns_output_format_clear_type(ldns_output_format* fmt, ldns_rr_type type);
ldns_status
ldns_pkt_opcode2buffer_str(ldns_buffer *output, ldns_pkt_opcode opcode);
ldns_status
ldns_pkt_rcode2buffer_str(ldns_buffer *output, ldns_pkt_rcode rcode);
ldns_status
ldns_algorithm2buffer_str(ldns_buffer *output,
ldns_algorithm algorithm);
ldns_status
ldns_cert_algorithm2buffer_str(ldns_buffer *output,
ldns_cert_algorithm cert_algorithm);
char *ldns_pkt_opcode2str(ldns_pkt_opcode opcode);
char *ldns_pkt_rcode2str(ldns_pkt_rcode rcode);
char *ldns_pkt_algorithm2str(ldns_algorithm algorithm);
char *ldns_pkt_cert_algorithm2str(ldns_cert_algorithm cert_algorithm);
ldns_status ldns_rdf2buffer_str_a(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_aaaa(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_str(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_b64(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_b32_ext(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_hex(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_type(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_class(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_alg(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rr_type2buffer_str(ldns_buffer *output,
const ldns_rr_type type);
char *ldns_rr_type2str(const ldns_rr_type type);
ldns_status ldns_rr_class2buffer_str(ldns_buffer *output,
const ldns_rr_class klass);
char *ldns_rr_class2str(const ldns_rr_class klass);
ldns_status ldns_rdf2buffer_str_cert_alg(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_loc(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_unknown(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_nsap(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_atma(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_wks(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_nsec(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_period(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_tsigtime(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_apl(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_int16_data(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_ipseckey(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rr2buffer_str(ldns_buffer *output, const ldns_rr *rr);
ldns_status ldns_rr2buffer_str_fmt(ldns_buffer *output,
const ldns_output_format *fmt, const ldns_rr *rr);
ldns_status ldns_pkt2buffer_str(ldns_buffer *output, const ldns_pkt *pkt);
ldns_status ldns_edns_option_list2buffer_str(ldns_buffer *output,
ldns_edns_option_list* edns_list);
ldns_status ldns_pkt2buffer_str_fmt(ldns_buffer *output,
const ldns_output_format *fmt, const ldns_pkt *pkt);
ldns_status ldns_rdf2buffer_str_nsec3_salt(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_key2buffer_str(ldns_buffer *output, const ldns_key *k);
ldns_status ldns_rdf2buffer_str_int8(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_int16(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_int32(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_time(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_ilnp64(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_eui48(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_eui64(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_tag(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_long_str(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_hip(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_amtrelay(ldns_buffer *output,
const ldns_rdf *rdf);
ldns_status ldns_rdf2buffer_str_svcparams(ldns_buffer *output,
const ldns_rdf *rdf);
char *ldns_rdf2str(const ldns_rdf *rdf);
char *ldns_rr2str(const ldns_rr *rr);
char *ldns_rr2str_fmt(const ldns_output_format *fmt, const ldns_rr *rr);
char *ldns_pkt2str(const ldns_pkt *pkt);
char *ldns_pkt2str_fmt(const ldns_output_format *fmt, const ldns_pkt *pkt);
char *ldns_key2str(const ldns_key *k);
char *ldns_rr_list2str(const ldns_rr_list *rr_list);
char *ldns_rr_list2str_fmt(
const ldns_output_format *fmt, const ldns_rr_list *rr_list);
char *ldns_buffer2str(ldns_buffer *buffer);
char *ldns_buffer_export2str(ldns_buffer *buffer);
void ldns_rdf_print(FILE *output, const ldns_rdf *rdf);
void ldns_rr_print(FILE *output, const ldns_rr *rr);
void ldns_rr_print_fmt(FILE *output,
const ldns_output_format *fmt, const ldns_rr *rr);
void ldns_pkt_print(FILE *output, const ldns_pkt *pkt);
void ldns_pkt_print_fmt(FILE *output,
const ldns_output_format *fmt, const ldns_pkt *pkt);
ldns_status ldns_rr_list2buffer_str(ldns_buffer *output, const ldns_rr_list *list);
ldns_status ldns_rr_list2buffer_str_fmt(ldns_buffer *output,
const ldns_output_format *fmt, const ldns_rr_list *list);
ldns_status ldns_pktheader2buffer_str(ldns_buffer *output, const ldns_pkt *pkt);
void ldns_rr_list_print(FILE *output, const ldns_rr_list *list);
void ldns_rr_list_print_fmt(FILE *output,
const ldns_output_format *fmt, const ldns_rr_list *list);
void ldns_resolver_print(FILE *output, const ldns_resolver *r);
void ldns_resolver_print_fmt(FILE *output,
const ldns_output_format *fmt, const ldns_resolver *r);
void ldns_zone_print(FILE *output, const ldns_zone *z);
void ldns_zone_print_fmt(FILE *output,
const ldns_output_format *fmt, const ldns_zone *z);
ldns_status ldns_rdf2buffer_str_dname(ldns_buffer *output, const ldns_rdf *dname);
#ifdef __cplusplus
}
#endif
#endif /* LDNS_HOST2STR_H */
buffer.h
This file contains the definition of ldns_buffer, and functions to manipulate those.
ldns_buffer
struct ldns_struct_buffer ldns_buffer
Definition buffer.h:72
common.h
Common definitions for LDNS.
ldns_edns_option_list
struct ldns_struct_edns_option_list ldns_edns_option_list
Definition edns.h:115
error.h
Defines error numbers and functions to translate those to a readable string.
ldns_status
enum ldns_enum_status ldns_status
Definition error.h:148
ldns_pkt2str_fmt
char * ldns_pkt2str_fmt(const ldns_output_format *fmt, const ldns_pkt *pkt)
Converts the data in the DNS packet to presentation format and returns that as a char *.
Definition host2str.c:3317
ldns_rr2buffer_str
ldns_status ldns_rr2buffer_str(ldns_buffer *output, const ldns_rr *rr)
Converts the data in the resource record to presentation format (as char *) and appends it to the giv...
Definition host2str.c:2033
ldns_rdf2buffer_str_hip
ldns_status ldns_rdf2buffer_str_hip(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_HIP rdata element to presentation format for the algorithm,...
Definition host2str.c:1265
ldns_rdf2buffer_str_wks
ldns_status ldns_rdf2buffer_str_wks(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_WKS rdata element to string format and adds it to the output buffer.
Definition host2str.c:817
ldns_output_format_nocomments
const ldns_output_format * ldns_output_format_nocomments
Standard output format record that disables commenting in the textual representation of Resource Reco...
Definition host2str.c:135
ldns_rr_list2str_fmt
char * ldns_rr_list2str_fmt(const ldns_output_format *fmt, const ldns_rr_list *rr_list)
Converts a list of resource records to presentation format and returns that as a char *.
Definition host2str.c:3359
ldns_key2str
char * ldns_key2str(const ldns_key *k)
Converts a private key to the test presentation fmt and returns that as a char *.
Definition host2str.c:3342
ldns_pkt_cert_algorithm2str
char * ldns_pkt_cert_algorithm2str(ldns_cert_algorithm cert_algorithm)
Converts a cert algorithm to its mnemonic and returns that as an allocated null-terminated string.
Definition host2str.c:314
ldns_key2buffer_str
ldns_status ldns_key2buffer_str(ldns_buffer *output, const ldns_key *k)
Converts the data in the DNS packet to presentation format (as char *) and appends it to the given bu...
Definition host2str.c:2961
ldns_rdf2buffer_str_int32
ldns_status ldns_rdf2buffer_str_int32(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_INT32 rdata element to string format and adds it to the output buffer.
Definition host2str.c:405
ldns_edns_option_list2buffer_str
ldns_status ldns_edns_option_list2buffer_str(ldns_buffer *output, ldns_edns_option_list *edns_list)
Converts the list of EDNS options to presentation format (as char *) and appends it to the given buff...
Definition host2str.c:2609
ldns_rdf2buffer_str_hex
ldns_status ldns_rdf2buffer_str_hex(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_HEX rdata element to string format and adds it to the output buffer.
Definition host2str.c:530
ldns_pkt_opcode2str
char * ldns_pkt_opcode2str(ldns_pkt_opcode opcode)
Converts a packet opcode to its mnemonic and returns that as an allocated null-terminated string.
Definition host2str.c:253
ldns_rdf2buffer_str_str
ldns_status ldns_rdf2buffer_str_str(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_STR rdata element to string format and adds it to the output buffer.
Definition host2str.c:471
ldns_pkt_rcode2buffer_str
ldns_status ldns_pkt_rcode2buffer_str(ldns_buffer *output, ldns_pkt_rcode rcode)
Converts an ldns packet rcode value to its mnemonic, and adds that to the output buffer.
Definition host2str.c:212
ldns_rr2str
char * ldns_rr2str(const ldns_rr *rr)
Converts the data in the resource record to presentation format and returns that as a char *.
Definition host2str.c:3311
ldns_rdf2buffer_str_loc
ldns_status ldns_rdf2buffer_str_loc(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_LOC rdata element to string format and adds it to the output buffer.
Definition host2str.c:705
ldns_rdf2buffer_str_apl
ldns_status ldns_rdf2buffer_str_apl(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_APL rdata element to string format and adds it to the output buffer.
Definition host2str.c:973
ldns_rdf2buffer_str_nsap
ldns_status ldns_rdf2buffer_str_nsap(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_NSAP rdata element to string format and adds it to the output buffer.
Definition host2str.c:804
ldns_rdf2buffer_str_b64
ldns_status ldns_rdf2buffer_str_b64(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_B64 rdata element to string format and adds it to the output buffer.
Definition host2str.c:487
ldns_rdf2buffer_str_type
ldns_status ldns_rdf2buffer_str_type(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_TYPE rdata element to string format and adds it to the output buffer.
Definition host2str.c:558
ldns_buffer_export2str
char * ldns_buffer_export2str(ldns_buffer *buffer)
Exports and returns the data in the buffer as a null terminated char * string.
Definition host2str.c:3262
ldns_pkt_print_fmt
void ldns_pkt_print_fmt(FILE *output, const ldns_output_format *fmt, const ldns_pkt *pkt)
Prints the data in the DNS packet to the given file stream (in presentation format).
Definition host2str.c:3425
ldns_pkt2str
char * ldns_pkt2str(const ldns_pkt *pkt)
Converts the data in the DNS packet to presentation format and returns that as a char *.
Definition host2str.c:3336
ldns_pkt2buffer_str_fmt
ldns_status ldns_pkt2buffer_str_fmt(ldns_buffer *output, const ldns_output_format *fmt, const ldns_pkt *pkt)
Converts the data in the DNS packet to presentation format (as char *) and appends it to the given bu...
Definition host2str.c:2689
ldns_buffer2str
char * ldns_buffer2str(ldns_buffer *buffer)
Returns a copy of the data in the buffer as a null terminated char * string.
Definition host2str.c:3235
ldns_rr_type2str
char * ldns_rr_type2str(const ldns_rr_type type)
Converts an ldns_rr_type value to its string representation, and returns that string.
Definition host2str.c:650
ldns_rr2buffer_str_fmt
ldns_status ldns_rr2buffer_str_fmt(ldns_buffer *output, const ldns_output_format *fmt, const ldns_rr *rr)
Converts the data in the resource record to presentation format (as char *) and appends it to the giv...
Definition host2str.c:1809
ldns_zone_print_fmt
void ldns_zone_print_fmt(FILE *output, const ldns_output_format *fmt, const ldns_zone *z)
Print a zone structure * to output.
Definition host2str.c:3533
ldns_pktheader2buffer_str
ldns_status ldns_pktheader2buffer_str(ldns_buffer *output, const ldns_pkt *pkt)
Converts the header of a packet to presentation format and appends it to the output buffer.
Definition host2str.c:2059
ldns_output_format_onlykeyids
const ldns_output_format * ldns_output_format_onlykeyids
Standard output format record that annotated only DNSKEY RR's with comment text.
Definition host2str.c:140
ldns_rdf2buffer_str_tag
ldns_status ldns_rdf2buffer_str_tag(ldns_buffer *output, const ldns_rdf *rdf)
Adds the LDNS_RDF_TYPE_TAG rdata to the output buffer, provided it contains only alphanumeric charact...
Definition host2str.c:1228
ldns_rr_list2buffer_str
ldns_status ldns_rr_list2buffer_str(ldns_buffer *output, const ldns_rr_list *list)
Converts a rr_list to presentation format and appends it to the output buffer.
Definition host2str.c:2052
ldns_rr_class2str
char * ldns_rr_class2str(const ldns_rr_class klass)
Converts an ldns_rr_class value to its string representation, and returns that string.
Definition host2str.c:686
ldns_rr_class2buffer_str
ldns_status ldns_rr_class2buffer_str(ldns_buffer *output, const ldns_rr_class klass)
Converts an ldns_rr_class value to its string representation, and places it in the given buffer.
Definition host2str.c:671
ldns_output_format_clear_type
ldns_status ldns_output_format_clear_type(ldns_output_format *fmt, ldns_rr_type type)
Makes sure the LDNS_FMT_RFC3597 is set in the output format.
Definition host2str.c:180
ldns_rdf_print
void ldns_rdf_print(FILE *output, const ldns_rdf *rdf)
Prints the data in the rdata field to the given file stream (in presentation format).
Definition host2str.c:3394
ldns_pkt_rcode2str
char * ldns_pkt_rcode2str(ldns_pkt_rcode rcode)
Converts a packet rcode to its mnemonic and returns that as an allocated null-terminated string.
Definition host2str.c:273
ldns_algorithm2buffer_str
ldns_status ldns_algorithm2buffer_str(ldns_buffer *output, ldns_algorithm algorithm)
Converts an ldns algorithm type to its mnemonic, and adds that to the output buffer.
Definition host2str.c:224
ldns_rdf2buffer_str_time
ldns_status ldns_rdf2buffer_str_time(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_TIME rdata element to string format and adds it to the output buffer.
Definition host2str.c:413
ldns_rr_list2str
char * ldns_rr_list2str(const ldns_rr_list *rr_list)
Converts a list of resource records to presentation format and returns that as a char *.
Definition host2str.c:3388
ldns_rr_print
void ldns_rr_print(FILE *output, const ldns_rr *rr)
Prints the data in the resource record to the given file stream (in presentation format).
Definition host2str.c:3419
ldns_output_format_storage
struct ldns_struct_output_format_storage ldns_output_format_storage
Definition host2str.h:107
ldns_cert_algorithm2buffer_str
ldns_status ldns_cert_algorithm2buffer_str(ldns_buffer *output, ldns_cert_algorithm cert_algorithm)
Converts an ldns certificate algorithm type to its mnemonic, and adds that to the output buffer.
Definition host2str.c:238
ldns_rr_list_print_fmt
void ldns_rr_list_print_fmt(FILE *output, const ldns_output_format *fmt, const ldns_rr_list *list)
print a rr_list to output
Definition host2str.c:3444
ldns_rr_list_print
void ldns_rr_list_print(FILE *output, const ldns_rr_list *list)
print a rr_list to output
Definition host2str.c:3454
ldns_resolver_print_fmt
void ldns_resolver_print_fmt(FILE *output, const ldns_output_format *fmt, const ldns_resolver *r)
Print a resolver (in sofar that is possible) state to output.
Definition host2str.c:3460
ldns_rdf2str
char * ldns_rdf2str(const ldns_rdf *rdf)
Converts the data in the rdata field to presentation format and returns that as a char *.
Definition host2str.c:3276
ldns_rdf2buffer_str_tsigtime
ldns_status ldns_rdf2buffer_str_tsigtime(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_TSIGTIME rdata element to string format and adds it to the output buffer.
Definition host2str.c:949
ldns_rdf2buffer_str_eui48
ldns_status ldns_rdf2buffer_str_eui48(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_EUI48 rdata element to 6 hexadecimal numbers separated by dashes and adds i...
Definition host2str.c:1201
ldns_rdf2buffer_str_int8
ldns_status ldns_rdf2buffer_str_int8(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_INT8 rdata element to string format and adds it to the output buffer.
Definition host2str.c:389
ldns_rdf2buffer_str_alg
ldns_status ldns_rdf2buffer_str_alg(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_ALG rdata element to string format and adds it to the output buffer.
Definition host2str.c:594
ldns_rdf2buffer_str_svcparams
ldns_status ldns_rdf2buffer_str_svcparams(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_SVCPARAMS rdata element to presentation format.
Definition host2str.c:1551
ldns_rdf2buffer_str_eui64
ldns_status ldns_rdf2buffer_str_eui64(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_EUI64 rdata element to 8 hexadecimal numbers separated by dashes and adds i...
Definition host2str.c:1214
ldns_rdf2buffer_str_amtrelay
ldns_status ldns_rdf2buffer_str_amtrelay(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_AMTRELAY rdata element to presentation format for the precedence,...
Definition host2str.c:1309
ldns_rdf2buffer_str_ilnp64
ldns_status ldns_rdf2buffer_str_ilnp64(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_ILNP64 rdata element to 4 hexadecimal numbers separated by colons and adds ...
Definition host2str.c:1187
ldns_rdf2buffer_str_nsec
ldns_status ldns_rdf2buffer_str_nsec(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_NSEC rdata element to string format and adds it to the output buffer.
Definition host2str.c:906
ldns_resolver_print
void ldns_resolver_print(FILE *output, const ldns_resolver *r)
Print a resolver (in sofar that is possible) state to output.
Definition host2str.c:3527
ldns_rdf2buffer_str_long_str
ldns_status ldns_rdf2buffer_str_long_str(ldns_buffer *output, const ldns_rdf *rdf)
Adds the LDNS_RDF_TYPE_LONG_STR rdata to the output buffer, in-between double quotes and all non prin...
Definition host2str.c:1254
ldns_rdf2buffer_str_b32_ext
ldns_status ldns_rdf2buffer_str_b32_ext(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_B32_EXT rdata element to string format and adds it to the output buffer.
Definition host2str.c:509
ldns_rr2str_fmt
char * ldns_rr2str_fmt(const ldns_output_format *fmt, const ldns_rr *rr)
Converts the data in the resource record to presentation format and returns that as a char *.
Definition host2str.c:3293
ldns_rdf2buffer_str_unknown
ldns_status ldns_rdf2buffer_str_unknown(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_UNKNOWN rdata element to string format and adds it to the output buffer.
Definition host2str.c:797
ldns_zone_print
void ldns_zone_print(FILE *output, const ldns_zone *z)
Print a zone structure * to output.
Definition host2str.c:3541
ldns_rdf2buffer_str_cert_alg
ldns_status ldns_rdf2buffer_str_cert_alg(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_CERT rdata element to string format and adds it to the output buffer.
Definition host2str.c:580
ldns_rdf2buffer_str
ldns_status ldns_rdf2buffer_str(ldns_buffer *output, const ldns_rdf *rdf)
Converts the data in the rdata field to presentation format (as char *) and appends it to the given b...
Definition host2str.c:1751
ldns_rdf2buffer_str_class
ldns_status ldns_rdf2buffer_str_class(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_CLASS rdata element to string format and adds it to the output buffer.
Definition host2str.c:565
ldns_rdf2buffer_str_int16
ldns_status ldns_rdf2buffer_str_int16(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_INT16 rdata element to string format and adds it to the output buffer.
Definition host2str.c:397
ldns_rdf2buffer_str_ipseckey
ldns_status ldns_rdf2buffer_str_ipseckey(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_IPSECKEY rdata element to string format and adds it to the output buffer.
Definition host2str.c:1077
ldns_pkt_opcode2buffer_str
ldns_status ldns_pkt_opcode2buffer_str(ldns_buffer *output, ldns_pkt_opcode opcode)
Converts an ldns packet opcode value to its mnemonic, and adds that to the output buffer.
Definition host2str.c:200
ldns_output_format_default
const ldns_output_format * ldns_output_format_default
The default output format record.
Definition host2str.c:142
ldns_rdf2buffer_str_period
ldns_status ldns_rdf2buffer_str_period(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_PERIOD rdata element to string format and adds it to the output buffer.
Definition host2str.c:938
ldns_pkt_print
void ldns_pkt_print(FILE *output, const ldns_pkt *pkt)
Prints the data in the DNS packet to the given file stream (in presentation format).
Definition host2str.c:3438
ldns_rr_list2buffer_str_fmt
ldns_status ldns_rr_list2buffer_str_fmt(ldns_buffer *output, const ldns_output_format *fmt, const ldns_rr_list *list)
Converts a rr_list to presentation format and appends it to the output buffer.
Definition host2str.c:2039
ldns_rdf2buffer_str_dname
ldns_status ldns_rdf2buffer_str_dname(ldns_buffer *output, const ldns_rdf *dname)
Print the ldns_rdf containing a dname to the buffer.
Definition host2str.c:337
ldns_output_format_set_type
ldns_status ldns_output_format_set_type(ldns_output_format *fmt, ldns_rr_type type)
Makes sure the LDNS_FMT_RFC3597 is set in the output format.
Definition host2str.c:160
ldns_rdf2buffer_str_a
ldns_status ldns_rdf2buffer_str_a(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_A rdata element to string format and adds it to the output buffer.
Definition host2str.c:428
ldns_rdf2buffer_str_nsec3_salt
ldns_status ldns_rdf2buffer_str_nsec3_salt(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_NSEC3_SALT rdata element to string format and adds it to the output buffer.
Definition host2str.c:913
ldns_output_format_bubblebabble
const ldns_output_format * ldns_output_format_bubblebabble
Standard output format record that shows all DNSKEY related information in the comment text,...
Definition host2str.c:148
ldns_rr_type2buffer_str
ldns_status ldns_rr_type2buffer_str(ldns_buffer *output, const ldns_rr_type type)
Converts an ldns_rr_type value to its string representation, and places it in the given buffer.
Definition host2str.c:617
ldns_pkt2buffer_str
ldns_status ldns_pkt2buffer_str(ldns_buffer *output, const ldns_pkt *pkt)
Converts the data in the DNS packet to presentation format (as char *) and appends it to the given bu...
Definition host2str.c:2825
ldns_pkt_algorithm2str
char * ldns_pkt_algorithm2str(ldns_algorithm algorithm)
Converts a signing algorithms to its mnemonic and returns that as an allocated null-terminated string...
Definition host2str.c:293
ldns_output_format
struct ldns_struct_output_format ldns_output_format
Definition host2str.h:95
ldns_rdf2buffer_str_int16_data
ldns_status ldns_rdf2buffer_str_int16_data(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_INT16_DATA rdata element to string format and adds it to the output buffer.
Definition host2str.c:1050
ldns_rdf2buffer_str_aaaa
ldns_status ldns_rdf2buffer_str_aaaa(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_AAAA rdata element to string format and adds it to the output buffer.
Definition host2str.c:439
ldns_rdf2buffer_str_atma
ldns_status ldns_rdf2buffer_str_atma(ldns_buffer *output, const ldns_rdf *rdf)
Converts an LDNS_RDF_TYPE_ATMA rdata element to string format and adds it to the output buffer.
Definition host2str.c:811
ldns_rr_print_fmt
void ldns_rr_print_fmt(FILE *output, const ldns_output_format *fmt, const ldns_rr *rr)
Prints the data in the resource record to the given file stream (in presentation format).
Definition host2str.c:3406
ldns_key
struct ldns_struct_key ldns_key
Definition keys.h:167
ldns_algorithm
enum ldns_enum_algorithm ldns_algorithm
Definition keys.h:64
packet.h
Contains the definition of ldns_pkt and its parts, as well as functions to manipulate those.
ldns_pkt_rcode
enum ldns_enum_pkt_rcode ldns_pkt_rcode
Definition packet.h:69
ldns_pkt
struct ldns_struct_pkt ldns_pkt
Definition packet.h:272
ldns_pkt_opcode
enum ldns_enum_pkt_opcode ldns_pkt_opcode
Definition packet.h:53
rdata.h
Defines ldns_rdf and functions to manipulate those.
ldns_cert_algorithm
enum ldns_enum_cert_algorithm ldns_cert_algorithm
Definition rdata.h:169
ldns_rdf
struct ldns_struct_rdf ldns_rdf
Definition rdata.h:205
resolver.h
Defines the ldns_resolver structure, a stub resolver that can send queries and parse answers.
ldns_resolver
struct ldns_struct_resolver ldns_resolver
Definition resolver.h:147
rr.h
Contains the definition of ldns_rr and functions to manipulate those.
ldns_rr
struct ldns_struct_rr ldns_rr
Definition rr.h:337
ldns_rr_type
enum ldns_enum_rr_type ldns_rr_type
Definition rr.h:251
ldns_rr_list
struct ldns_struct_rr_list ldns_rr_list
Definition rr.h:351
ldns_rr_class
enum ldns_enum_rr_class ldns_rr_class
Definition rr.h:61
ldns_rbtree_t
definition for tree struct
Definition rbtree.h:83
ldns_struct_output_format_storage
Output format struct with additional data for flags that use them.
Definition host2str.h:103
ldns_struct_output_format_storage::flags
int flags
Definition host2str.h:103
ldns_struct_output_format_storage::bitmap
ldns_rdf * bitmap
Definition host2str.h:105
ldns_struct_output_format_storage::hashmap
ldns_rbtree_t * hashmap
Definition host2str.h:104
ldns_struct_output_format
Output format specifier.
Definition host2str.h:89
ldns_struct_output_format::flags
int flags
Specification of how RR's should be formatted in text.
Definition host2str.h:91
ldns_struct_output_format::data
void * data
Potential extra data to be used with formatting RR's in text.
Definition host2str.h:93
util.h
INLINE
#define INLINE
splint static inline workaround
Definition util.h:42
zone.h
zone.h
ldns_zone
struct ldns_struct_zone ldns_zone
Definition zone.h:50