summaryrefslogtreecommitdiffstats
path: root/src/libsystemd (unfollow)
Commit message (Collapse)AuthorFilesLines
2019-03-01volatile-util: tweak query_volatile_mode() a bitLennart Poettering1-9/+10
2019-03-01nspawn: rework how arg_read_only is initialized in --volatile= modeLennart Poettering1-4/+10
Previously, we'd refuse the combination, and claimed we'd imply it, but actually didn't. Let's allow the combination and imply read-only from --volatile=, because that's what's documented, what we claim we do, and what makes sense.
2019-03-01nspawn: refactor how we determine whether it's OK to write to /etcLennart Poettering1-6/+10
2019-03-01nspawn: no need to make top-level directory a bind mount if we just ↵Lennart Poettering1-4/+6
dissected an image
2019-03-01nspawn: slightly reorder mount logicLennart Poettering1-22/+22
Let's first setup the volatile logic, and only then mount secondary partitions of the image in.
2019-03-01nspawn: add --volatile=overlay supportLennart Poettering4-6/+76
Fixes: #11054 #3847
2019-03-01nspawn: fix an error pathLennart Poettering1-1/+1
2019-03-01nspawn: add volatile mode multiplexer call setup_volatile_mode()Lennart Poettering3-27/+26
Just some refactoring, no change in behaviour.
2019-03-01nspawn: explicitly refuse mounts over /Lennart Poettering1-0/+7
Previously this would fail later on, but let's filter this out at the time of parsing.
2019-03-01json: don't call va_end() twice in json_build()Lennart Poettering1-2/+0
This was apparently left-over when json_buildv() was added, and json_build() just became a wrapper for it.
2019-03-01semaphoreci: Run subset of autopkgtests in LXC (#11814)Martin Pitt2-27/+76
Run build/test in LXC for now, as full nested QEMU is too brittle right now: https://github.com/semaphoreci/semaphore/issues/37 But this at least runs some tests. It ensures that systemd generally works in containers, as well as provides some backup results if the main Ubuntu CI is down.
2019-02-28man: add ACRN hypervisorRoss Burton2-1/+7
2019-02-28Better C code formatting of arguments in EmacsJörg Sommer1-1/+2
In [PR#11696][1] it came up that the formatting of continued arguments should follow the default Emacs style. To ensure this happens when someone has changed his setting in her private config, the value should be set by *dir-locals.el*. [1]: https://github.com/systemd/systemd/pull/11696#pullrequestreview-205463987
2019-02-28virt: detect the ACRN hypervisorRoss Burton2-0/+4
Add magic string and enumeration for the ACRN hypervisor (https://projectacrn.org).
2019-02-28test-time-util: use standard intro and print timezones read from fileZbigniew Jędrzejewski-Szmek1-3/+6
The asserts are OK, but it's also nice to see the list by eye.
2019-02-28README: mention that we need tzdata >= 2014fZbigniew Jędrzejewski-Szmek1-0/+1
zone1970.tab was added in that version. Not that it makes sense to use outdata timezone tables, but people do strange things. C.f. https://github.com/nodatime/nodatime/issues/319.
2019-02-28man/shutdown: Fix grammarTheo Ouzhinski1-1/+1
2019-02-28Use new time zone listChristopher Wong1-1/+1
When systemd retrieve the time zone it read what is in the file /usr/share/zoneinfo/zone.tab provided by the Time Zone Database. According to the comments in zone.tab its content is for backward- compatibility aid for older programs. New programs should use zone1970.tab. This patch replaces zone.tab with zone1970.tab.
2019-02-28sd-bus: deal with cookie overrunsLennart Poettering1-1/+46
Apparently this happens IRL. Let's carefully deal with issues like this: when we overrun, let's not go back to zero but instead leave the highest cookie bit set. We use that as indication that we are in "overrun territory", and then are particularly careful with checking cookies, i.e. that they haven't been used for still outstanding replies yet. This should retain the quick cookie generation behaviour we used to have, but permits dealing with overruns. Replaces: #11804 Fixes: #11809
2019-02-28man: create .so links for sd_bus_close_{unref,unrefp}Zbigniew Jędrzejewski-Szmek1-1/+3
Follow-up for bd62b7448623fbe36665e089977731efb55524c0.
2019-02-28meson: remove workaround for old meson bug with command quotingZbigniew Jędrzejewski-Szmek1-4/+1
Those bugs were fixed a long time ago. Let's take advantage of this and use the usual $() syntax.
2019-02-28udev-builtin-usb_id: guard against overflow when reading descriptor dataZbigniew Jędrzejewski-Szmek1-3/+8
CID#996458. Coverity warns that we trust desc->bLength as read in the input data to adjust our position in the buffer. This value could be anything, leading to overflow. It's unlikely that the kernel feeds us invalid data, but let's me more careful. If any error is encountered, more logs are given.
2019-02-28udev-builtin-usb_id: use strjoina to simplify codeZbigniew Jędrzejewski-Szmek1-5/+3
2019-02-28shared/install: do not use a temporary variable outside of its scopeZbigniew Jędrzejewski-Szmek1-8/+3
Coverity says: > Pointer to local outside scope (RETURN_LOCAL)9. > use_invalid: Using dirs, which points to an out-of-scope temporary variable of type char const *[5]. And indeed, the switch statement forms a scope. Let's use an if to avoid creating a scope.
2019-02-28fuzz: do not assume the existence of /sys/class/net/loYu Watanabe1-1/+2
Hopefully fixes oss-fuzz#13440.
2019-02-28network: wrap long linesYu Watanabe1-7/+12
2019-02-28network: simplify config_parse_lifetime()Yu Watanabe1-16/+10
2019-02-28network: avoid address section freedYu Watanabe1-0/+1
Otherwise, if HomeAddress= or friends are specified at the first line of a section, then its assignment will be ignored.
2019-02-28network: cleanup logging in route related config parsersYu Watanabe1-9/+15
2019-02-28network: do not override previously specified familyYu Watanabe1-11/+17
2019-02-28test-network: add testcase for #1850Yu Watanabe2-0/+34
2019-02-28network: enable GatewayOnLink= if Gateway= without static address configuredYu Watanabe1-1/+12
And warn about that. But this only done if GatewayOnLink= is not specified. When it is explicitly disabled, then the flag will not be set.
2019-02-28network: save GatewayOnLink= value as tristate in RouteYu Watanabe2-1/+7
This should not change any behavior. But used in the later commit.
2019-02-28network: relax the .network file checkYu Watanabe1-15/+20
Previously, if a .networ file contains invalid [Address] or [Route] section, then the file is completely dropped. This makes networkd just drops invalid sections.
2019-02-28network: rename GatewayOnlink= to GatewayOnLink=Yu Watanabe6-4/+6
But still GatewayOnlink= is supported for backward compatibility.
2019-02-27networkd-test: ignore failures of test_route_only_dns* in containersMartin Pitt1-4/+19
This test exposes a race condition when running in LXC, see issue #11848 for details. Until that is understood and fixed, skip the test as it's not a recent regression.
2019-02-27networkd-test: specify Address= with prefix lengthMartin Pitt1-5/+5
This avoids a warning: An address '192.168.42.100' is specified without prefix length. The behavior of parsing addresses without prefix length will be changed in the future release. Please specify prefix length explicitly.
2019-02-27networkd-test: show service journal on startup failureMartin Pitt1-11/+15
This provides easier evaluation of failed tests.
2019-02-27journalctl: New option --cursor-fileJörg Sommer4-12/+67
The option cursor-file takes a filename as argument. If the file exists and contains a valid cursor, this is used to start the output after this position. At the end, the last cursor gets written to the file. This allows for an easy implementation of a timer that regularly looks in the journal for some messages. journalctl --cursor-file err-cursor -b -p err journalctl --cursor-file audit-cursor -t audit --grep DENIED Or you might want to walk the journal in steps of 10 messages: journalctl --cursor-file ./curs -n10 --since=today -t systemd
2019-02-27analyze security: check for ProtectHostname=yesTopi Miettinen1-0/+12
2019-02-27networkd: refuse more than 128 NTP serversZbigniew Jędrzejewski-Szmek2-3/+11
This test case is a bit silly, but it shows that our code is unprepared to handle so many network servers, with quadratic complexity in various places. I don't think there are any valid reasons to have hundres of NTP servers configured, so let's just emit a warning and cut the list short. https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=13354
2019-02-27networkd: fix memleak when the same NetDev is specified twiceZbigniew Jędrzejewski-Szmek2-6/+7
hashmap_put() returns 0 if the (key, value) pair is already present in the hashmap, and -EEXIST if the key exists, but the value is different. https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=13433
2019-02-27network: wrap some long linesZbigniew Jędrzejewski-Szmek1-3/+6
2019-02-27selinux: don't log SELINUX_INFO and SELINUX_WARNING messages to auditMichal Sekletar1-1/+5
Previously we logged even info message from libselinux as USER_AVC's to audit. For example, setting SELinux to permissive mode generated following audit message, time->Tue Feb 26 11:29:29 2019 type=USER_AVC msg=audit(1551198569.423:334): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='avc: received setenforce notice (enforcing=0) exe="/usr/lib/systemd/systemd" sauid=0 hostname=? addr=? terminal=?' This is unnecessary and wrong at the same time. First, kernel already records audit event that SELinux was switched to permissive mode, also the type of the message really shouldn't be USER_AVC. Let's ignore SELINUX_WARNING and SELINUX_INFO and forward to audit only USER_AVC's and errors as these two libselinux message types have clear mapping to audit message types.
2019-02-27man: clarify whitespace handling in systemd.syntaxDavide Cavalca1-1/+1
2019-02-27test-network: add testcase for issue #11280Yu Watanabe3-4/+41
2019-02-27test-network: drop relevant ip routing policy rules before testingYu Watanabe1-0/+15
2019-02-27network: fix error code in logYu Watanabe1-1/+1
2019-02-27network: merge conditions and use FLAGS_SET() macroYu Watanabe1-6/+6
2019-02-27network: make ndisc_router_process_options() propagate errorYu Watanabe1-15/+11
And its caller ignore the error.