b26fa1a2fbcfee7d03b0c8fd15ec3aa64ae70b9f |
|
10-Feb-2016 |
Daniel Mack <daniel@zonque.org> |
tree-wide: remove Emacs lines from all files
This should be handled fine now by .dir-locals.el, so need to carry that
stuff in every file. |
011696f76233486bc56c266b18a328924f70269c |
|
01-Feb-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved: rework what ResolveHostname() with family == AF_UNSPEC means
Previously, if a hostanem is resolved with AF_UNSPEC specified, this would be used as indication to resolve both an
AF_INET and an AF_INET6 address. With this change this logic is altered: an AF_INET address is only resolved if there's
actually a routable IPv4 address on the specific interface, and similar an AF_INET6 address is only resolved if there's
a routable IPv6 address. With this in place, it's ensured that the returned data is actually connectable by
applications. This logic mimics glibc's resolver behaviour.
Note that if the client asks explicitly for AF_INET or AF_INET6 it will get what it asked for.
This also simplifies the logic how it is determined whether a specific lookup shall take place on a scope.
Specifically, the checks with dns_scope_good_key() are now moved out of the transaction code and into the query code,
so that we don't even create a transaction object on a specific scope if we cannot execute the resolution on it anyway. |
3df9bec57c3e2d96f7e2a25961585cfa609b61eb |
|
26-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
networkd: rework Domains= setting
Previously, .network files only knew a vaguely defined "Domains=" concept, for which the documentation declared it was
the "DNS domain" for the network connection, without specifying what that means.
With this the Domains setting is reworked, so that there are now "routing" domains and "search" domains. The former are
to be used by resolved to route DNS request to specific network interfaces, the latter is to be used for searching
single-label hostnames with (in addition to being used for routing). Both settings are configured in the "Domains="
setting. Normal domain names listed in it are now considered search domains (for compatibility with existing setups),
while those prefixed with "~" are considered routing domains only. To route all lookups to a specific interface the
routing domain "." may be used, referring to the root domain. An alternative syntax for this is the "*", as was already
implemented before using the "wildcard" domain concept.
This commit adds proper parsers for this new logic, and exposes this via the sd-network API. This information is not
used by resolved yet, this will be added in a later commit. |
dd0bc0f1414cc1d0fa73a29470bd14944e4942d3 |
|
25-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved: synthesize RRs for data from /etc/hosts
This way the difference between lookups via NSS and our native bus API should become minimal. |
59c5b5974d106c5ebad080739b41d0e92ab74d29 |
|
25-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved: log each time we increase the DNSSEC verdict counters
Also, don't consider RRs that aren't primary to the lookups we do as relevant to the lookups. |
c69fa7e3c44240bedc0ee1bd89fecf954783ac85 |
|
19-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved: rework DNSSECSupported property
Not only report whether the server actually supports DNSSEC, but also first check whether DNSSEC is actually enabled
for it in our local configuration.
Also, export a per-link DNSSECSupported property in addition to the existing manager-wide property. |
ad6c04756115809d615dede330213d73edf732a8 |
|
05-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved,networkd: add a per-interface DNSSEC setting
This adds a DNSSEC= setting to .network files, and makes resolved honour
them. |
af49ca27ffd790d78dbbb465b978266dfd5c93da |
|
05-Jan-2016 |
Lennart Poettering <lennart@poettering.net> |
resolved,networkd: unify ResolveSupport enum
networkd previously knew an enum "ResolveSupport" for configuring
per-interface LLMNR support, resolved had a similar enum just called
"Support", with the same value and similar pasers.
Unify this, call the enum ResolveSupport, and port both daemons to it. |
a150ff5e4e2481eb28d6ed6e0d3e176623e25f5a |
|
26-Dec-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: gather statistics about resolved names
This collects statistical data about transactions, dnssec verifications
and the cache, and exposes it over the bus. The systemd-resolve-host
tool learns new options to query these statistics and reset them. |
bc7702b098b63031767174206f5df14a8ccb45cf |
|
08-Dec-2015 |
Daniel Mack <daniel@zonque.org> |
resolved: add infrastructure for mDNS related sockets
Just hook up mDNS listeners with an empty packet dispather function,
introduce a config directive, man page updates etc. |
0d2cd47617b423f37d7425be7a56ae2fca8ff9f6 |
|
03-Dec-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: add a simple trust anchor database as additional RR source
When doing DNSSEC lookups we need to know one or more DS or DNSKEY RRs
as trust anchors to validate lookups. With this change we add a
compiled-in trust anchor database, serving the root DS key as of today,
retrieved from:
https://data.iana.org/root-anchors/root-anchors.xml
The interface is kept generic, so that additional DS or DNSKEY RRs may
be served via the same interface, for example by provisioning them
locally in external files to support "islands" of security.
The trust anchor database becomes the fourth source of RRs we maintain,
besides, the network, the local cache, and the local zone. |
9176a57c101d51b4a7fb4141240b5ce03abac57d |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: split out calls to compile full list of dns servers and search domains
Let's split this out from the resolv.conf parser, so that this becomes
generically useful. |
eed857b71702f8551b46b66b31fa0d08583cf23c |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: enforce a maximum limit on both dns servers and search domains |
a51c10485af349eb15faa4d1a63b9818bcf3e589 |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: add a generic DnsSearchDomain concept
With this change, we add a new object to resolved, "DnsSearchDomain="
which wraps a search domain. This is then used to introduce a global
search domain list, in addition to the existing per-link search domain
list which is reword to make use of this new object too.
This is preparation for implement proper unicast DNS search domain
support. |
00fa60ae3b2823036cb3e7734f16bce30cb7441d |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: make sure FallbackDNS= overrides built-in servers, doesn't extend them
Closes #342. |
f2f1dbe50fea13abadc9c1e845a29031b90b40f3 |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: move dns server picking code from resolved-manager.c to resolved-dns-server.c |
f8dc7e343d903f053070d01f3273db819deee951 |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: split out all code dealing with /etc/resolv.conf into its own .c file
No functional changes. |
636e813dc98ea40c58c6c85bc5e7e3c9f0904ea2 |
|
25-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: unify code for parsing dns server information
Let's use the same parser when parsing dns server information from
/etc/resolv.conf and our native configuration file.
Also, move all code that manages lists of dns servers to a single place.
resolved-dns-server.c |
71d35b6b5563817dfbe757ab9e3b9f018b2db491 |
|
18-Nov-2015 |
Thomas Hindoe Paaboel Andersen <phomes@gmail.com> |
tree-wide: sort includes in *.h
This is a continuation of the previous include sort patch, which
only sorted for .c files. |
4d506d6bb757af3b99e0876234c465e6898c5ea4 |
|
26-Aug-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: dump cache and zone contents to syslog on SIGUSR1 |
78c6a153c47f8d597c827bdcaf8c4e42ac87f738 |
|
21-Aug-2015 |
Lennart Poettering <lennart@poettering.net> |
resolved: rework synthesizing logic
With this change we'll now also generate synthesized RRs for the local
LLMNR hostname (first label of system hostname), the local mDNS hostname
(first label of system hostname suffixed with .local), the "gateway"
hostname and all the reverse PTRs. This hence takes over part of what
nss-myhostname already implemented.
Local hostnames resolve to the set of local IP addresses. Since the
addresses are possibly on different interfaces it is necessary to change
the internal DnsAnswer object to track per-RR interface indexes, and to
change the bus API to always return the interface per-address rather than
per-reply. This change also patches the existing clients for resolved
accordingly (nss-resolve + systemd-resolve-host).
This also changes the routing logic for queries slightly: we now ensure
that the local hostname is never resolved via LLMNR, thus making it
trustable on the local system. |
72290734be81e83e6ef9520c07692f68095eb5b2 |
|
27-Jul-2015 |
Tom Gundersen <teg@jklm.no> |
resolved: scope - write() unicast DNS packets
As we have connect()ed to the desired DNS server, we no longer need to pass
control messages manually when sending packets. Simplify the logic accordingly. |
d20b1667dbab8bccf69735523a0d5fc645e81b80 |
|
14-Jul-2015 |
Tom Gundersen <teg@jklm.no> |
resolved: use one UDP socket per transaction
We used to have one global socket, use one per transaction instead. This
has the side-effect of giving us a random UDP port per transaction, and
hence increasing the entropy and making cache poisoining significantly
harder to achieve.
We still reuse the same port number for packets belonging to the same
transaction (resent packets). |
5f402ae84bbc08fe8de5682e371b3f66c387da52 |
|
13-Jul-2015 |
Daniel Mack <daniel@zonque.org> |
resolved: move LLMNR related functions into separate file |
1c4baffc1895809bae9ac36b670af90a4cb9cd7d |
|
13-Jun-2015 |
Tom Gundersen <teg@jklm.no> |
sd-netlink: rename from sd-rtnl |
2eec67acbb00593e414549a7e5b35eb7dd776b1b |
|
23-Feb-2015 |
Thomas Hindoe Paaboel Andersen <phomes@gmail.com> |
remove unused includes
This patch removes includes that are not used. The removals were found with
include-what-you-use which checks if any of the symbols from a header is
in use. |
a5f035960006556beab51c42e6948985635e261a |
|
22-Oct-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: simplify detection of packets from the loopback device
We can simplify our code quite a bit if we explicitly check for the
ifindex being 1 on Linux as a loopback check. Apparently, this is
hardcoded on Linux on the kernel, and effectively exported to userspace
via rtnl and such, hence we should be able to rely on it. |
3e684349c2cead2e6fd2f816c34eb17daba23a49 |
|
12-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: unify logic how we flush out DNS servers we learnt |
902bb5d8abb2a7d258741828d212ca549ab16950 |
|
11-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: verify all RRs when we come back from suspend |
a407657425a3e47fd2b559cd3bc800f791303f63 |
|
11-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: implement full LLMNR conflict detection logic |
19b50b5ba7ee8c1bfb330377309e4bab7a7531d8 |
|
04-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: read the per-interface LLMNR setting from networkd and act on it |
edc501d4674dadc304d45a7e1c5b69e207eb8cd4 |
|
04-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: when there's already somebody listening on the LLMNR ports, simple disable LLMNR and warn, but continue
This allows us to run resolved inside an nspawn container that shares
the network namespace with the host, if there's already an instance
running. |
2c27fbca2d88214bd305272308a370a962818f1e |
|
01-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: flush cache each time we change to a different DNS server |
5cb36f41f01cf4b1f4395abfffd1b33116591e58 |
|
01-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: read the system /etc/resolv.conf unless we wrote it ourselves
This way we integrate nicely with foreign network management stacks,
such as NM. |
39d8db043b599a7382f94bfc904d5e108af438bd |
|
01-Aug-2014 |
Lennart Poettering <lennart@poettering.net> |
resolved: rename resolved.h to resolved-manager.h
After all it pretty much exlcusively containers definitions about the
"Manager" object, hence let's call this the most obvious way. |