resolved-dns-scope.h revision 28b9b7640603f88cb49f95609331fa5072715f15
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering This file is part of systemd.
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering Copyright 2014 Lennart Poettering
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering systemd is free software; you can redistribute it and/or modify it
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering under the terms of the GNU Lesser General Public License as published by
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering the Free Software Foundation; either version 2.1 of the License, or
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering (at your option) any later version.
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering systemd is distributed in the hope that it will be useful, but
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering WITHOUT ANY WARRANTY; without even the implied warranty of
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering Lesser General Public License for more details.
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering You should have received a copy of the GNU Lesser General Public License
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering along with systemd; If not, see <http://www.gnu.org/licenses/>.
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering LIST_HEAD(DnsQueryCandidate, query_candidates);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering /* Note that we keep track of ongoing transactions in two
a5344d2c3b0f14e954ce1c0ef905c5b44bc5bf0aLennart Poettering * ways: once in a hashmap, indexed by the rr key, and once in
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering * a linked list. We use the hashmap to quickly find
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering * transactions we can reuse for a key. But note that there
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering * might be multiple transactions for the same key (because
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering * the zone probing can't reuse a transaction answered from
d0bbc21caa6e68693a47db60c93e99422bf2a858Lennart Poettering * the zone or the cache), and the hashmap only tracks the
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poettering * most recent entry. */
d0bbc21caa6e68693a47db60c93e99422bf2a858Lennart Poetteringint dns_scope_new(Manager *m, DnsScope **ret, Link *l, DnsProtocol p, int family);
fe6521272ba203ec8f0d5a94f0729960b3f90525Lennart Poetteringvoid dns_scope_packet_received(DnsScope *s, usec_t rtt);
fe6521272ba203ec8f0d5a94f0729960b3f90525Lennart Poetteringvoid dns_scope_packet_lost(DnsScope *s, usec_t usec);
fe6521272ba203ec8f0d5a94f0729960b3f90525Lennart Poetteringint dns_scope_emit(DnsScope *s, int fd, DnsServer *server, DnsPacket *p);
fe6521272ba203ec8f0d5a94f0729960b3f90525Lennart Poetteringint dns_scope_tcp_socket(DnsScope *s, int family, const union in_addr_union *address, uint16_t port, DnsServer **server);
d0bbc21caa6e68693a47db60c93e99422bf2a858Lennart Poetteringint dns_scope_udp_dns_socket(DnsScope *s, DnsServer **server);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart PoetteringDnsScopeMatch dns_scope_good_domain(DnsScope *s, int ifindex, uint64_t flags, const char *domain);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poetteringint dns_scope_good_key(DnsScope *s, DnsResourceKey *key);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart PoetteringDnsServer *dns_scope_get_dns_server(DnsScope *s);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poetteringvoid dns_scope_next_dns_server(DnsScope *s);
d0bbc21caa6e68693a47db60c93e99422bf2a858Lennart Poetteringint dns_scope_llmnr_membership(DnsScope *s, bool b);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart Poetteringvoid dns_scope_process_query(DnsScope *s, DnsStream *stream, DnsPacket *p);
7f3e62571a63ac90de6ac5eefeeb8d3e9aa6f49eLennart PoetteringDnsTransaction *dns_scope_find_transaction(DnsScope *scope, DnsResourceKey *key, bool cache_ok);
b070e7f3c9ed680c821bd89d42506695f2438506Lennart Poetteringint dns_scope_notify_conflict(DnsScope *scope, DnsResourceRecord *rr);
25d042e81516246b1ebf706a57c47ac19abb0b8aLennart Poetteringvoid dns_scope_check_conflicts(DnsScope *scope, DnsPacket *p);
b070e7f3c9ed680c821bd89d42506695f2438506Lennart Poetteringvoid dns_scope_dump(DnsScope *s, FILE *f);
b070e7f3c9ed680c821bd89d42506695f2438506Lennart PoetteringDnsSearchDomain *dns_scope_get_search_domains(DnsScope *s);