summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* hwdb: reindent commments and say that "*" should always be trailingZbigniew Jędrzejewski-Szmek2020-10-159-66/+77
|
* hwdb: update chromiumos autosuspend rulesZbigniew Jędrzejewski-Szmek2020-10-151-0/+2
|
* hwdb: mount matrix for Chuwi Hi8 (CWI509) (#17355)Máté Pozsgay2020-10-151-0/+4
|
* Merge pull request #17354 from dtardon/udev-cleanupZbigniew Jędrzejewski-Szmek2020-10-152-17/+8
|\ | | | | some udev cleanup
| * udev-rules: drop pointless castDavid Tardon2020-10-141-8/+8
| |
| * udev-ctrl: drop workaround for old kernel bugDavid Tardon2020-10-141-9/+0
| | | | | | | | | | | | It's been 7 years. That should be long enough :-) This reverts commit b97caef538ae37bd2dc04fc15b448c12a2c9422b.
* | sd-bus: break the loop in bus_ensure_running() if the bus is not connectingZbigniew Jędrzejewski-Szmek2020-10-151-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | This might fix #17025: > the call trace is > bus_ensure_running -> sd_bus_process -> bus_process_internal -> process_closeing --> sd_bus_close > | > \-> process_match We ended doing callouts to the Disconnected matches from bus_ensure_running() and shouldn't. bus_ensure_running() should never do callouts. This change should fix this however: once we notice that the connection is going down we will now fail instantly with ENOTOCONN instead of calling any callbacks.
* | Merge pull request #17317 from yuwata/network-gateway-dhcp4-raYu Watanabe2020-10-1514-82/+143
|\ \ | | | | | | network: about Gateway=_dhcp4 or _ipv6ra
| * | test-network: do not use deprecated valueYu Watanabe2020-10-152-2/+2
| | |
| * | network: warn if dynamic gateway is specified but corresponding protocol is ↵Yu Watanabe2020-10-151-1/+14
| | | | | | | | | | | | disabled
| * | network: introduce network_adjust_dhcp()Yu Watanabe2020-10-153-16/+30
| | |
| * | network: introduce network_adjust_ipv6_accept_ra()Yu Watanabe2020-10-155-29/+22
| | |
| * | network: when Gateway=_dhcp4, set several properties based on lease if they ↵Yu Watanabe2020-10-155-6/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | are not explicitly specified Before this commit, event when Gateway=_dhcp4 or _ra is set, the route was configured with 'protocol static', and other properties specified by RouteTable=, RouteMTU=, or etc, were ignored. This commit makes set the route protocol based on the protocol the gateway address is obtained, and apply other settings if it is not explicitly specified in the [Route] section.
| * | network: determine a [Route] section will be used or not by gateway family ↵Yu Watanabe2020-10-152-4/+2
| | | | | | | | | | | | | | | | | | | | | instead of route family By this commit, user can configure dynamic IPv6 Gateway with IPv4 destination.
| * | network: when Gateway=_dhcp, assume gateway family based on other settingsYu Watanabe2020-10-151-13/+30
| | |
| * | network: rename Gateway=_dhcp6 -> Gateway=_ipv6raYu Watanabe2020-10-152-5/+4
| | |
| * | network: rename gateway_from_dhcp -> gateway_from_dhcp_or_raYu Watanabe2020-10-154-10/+10
|/ / | | | | | | As for IPv6 case gateway is given by RA.
* | Merge pull request #17351 from poettering/exec-rt-typo-fixLennart Poettering2020-10-142-6/+37
|\ \ | | | | | | fix one character typo in execute.c
| * | core: debug log about received fdsLennart Poettering2020-10-141-0/+18
| | |
| * | execute: make sure some more functions follow coding styleLennart Poettering2020-10-141-5/+18
| | | | | | | | | | | | | | | Initialize all return values on success, as our usual coding style suggests.
| * | execute: fix single character typoLennart Poettering2020-10-141-1/+1
| | | | | | | | | | | | | | | | | | Corrects: c413bb28df0996be99fd6b3f2335dfe8739d62fb Fixes: #17313
* | | Merge pull request #17350 from poettering/bus-read-arrayLennart Poettering2020-10-142-14/+22
|\ \ \ | | | | | | | | sd-bus: initialize return values on success in sd_bus_message_read_ar…
| * | | man: update sd_bus_message_read_array() docs to clarify return value 0 vs. 1Lennart Poettering2020-10-141-13/+16
| | | |
| * | | sd-bus: initialize return values on success in sd_bus_message_read_array()Lennart Poettering2020-10-141-1/+6
| | | | | | | | | | | | | | | | Fixes: #17346
* | | | bootctl: separate boot loader specific commands in man and --helpLennart Poettering2020-10-142-63/+90
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bootctl implements three types of operation: those that work with an EFI boot loader, those which work with any EFI boot loader that implements the boot loader spec + interface, and finally those specific to sd-boot. Previously the --help text and the man page mixed them all up. Let's put them clearly in three separate sections however, to communicate clearly what is supposed to work everywhere, and what is specific to systemd-boot or boot loaders implementing the two specs. This adjusts wording here and there, but is mostly just about re-ordering existing docs, and putting them under new sections.
* | | Merge pull request #17270 from keszybz/less-secure-modeLennart Poettering2020-10-145-70/+148
|\ \ \ | | | | | | | | Use less in "secure" mode when under sudo
| * | | pager: make pager secure when under euid is changed or explicitly requestedZbigniew Jędrzejewski-Szmek2020-10-142-27/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The variable is renamed to SYSTEMD_PAGERSECURE (because it's not just about less now), and we automatically enable secure mode in certain cases, but not otherwise. This approach is more nuanced, but should provide a better experience for users: - Previusly we would set LESSSECURE=1 and trust the pager to make use of it. But this has an effect only on less. We need to not start pagers which are insecure when in secure mode. In particular more is like that and is a very popular pager. - We don't enable secure mode always, which means that those other pagers can reasonably used. - We do the right thing by default, but the user has ultimate control by setting SYSTEMD_PAGERSECURE. Fixes #5666. v2: - also check $PKEXEC_UID v3: - use 'sd_pid_get_owner_uid() != geteuid()' as the condition
| * | | test-login: always test sd_pid_get_owner_uid(), modernizeZbigniew Jędrzejewski-Szmek2020-10-131-61/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A long time some function only worked when in a session, and the test didn't execute them when sd_pid_get_session() failed. Let's always call them to increase coverage. While at it, let's test for ==0 not >=0 where we don't expect the function to return anything except 0 or error.
| * | | pager: set $LESSSECURE whenver we invoke a pagerLennart Poettering2020-10-074-2/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some extra safety when invoked via "sudo". With this we address a genuine design flaw of sudo, and we shouldn't need to deal with this. But it's still a good idea to disable this surface given how exotic it is. Prompted by #5666
* | | | Merge pull request #17188 from keszybz/envvars-posixLennart Poettering2020-10-144-49/+100
|\ \ \ \ | | | | | | | | | | Follow (mostly) POSIX rules for environment variables
| * | | | systemctl: ignore invalid variables in import-environmentZbigniew Jędrzejewski-Szmek2020-10-121-3/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When doing import-environment, we shouldn't fail if some assignment is invalid. OTOH, if the invalid assignment is specified as a positional argument, we should keep failing. This would also fix https://bugzilla.redhat.com/show_bug.cgi?id=1754395, by ignoring certain variables which are not important in that scenario. It seems like the right thing to do in general.
| * | | | basic/env-util: (mostly) follow POSIX for what variable names are allowedZbigniew Jędrzejewski-Szmek2020-10-123-27/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was some confusion about what POSIX says about variable names: names shall not contain the character '='. For values to be portable across systems conforming to POSIX.1-2008, the value shall be composed of characters from the portable character set (except NUL and as indicated below). i.e. it allows almost all ASCII in variable names (without NUL and DEL and '='). OTOH, it says that *utilities* use a smaller set of characters: Environment variable names used by the utilities in the Shell and Utilities volume of POSIX.1-2008 consist solely of uppercase letters, digits, and the <underscore> ( '_' ) from the characters defined in Portable Character Set and do not begin with a digit. When enforcing variable names in environment blocks, we need to use this first definition, so that we can propagate all valid variables. I think having non-printable characters in variable names is too much, so I took out the whitespace stuff from the first definition. OTOH, when we use *shell syntax*, for example doing variable expansion, it seems enough to support expansion of variables that the shell would allow. Fixes #14878, https://bugzilla.redhat.com/show_bug.cgi?id=1754395, https://bugzilla.redhat.com/show_bug.cgi?id=1879216.
| * | | | test-env-util: print function headersZbigniew Jędrzejewski-Szmek2020-10-121-20/+42
| | | | |
* | | | | Merge pull request #16968 from yuwata/remove-old-device-on-move-eventLennart Poettering2020-10-1410-127/+259
|\ \ \ \ \ | |_|_|/ / |/| | | | core, udev: remove old device on move event
| * | | | test: add test for device renaming issue #16967Yu Watanabe2020-09-152-0/+31
| | | | |
| * | | | udev: merge rules for bluetooth deviceYu Watanabe2020-09-151-2/+2
| | | | |
| * | | | udev: do not update return value on failureYu Watanabe2020-09-151-1/+0
| | | | |
| * | | | udev: allow to match OriginalName= with renamed interface nameYu Watanabe2020-09-151-19/+8
| | | | |
| * | | | udev: re-assign ID_NET_DRIVER=, ID_NET_LINK_FILE=, ID_NET_NAME= properties ↵Yu Watanabe2020-09-152-4/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | on non-'add' uevent Previous commit makes drop ID_NET_DRIVER=, ID_NET_LINK_FILE=, and ID_NET_NAME= properties for network interfaces on 'move' uevent. ID_NET_DRIVER= and ID_NET_LINK_FILE= properties are used by networkctl. ID_NET_NAME= may be used by end-user rules or programs. So, let's re-assign them on 'move' uevent. (Note that strictly speaking, this makes them re-assigned on all but 'remove' uevent.)
| * | | | Revert "udev: import the full db on MOVE events for devices without dev_t"Yu Watanabe2020-09-151-9/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit b081b27e1433cdc7ac72b25ae8b4db887d79187f. If a network interface get a 'move' event, then previously SYSTEMD_ALIAS= property still contains an old alias, and the old alias .device unit will not be removed. This makes all properties cleared on 'move' event, and then old alias .device unit will be removed by pid1. Fixes #16967.
| * | | | udev: split link_config_apply() into small piecesYu Watanabe2020-09-152-88/+158
| | | | |
| * | | | ethtool: constify arguments for ethtool_set_xxx()Yu Watanabe2020-09-152-8/+8
| | | | |
| * | | | core/device: remove .device unit corresponding to DEVPATH_OLDYu Watanabe2020-09-151-0/+26
| | | | | | | | | | | | | | | | | | | | Partially fixes #16967.
* | | | | Merge pull request #17338 from poettering/close-rangeLennart Poettering2020-10-147-8/+240
|\ \ \ \ \ | |_|_|_|/ |/| | | | make use of new kernel 5.9 close_range() syscall in close_all_fds()
| * | | | update TODOLennart Poettering2020-10-141-2/+0
| | | | |
| * | | | test-fd-util: add test case for close_all_fd()Lennart Poettering2020-10-141-0/+96
| | | | |
| * | | | fd-util: port close_all_fds() to close_range()Lennart Poettering2020-10-141-0/+90
| | | | |
| * | | | missing: add close_range() wrapperLennart Poettering2020-10-142-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | The syscall was added in 5.9 and is not yet exposed in glibc, hence define our own wrapper.
| * | | | seccomp: allowlist close_range() by default in @basic-ioLennart Poettering2020-10-141-0/+1
| | | | |
| * | | | alloc-util: avoid allocating zero size memory blocksLennart Poettering2020-10-141-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | It's not clear what libc's make of this. We clamp to 1 byte allocations in most cases already, let's add this for a few where this was missing.