summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Move offline-password.[ch] to shared and add test-offline-passwdZbigniew Jędrzejewski-Szmek2020-07-185-2/+93
| | | | | | The test binary has two modes: in the default argument-less mode, it just checks that "root" can be resolved. When invoked manually, a root prefix and user/group names can be specified.
* Merge pull request #16490 from yuwata/network-radv-ndisc-cleanupsYu Watanabe2020-07-173-167/+148
|\ | | | | network: cleanups for radv and ndisc
| * network: ndisc: any failures in processing event make the link in failed stateYu Watanabe2020-07-161-111/+107
| | | | | | | | Also adjust log levels.
| * network: radv: clean up conf parsersYu Watanabe2020-07-162-56/+41
| |
* | Merge pull request #16491 from keszybz/udev-loggingZbigniew Jędrzejewski-Szmek2020-07-1712-129/+119
|\ \ | | | | | | Improvements to udev logging and related code
| * | tree-wide: use SYNTHETIC_ERRNO with log_device_* in more placesZbigniew Jędrzejewski-Szmek2020-07-164-28/+23
| | |
| * | sd-device: use LOG_PRI() in log_device_full()Zbigniew Jędrzejewski-Szmek2020-07-161-1/+1
| | | | | | | | | | | | | | | | | | We use LOG_PRI() in all log_*() functions, so let's do that here too for consistency. Effectively this doesn't change anything since we only use LOG_{INFO,DEBUG,...} as the argument.
| * | udev: don't complain when udev_watch_end() is called without udev_watch_init()Zbigniew Jędrzejewski-Szmek2020-07-161-2/+1
| | | | | | | | | | | | | | | | | | E.g. udevadm test prints "Invalid inotify descriptor." which is meaningless without any context. I think it should be OK to call udev_watch_end() from a cleanup path without any warning (even at debug level).
| * | basic/string-table: reduce variable scopeZbigniew Jędrzejewski-Szmek2020-07-161-3/+1
| | |
| * | udevadm: use STR_IN_SET(), add commentZbigniew Jędrzejewski-Szmek2020-07-161-11/+9
| | |
| * | sd-device: use strjoin instead of asprintfZbigniew Jędrzejewski-Szmek2020-07-162-36/+27
| | | | | | | | | | | | | | | strjoin should be faster for string concatenation. Also drop "_"-prefix from function prototypes.
| * | udev: tweak debug logs for udev rulesZbigniew Jędrzejewski-Szmek2020-07-161-7/+7
| | | | | | | | | | | | | | | We shouldn't say "ignoring" when running a program because the result is used for the match/nomatch result of the rule.
| * | man: add more details for IMPORT, PROGRAM and RUN keysZbigniew Jędrzejewski-Szmek2020-07-161-32/+47
| | | | | | | | | | | | | | | | | | | | | | | | 967de8faceaa83c11a1215515cb135d7a8c0c32c added a note that I found very hard to understand. Reword it, and also describe how IMPORT and PROGRAM are different from RUN. Minor markup adjustements too.
| * | udev: accept OPTIONS+= without any fussZbigniew Jędrzejewski-Szmek2020-07-161-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | There is no reason to consider this wrong. In fact one could argue that += is more appropriate, because we always add to options, and not replace previous assignments. If we output a debug message, we implicitly ask people to "fix" this, and we shouldn't. Also, all our rules use += right now.
| * | udev: accept IMPORT{}= without any fussZbigniew Jędrzejewski-Szmek2020-07-161-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Udev logs are full of messages about wrong operator type: ... Reading rules file: /usr/lib/udev/rules.d/60-persistent-storage.rules /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:30 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:54 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:57 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:60 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:63 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:66 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:67 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:93 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:107 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:110 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-storage.rules:113 IMPORT key takes '==' or '!=' operator, assuming '=='. Reading rules file: /usr/lib/udev/rules.d/60-persistent-v4l.rules /usr/lib/udev/rules.d/60-persistent-v4l.rules:7 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-v4l.rules:9 IMPORT key takes '==' or '!=' operator, assuming '=='. /usr/lib/udev/rules.d/60-persistent-v4l.rules:16 IMPORT key takes '==' or '!=' operator, assuming '=='. ... The warning was downgraded in f0beb6f816035e438d684cc52ae76fc4a44fc197, but I think it should be removed altogether. IMPORT{program}="asdf" seems like an obvious way to write this, and people don't expect to have to write "==". So let's just allow any operator.
* | | analyze: CAP_RAWIO -> CAP_SYS_RAWIOAnita Zhang2020-07-161-1/+1
| |/ |/| | | | | Fixes #16489
* | network: downgrade log level in conf parsersYu Watanabe2020-07-1655-754/+864
| |
* | Merge pull request #16485 from bluca/nspawn_os_release_mountsLennart Poettering2020-07-164-8/+13
|\ \ | | | | | | Follow-up for comments on #15891
| * | nspawn: mount os-release in two steps to make it read-onlyLuca Boccassi2020-07-162-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | The kernel interface requires setting up read-only bind-mounts in two steps, the bind first and then a read-only remount. Fix nspawn-mount, and cover this case in the integration test. Fixes #16484
| * | nspawn: use access/F_OK instead of stat to check for file existenceLuca Boccassi2020-07-161-2/+1
| | |
| * | shared/os-util: fix comment style to follow guidelinesLuca Boccassi2020-07-161-1/+1
| | |
| * | basic/mkdir: use uid_is_valid instead of manual checkLuca Boccassi2020-07-161-2/+2
| | |
* | | Merge pull request #16482 from poettering/coverity-246Yu Watanabe2020-07-162-2/+2
|\ \ \ | |/ / |/| | two coverity fixes
| * | machine: fix if checkLennart Poettering2020-07-161-1/+1
| | | | | | | | | | | | Fixes: coverity 1430462
| * | execute: fix if checkLennart Poettering2020-07-161-1/+1
| | | | | | | | | | | | Fixes: coverity 1430459
* | | Merge pull request #16483 from poettering/man-env-d-no-sessionZbigniew Jędrzejewski-Szmek2020-07-161-5/+4
|\ \ \ | | | | | | | | man: three minor fixes to environment.d/ man page
| * | | man: configuration files contain assignments, no directoriesLennart Poettering2020-07-161-3/+2
| | | |
| * | | man: GNOME is usually capitalizedLennart Poettering2020-07-161-1/+1
| | | |
| * | | man: don't claim environment.d/ was about sessionsLennart Poettering2020-07-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This only sets the environment for user *services*, it has no effect on sessions, as those get an env block set up by whatever program sets them up and not systemd.
* | | | Merge pull request #16480 from yuwata/network-fix-dhcp4-racesZbigniew Jędrzejewski-Szmek2020-07-164-49/+78
|\ \ \ \ | |/ / / |/| | | network: fix two minor races in DHCP4 handling
| * | | network: dhcp4: add two warningsYu Watanabe2020-07-161-4/+8
| | | |
| * | | network: dhcp4: fix another race with SendDecline=yesYu Watanabe2020-07-162-41/+66
| | | | | | | | | | | | | | | | | | | | If the SD_IPV4ACD_EVENT_BIND event happens before all routes are assigned, then the link stuck in configuring state.
| * | | network: dhcp4: also release old lease in dhcp_lease_lost()Yu Watanabe2020-07-163-4/+4
| | | | | | | | | | | | | | | | | | | | The lease lost may happen during renewing address. If it happens, assertion hits in dhcp4_release_old_lease().
* | | | Revert "selinux: cache enforced status and treat retrieve failure as ↵Lennart Poettering2020-07-163-36/+6
| |/ / |/| | | | | | | | | | | | | | enforced mode" This reverts commit 257188f80ce1a083e3a88b679b898a73fecab53b.
* | | dhcp4: only renewing lease when the client already has a leaseYu Watanabe2020-07-161-1/+1
| | | | | | | | | | | | | | | | | | Follow-up for ceaec54a3c8366e81863a7d0d9c1f1d9f09960e1. Hopefully fixes #16299.
* | | load-fragment: downgrade log messages we ignore to LOG_WARNINGLennart Poettering2020-07-161-2/+2
| | | | | | | | | | | | | | | We typically don't log above LOG_WARNING about issues we then go on to ignore. Do so here, too
* | | mountpoint-util: fix error handlingLennart Poettering2020-07-161-1/+1
|/ /
* | core: fix invalid assertionLennart Poettering2020-07-161-2/+4
| | | | | | | | We miscounted here, and would hit an assert once too early.
* | network: fix typoChristian Göttsche2020-07-161-1/+1
|/
* update TODOLennart Poettering2020-07-151-0/+6
|
* Merge pull request #16396 from yuwata/network-configured-flagZbigniew Jędrzejewski-Szmek2020-07-1549-260/+559
|\ | | | | network: about xxx_configured flags
| * network: drop doubled white spaceYu Watanabe2020-07-156-7/+7
| |
| * network: free address when it is removedYu Watanabe2020-07-151-0/+2
| |
| * network: dhcp4: do not assign new address before old one is not removedYu Watanabe2020-07-152-147/+241
| | | | | | | | | | | | | | | | | | | | | | | | | | If DHCP4 client lost a lease, and then soon acquire new lease, then the removal of the old address may not be completed. If that happens, and the new and old addresses are the same, then the new address will be considered as a foreign address. Such a situation can occur when the DHCP4 server is restarted. This makes networkd wait for the removal of the old address when a new lease is acquired. This also makes the link in configuring state when renewing address.
| * network: do not call link_check_ready() in ↵Yu Watanabe2020-07-151-3/+2
| | | | | | | | | | | | link_request_set_routing_policy_rule() It will be called in link_request_set_nexthop() or serveral handlers().
| * network: make link_request_set_nexthop() called from ↵Yu Watanabe2020-07-155-16/+28
| | | | | | | | | | | | link_request_set_routes() or route_handler() Then we can drop static_routes_ready() flag.
| * network: do not make link in configured state when no address is assignedYu Watanabe2020-07-151-0/+5
| | | | | | | | | | | | | | | | When DHCP6 and RA are enabled, and RA does not provide any addresses, then link may become configured state even if no address is assigned, due to the time-lag between RA completion and DHCP reply. This makes if DHCP is explicitly enabled, then link must have at least one valid address to be in the configured state.
| * network: ndisc: split ndisc_configured flag into for addresses and routesYu Watanabe2020-07-153-34/+52
| |
| * network: ndisc: do not ignore remaining addressesYu Watanabe2020-07-151-2/+1
| | | | | | | | Follow-up for c24c83dc67a63c88b0a537f4fa7f605b1fcbac39.
| * test-network: wait for addresses are not in tentative stateYu Watanabe2020-07-152-2/+2
| |