1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-06 08:26:52 +03:00
Commit Graph

38549 Commits

Author SHA1 Message Date
Yu Watanabe
40288ecea1 network: bump mtu if stacked vlan or macvlan requests larger size
Closes #5972.
2019-02-27 10:04:56 +09:00
Lennart Poettering
f3892edd5e
Merge pull request #11824 from keszybz/fuzzer-fixes
Fuzzer fixes
2019-02-26 19:02:12 +01:00
Lennart Poettering
9a43fc6a2a
Merge pull request #11827 from keszybz/pkgconfig-variables
Allow overriding pkgconfig prefixes
2019-02-26 18:58:03 +01:00
Lennart Poettering
88a56c7670
Merge pull request #11357 from GiacintoCifelli/dbus_labels
sd-bus: add methods and signals parameter names
2019-02-26 17:22:04 +01:00
Lennart Poettering
8c28360a21
Merge pull request #11823 from keszybz/more-fuzz-coverage
More fuzz coverage
2019-02-26 17:21:32 +01:00
Zbigniew Jędrzejewski-Szmek
9b7f73b03f fuzz-ndisc-rs: avoid assertion failure on samples which dont fit in pipe
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11605.
2019-02-26 13:14:56 +01:00
Zbigniew Jędrzejewski-Szmek
d92e7b8fe4 fuzz-lldp: avoid assertion failure on samples which dont fit in pipe
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11603.
2019-02-26 13:13:02 +01:00
Zbigniew Jędrzejewski-Szmek
eafadd069c fuzz-journal-stream: avoid assertion failure on samples which don't fit in pipe
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11587.
We had a sample which was large enough that write(2) failed to push all the
data into the pipe, and an assert failed. The code could be changed to use
a loop, but then we'd need to interleave writes and sd_event_run (to process
the journal). I don't think the complexity is worth it — fuzzing works best
if the sample is not too huge anyway. So let's just reject samples above 64k,
and tell oss-fuzz about this limit.
2019-02-26 13:00:35 +01:00
Giacinto Cifelli
856ad2a86b sd-bus: add methods and signals parameter names. Fixes: #1564 2019-02-26 12:55:02 +01:00
Zbigniew Jędrzejewski-Szmek
d26eef9252 shared/ask-password-api: when echoing multi-byte characters, print the whole sequence
This is untested, but I don't see how the previous code could have worked
for multibyte characters (with echo on).
2019-02-26 12:43:07 +01:00
Zbigniew Jędrzejewski-Szmek
92e068b465 basic/utf8: do not read past end of string when looking for a multi-byte character
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=9341.
2019-02-26 12:37:40 +01:00
Zbigniew Jędrzejewski-Szmek
84319aa76e basic/utf8: change type of function to emphasize that it only looks at one character 2019-02-26 12:17:12 +01:00
Lennart Poettering
a81a4b3b24
Merge pull request #11822 from yuwata/fuzz-udev-database
fuzz: add fuzzer for udev database
2019-02-26 10:26:38 +01:00
Anita Zhang
e51237253e core: consider non-SERVICE_EXEC_START commands for EXIT_CLEAN_COMMAND
When there are multiple ExecStop= statements, the next command would continue
to run even after TimeoutStopSec= is up and sends SIGTERM. This is because,
unless Type= is oneshot, the exit code/status would evaluate to SERVICE_SUCCESS
in service_sigchld_event()'s call to is_clean_exit(). This success indicates
following commands would continue running until the end of the list
is reached, or another timeout is hit and SIGKILL is sent.

Since long running processes should not be invoked in non-SERVICE_EXEC_START
commands, consider them for EXIT_CLEAN_COMMAND instead of EXIT_CLEAN_DAEMON.
Passing EXIT_CLEAN_COMMAND to is_clean_exit() evaluates the SIGTERM exit
code/status to failure and will stop execution after the first timeout is hit.

Fixes #11431
2019-02-26 10:18:39 +01:00
Zbigniew Jędrzejewski-Szmek
453823a290
Merge pull request #11780 from yuwata/fix-4211
network: skip .network files earlier when conditions do not match system environment
2019-02-26 08:31:32 +01:00
Yu Watanabe
10f6188b67 fuzz: add a sample for fuzz-udev-database 2019-02-26 13:28:30 +09:00
Yu Watanabe
4c9024c2cf fuzz: add fuzzer for udev database 2019-02-26 13:10:31 +09:00
Yu Watanabe
b07d0f2a85 sd-device: split device_read_db_internal() into two part
The new device_read_db_internal_filename() will be used by a fuzzer.
2019-02-26 12:55:43 +09:00
Ryan Gonzalez
c20db38875 cryptsetup: Treat key file errors as a failed password attempt
6f177c7dc0 caused key file errors to immediately fail, which would make it hard to correct an issue due to e.g. a crypttab typo or a damaged key file.

Closes #11723.
2019-02-26 10:48:07 +09:00
Yu Watanabe
102bc043bb network: assign Network::manager when it is listed to the manager object.
Now Network::manager is not necessary during parsing configs.

C.f. 838b2f7a30.
2019-02-26 10:06:27 +09:00
Yu Watanabe
cebe12571d network: make resolving NetDev names delayed and moved to network_verify()
And before resolving NetDev names, check conditions in .network,
and if they do not match the system environment, drop the network
unit earlier.

Fixes #4211.
2019-02-26 10:06:23 +09:00
Yu Watanabe
a6779fecd9 network: add debug log when conditions do not match system environment 2019-02-26 09:58:33 +09:00
Lennart Poettering
510dc4da13
Merge pull request #11767 from yuwata/network-bridge-enslaved
network: extend 'enslaved' state to bridge slave
2019-02-25 19:29:30 +01:00
Michael Olbrich
416d7d4648 meson: declare version.h as dependency for systemd
This is a followup to #11815 and adds the last missing dependency.
With this #11565 is hopefully really fixed.
2019-02-25 15:55:38 +01:00
Zbigniew Jędrzejewski-Szmek
4832ce7eec fuzz-unit-file: also run manager_dump()
This should increase coverage a bit.
2019-02-25 15:46:23 +01:00
Zbigniew Jędrzejewski-Szmek
4c4589227e fuzz-unit-file: add some directives for stuff coverage reports as not covered
Some of those directives appear in the corpus, but without arguments, so maybe
the fuzzing libraries can't trigger the right cases. Let's help them.
2019-02-25 15:46:23 +01:00
Lennart Poettering
c55a447ab4
Merge pull request #11798 from keszybz/mem-sanitizer-fix
meson: make sure preprocesor warnings are not treated as errors
2019-02-25 13:50:56 +01:00
Zbigniew Jędrzejewski-Szmek
60722ad778 meson: declare version.h as dep for various targets that include build.h
Should fix #11565.
2019-02-25 10:41:41 +01:00
Zbigniew Jędrzejewski-Szmek
adbdcfbe63 test-json: use standard test intro 2019-02-25 10:07:18 +01:00
Zbigniew Jędrzejewski-Szmek
b6cda3ec4d test-json: avoid deep stack recursion under msan 2019-02-25 10:07:18 +01:00
Zbigniew Jędrzejewski-Szmek
9003da2963 test-mountpoint-util: unpoison string allocated by sscanf %ms 2019-02-25 10:07:18 +01:00
Zbigniew Jędrzejewski-Szmek
c322f379e6 Add wrapper for __msan_unpoinson() to reduce #ifdeffery
This isn't really necessary for the subsequent commit, but I expect that we'll
need to unpoison more often once we turn on msan in CI, so I think think this
change makes sense in the long run.
2019-02-25 10:07:18 +01:00
Zbigniew Jędrzejewski-Szmek
3b8951c1dc meson: make sure preprocesor warnings are not treated as errors
Clang includes -W#warning in -Werror, so the #warning used for msan would
be an error.

v2:
- use -Wno-error=... so that the warning is still emitted, but not as an error.
2019-02-25 10:06:47 +01:00
Zbigniew Jędrzejewski-Szmek
d05da14f32
Merge pull request #11796 from yuwata/fuzz-link-parser
fuzz: add fuzzer for .link files
2019-02-25 09:55:02 +01:00
Yu Watanabe
051f39c227 tools: check all directives even if it detects non-updated files 2019-02-25 12:41:11 +09:00
Yu Watanabe
810d43a8e8 tools: update check-directives.sh to support fuzz-link-parser 2019-02-25 12:41:11 +09:00
Yu Watanabe
eac31d708f fuzz: add directives.link and 99-default.link for fuzz-link-parser
Also adds several reproducers of errors fixed in earlier commits.
2019-02-25 12:40:42 +09:00
Yu Watanabe
a378400b3f fuzz: add fuzzer for parsing .link files
This also renames load_link() to link_load_one()
2019-02-25 12:35:51 +09:00
Yu Watanabe
7cd1f60df0 fuzz: use fflush() and drop unnecessary rewind() 2019-02-25 12:35:51 +09:00
Yu Watanabe
84fb56d396 udev/ethtool: fix error detection of ethtool_link_mode_bit_from_string() 2019-02-25 12:35:40 +09:00
Yu Watanabe
391f6bc1db udev: fix memleak in conditions for .link file 2019-02-25 11:57:14 +09:00
Yu Watanabe
176d9c0e11 udev/net: drop .link files earlier when their conditions do not match system environment 2019-02-25 11:54:50 +09:00
Yu Watanabe
6cdab9f17f udev/net: use structured initializer at one more place 2019-02-25 11:53:57 +09:00
Yu Watanabe
79a60834e2 udev/net: use size_t for index at one more place 2019-02-25 11:51:32 +09:00
Yu Watanabe
e8a42907ed udev/net: ignore errors in loading .link files but warn about that 2019-02-25 11:50:57 +09:00
Yu Watanabe
f2d251cdb8 udev/net: shorten load_link() a little bit 2019-02-25 11:48:39 +09:00
Yu Watanabe
c6b3370ab2 udev: drop unused Ethernet section 2019-02-25 11:45:34 +09:00
Yu Watanabe
7d4ea8f91c man: update explanation about operational state of network interfaces 2019-02-25 09:34:14 +09:00
Yu Watanabe
85fc09c97a man: mention that LinkLocalAddressing= is disabled by default when Bridge= is set 2019-02-25 09:34:14 +09:00
Yu Watanabe
6609924c32 test-network: add more tests for IgnoreCarrierLoss=
Suggested by @amishmm in #9262.
2019-02-25 09:34:14 +09:00