Lines Matching refs:DnsPacket

23         DnsPacket *packet;
39 DnsPacket **ret, in dns_packet_new()
44 DnsPacket *p; in dns_packet_new()
71 a = PAGE_ALIGN(ALIGN(sizeof(DnsPacket)) + a) - ALIGN(sizeof(DnsPacket)); in dns_packet_new()
77 p = malloc0(ALIGN(sizeof(DnsPacket)) + a); in dns_packet_new()
81 *p = (DnsPacket) { in dns_packet_new()
97 void dns_packet_set_flags(DnsPacket *p, bool dnssec_checking_disabled, bool truncated) { in dns_packet_set_flags()
147 int dns_packet_new_query(DnsPacket **ret, DnsProtocol protocol, size_t min_alloc_dsize, bool dnssec… in dns_packet_new_query()
148 DnsPacket *p; in dns_packet_new_query()
166 int dns_packet_dup(DnsPacket **ret, DnsPacket *p) { in dns_packet_dup()
167 DnsPacket *c; in dns_packet_dup()
177 c = malloc(ALIGN(sizeof(DnsPacket)) + p->size); in dns_packet_dup()
181 *c = (DnsPacket) { in dns_packet_dup()
198 DnsPacket *dns_packet_ref(DnsPacket *p) { in dns_packet_ref()
210 static void dns_packet_free(DnsPacket *p) { in dns_packet_free()
229 DnsPacket *dns_packet_unref(DnsPacket *p) { in dns_packet_unref()
245 int dns_packet_validate(DnsPacket *p) { in dns_packet_validate()
257 int dns_packet_validate_reply(DnsPacket *p) { in dns_packet_validate_reply()
295 int dns_packet_validate_query(DnsPacket *p) { in dns_packet_validate_query()
347 static int dns_packet_extend(DnsPacket *p, size_t add, void **ret, size_t *start) { in dns_packet_extend()
375 memcpy(p->_data, (uint8_t*) p + ALIGN(sizeof(DnsPacket)), p->size); in dns_packet_extend()
392 void dns_packet_truncate(DnsPacket *p, size_t sz) { in dns_packet_truncate()
413 int dns_packet_append_blob(DnsPacket *p, const void *d, size_t l, size_t *start) { in dns_packet_append_blob()
427 int dns_packet_append_uint8(DnsPacket *p, uint8_t v, size_t *start) { in dns_packet_append_uint8()
442 int dns_packet_append_uint16(DnsPacket *p, uint16_t v, size_t *start) { in dns_packet_append_uint16()
457 int dns_packet_append_uint32(DnsPacket *p, uint32_t v, size_t *start) { in dns_packet_append_uint32()
472 int dns_packet_append_string(DnsPacket *p, const char *s, size_t *start) { in dns_packet_append_string()
479 int dns_packet_append_raw_string(DnsPacket *p, const void *s, size_t size, size_t *start) { in dns_packet_append_raw_string()
500 int dns_packet_append_label(DnsPacket *p, const char *d, size_t l, bool canonical_candidate, size_t… in dns_packet_append_label()
536 DnsPacket *p, in dns_packet_append_name()
612 int dns_packet_append_key(DnsPacket *p, const DnsResourceKey *k, const DnsAnswerFlags flags, size_t… in dns_packet_append_key()
645 static int dns_packet_append_type_window(DnsPacket *p, uint8_t window, uint8_t length, const uint8_… in dns_packet_append_type_window()
676 static int dns_packet_append_types(DnsPacket *p, Bitmap *types, size_t *start) { in dns_packet_append_types()
722 DnsPacket *p, in dns_packet_append_opt()
851 int dns_packet_truncate_opt(DnsPacket *p) { in dns_packet_truncate_opt()
872 int dns_packet_append_rr(DnsPacket *p, const DnsResourceRecord *rr, const DnsAnswerFlags flags, siz… in dns_packet_append_rr()
1218 int dns_packet_append_question(DnsPacket *p, DnsQuestion *q) { in dns_packet_append_question()
1233 int dns_packet_append_answer(DnsPacket *p, DnsAnswer *a, unsigned *completed) { in dns_packet_append_answer()
1252 int dns_packet_read(DnsPacket *p, size_t sz, const void **ret, size_t *start) { in dns_packet_read()
1268 void dns_packet_rewind(DnsPacket *p, size_t idx) { in dns_packet_rewind()
1276 int dns_packet_read_blob(DnsPacket *p, void *d, size_t sz, size_t *start) { in dns_packet_read_blob()
1292 DnsPacket *p, size_t size, in dns_packet_read_memdup()
1327 int dns_packet_read_uint8(DnsPacket *p, uint8_t *ret, size_t *start) { in dns_packet_read_uint8()
1341 int dns_packet_read_uint16(DnsPacket *p, uint16_t *ret, size_t *start) { in dns_packet_read_uint16()
1357 int dns_packet_read_uint32(DnsPacket *p, uint32_t *ret, size_t *start) { in dns_packet_read_uint32()
1372 int dns_packet_read_string(DnsPacket *p, char **ret, size_t *start) { in dns_packet_read_string()
1410 int dns_packet_read_raw_string(DnsPacket *p, const void **ret, size_t *size, size_t *start) { in dns_packet_read_raw_string()
1435 DnsPacket *p, in dns_packet_read_name()
1524 static int dns_packet_read_type_window(DnsPacket *p, Bitmap **types, size_t *start) { in dns_packet_read_type_window()
1591 static int dns_packet_read_type_windows(DnsPacket *p, Bitmap **types, size_t size, size_t *start) { in dns_packet_read_type_windows()
1616 DnsPacket *p, in dns_packet_read_key()
1677 DnsPacket *p, in dns_packet_read_rr()
2184 static int dns_packet_extract_question(DnsPacket *p, DnsQuestion **ret_question) { in dns_packet_extract_question()
2235 static int dns_packet_extract_answer(DnsPacket *p, DnsAnswer **ret_answer) { in dns_packet_extract_answer()
2375 int dns_packet_extract(DnsPacket *p) { in dns_packet_extract()
2410 int dns_packet_is_reply_for(DnsPacket *p, const DnsResourceKey *key) { in dns_packet_is_reply_for()
2437 int dns_packet_patch_max_udp_size(DnsPacket *p, uint16_t max_udp_size) { in dns_packet_patch_max_udp_size()
2451 static int patch_rr(DnsPacket *p, usec_t age) { in patch_rr()
2493 int dns_packet_patch_ttls(DnsPacket *p, usec_t timestamp) { in dns_packet_patch_ttls()
2533 static void dns_packet_hash_func(const DnsPacket *s, struct siphash *state) { in dns_packet_hash_func()
2537 siphash24_compress(DNS_PACKET_DATA((DnsPacket*) s), s->size, state); in dns_packet_hash_func()
2540 static int dns_packet_compare_func(const DnsPacket *x, const DnsPacket *y) { in dns_packet_compare_func()
2547 return memcmp(DNS_PACKET_DATA((DnsPacket*) x), DNS_PACKET_DATA((DnsPacket*) y), x->size); in dns_packet_compare_func()
2550 DEFINE_HASH_OPS(dns_packet_hash_ops, DnsPacket, dns_packet_hash_func, dns_packet_compare_func);
2552 bool dns_packet_equal(const DnsPacket *a, const DnsPacket *b) { in dns_packet_equal()
2556 int dns_packet_has_nsid_request(DnsPacket *p) { in dns_packet_has_nsid_request()
2602 size_t dns_packet_size_unfragmented(DnsPacket *p) { in dns_packet_size_unfragmented()