1 /* SPDX-License-Identifier: LGPL-2.1-or-later */
7 #include "resolve-util.h"
8 #include "resolved-dns-dnssec.h"
11 typedef struct DnsCache
{
18 #include "resolved-dns-answer.h"
19 #include "resolved-dns-packet.h"
20 #include "resolved-dns-question.h"
21 #include "resolved-dns-rr.h"
23 void dns_cache_flush(DnsCache
*c
);
24 void dns_cache_prune(DnsCache
*c
);
28 DnsCacheMode cache_mode
,
32 DnsPacket
*full_packet
,
34 DnssecResult dnssec_result
,
37 const union in_addr_union
*owner_address
);
44 DnsAnswer
**ret_answer
,
45 DnsPacket
**ret_full_packet
,
46 bool *ret_authenticated
,
47 DnssecResult
*ret_dnssec_result
);
49 int dns_cache_check_conflicts(DnsCache
*cache
, DnsResourceRecord
*rr
, int owner_family
, const union in_addr_union
*owner_address
);
51 void dns_cache_dump(DnsCache
*cache
, FILE *f
);
52 bool dns_cache_is_empty(DnsCache
*cache
);
54 unsigned dns_cache_size(DnsCache
*cache
);
56 int dns_cache_export_shared_to_packet(DnsCache
*cache
, DnsPacket
*p
);