Mike Yuan [Sun, 3 Mar 2024 10:13:52 +0000 (18:13 +0800)]
extract-word: modernize extract_many_words
Mike Yuan [Sun, 3 Mar 2024 09:56:57 +0000 (17:56 +0800)]
core/service: minor cleanup for service_add_fd_store
Luca Boccassi [Sat, 2 Mar 2024 22:07:22 +0000 (22:07 +0000)]
Merge pull request #31594 from YHNdnzj/logind-seat-basename
logind: several coding style cleanups
Lennart Poettering [Sat, 2 Mar 2024 18:39:13 +0000 (19:39 +0100)]
hostnamed: use sd_bus_reply_method_return() to shorten code a bit
Zbigniew Jędrzejewski-Szmek [Sat, 2 Mar 2024 10:26:38 +0000 (11:26 +0100)]
docs/UEFI_SECURITY: minor tweaks to the text
Oxford comma, some mistakes in counts, and splitting of long sentences.
Lennart Poettering [Fri, 1 Mar 2024 20:46:46 +0000 (21:46 +0100)]
resolved: explicitly disconnect all left-over TCP connections when coming back from suspend
Fixes: #13730 (original reporter's log shows the TCP connection needed
to time out first)
Piotr Drąg [Sat, 2 Mar 2024 15:06:15 +0000 (16:06 +0100)]
po: add false positives to POTFILES.skip
Scripts used to detect files that should be in POTFILES.in, like
intltool-update -m used on https://l10n.gnome.org/module/systemd/,
falsely detect these files as containing translations. Avoid this
behavior by putting the files in POTFILES.skip.
Mike Yuan [Sat, 2 Mar 2024 15:46:00 +0000 (23:46 +0800)]
logind-{session,seat}: get rid of basename() in _new()
Mike Yuan [Sat, 2 Mar 2024 15:44:14 +0000 (23:44 +0800)]
logind-device: remove unneeded 'struct'
Mike Yuan [Sat, 2 Mar 2024 15:43:39 +0000 (23:43 +0800)]
logind: place 'ret' param at last
Luca Boccassi [Sat, 2 Mar 2024 11:47:44 +0000 (11:47 +0000)]
Merge pull request #31587 from yuwata/udev-rps-follow-ups
udev: follow-ups for RPS setting
Yu Watanabe [Sat, 2 Mar 2024 06:31:29 +0000 (15:31 +0900)]
Merge pull request #31586 from YHNdnzj/progress-bar-minor-followup
shared/pretty-print: minor follow-up for progress bar
Yu Watanabe [Sat, 2 Mar 2024 06:31:00 +0000 (15:31 +0900)]
Merge pull request #31583 from yuwata/sd-lldp-json-follow-up
sd-lldp: fix assignment of capabilities in JSON output
Yu Watanabe [Sat, 2 Mar 2024 05:48:33 +0000 (14:48 +0900)]
test-network: wait for the interface being processed by udevd
Otherwise, even if the interface is available, the requested config may
not be applied to the interface yet.
This also merges multiple tests for RPS setting. Hopefully the
performance of the test is improved.
Yu Watanabe [Sat, 2 Mar 2024 05:34:49 +0000 (14:34 +0900)]
test-network: introduce udevadm() and friends
Yu Watanabe [Sat, 2 Mar 2024 05:45:44 +0000 (14:45 +0900)]
udev/net: fix ReceivePacketSteeringCPUMask=disable assignment
Follow-up for
0f30bf5886f839984df545df74e9658daf3533d2.
If 'mask' is newly allocated, previously the value was ignored.
Yu Watanabe [Sat, 2 Mar 2024 04:50:50 +0000 (13:50 +0900)]
fuzz-lldp-rx: fuzz lldp_rx_build_neighbors_json()
Addresses https://github.com/systemd/systemd/pull/31583#discussion_r1509882453.
Yu Watanabe [Sat, 2 Mar 2024 04:44:20 +0000 (13:44 +0900)]
test-network: check enabled capabilities in LLDP neighbors
Addresses https://github.com/systemd/systemd/pull/31583#discussion_r1509880349.
Yu Watanabe [Sat, 2 Mar 2024 02:08:18 +0000 (11:08 +0900)]
sd-lldp: fix assignment of capabilities in JSON output
Follow-up for
329146a9ac73ac3f91b80f318e3037041488087c.
Mike Yuan [Sat, 2 Mar 2024 03:33:29 +0000 (11:33 +0800)]
shared/pretty-print: use strrepa where appropriate
Mike Yuan [Sat, 2 Mar 2024 03:45:02 +0000 (11:45 +0800)]
shared/pretty-print: print color sequence only when needed
Follow-up for
71cb203a6ea6de409c6b9c042feda2ff655101e9
Yu Watanabe [Sat, 2 Mar 2024 02:57:36 +0000 (11:57 +0900)]
Lennart Poettering [Fri, 1 Mar 2024 20:43:21 +0000 (21:43 +0100)]
hashmap: reorder fields to pack structure better
When building with ENABLE_DEBUG_HASHMAP we can pack the hashmap iterator
structure a bit better.
Fixes: #31558
Lennart Poettering [Fri, 1 Mar 2024 22:42:32 +0000 (23:42 +0100)]
Merge pull request #31507 from poettering/import-modernize
importd: various modernizations
Lennart Poettering [Fri, 1 Mar 2024 22:42:10 +0000 (23:42 +0100)]
Merge pull request #31571 from poettering/hostnamed-show-more
hostnamectl: show product uuid/hardware serial in regular output, plus various fixes
Lennart Poettering [Fri, 1 Mar 2024 22:41:25 +0000 (23:41 +0100)]
Merge pull request #31274 from bluca/measure_engine
repart/measure/ukify: add support for OpenSSL engines/providers
Ronan Pigott [Fri, 1 Mar 2024 04:42:43 +0000 (21:42 -0700)]
resolve: skip IP_UNICAST_IF for local sockets
SO_BINDTODEVICE was used during connect() to fix an issue where
IP_UNICAST_IF was improperly ignored for route lookups made by connect
in linux. This has since been resolved upstream [1][2], but as a result
we must apply the local socket excpetion to IP_UNICAST_IF as well.
The SO_BINDTODEVICE is no longer necessary, but left in place for 5.x
kernels.
[1] https://lore.kernel.org/all/
20220829111554.GA1771@debian/
[2] https://lore.kernel.org/all/
20221208145437.GA75680@debian/
Lennart Poettering [Fri, 1 Mar 2024 21:39:27 +0000 (22:39 +0100)]
Merge pull request #31567 from YHNdnzj/service-unused-param
core/service: remove unused function param and minor cleanup
Lennart Poettering [Fri, 1 Mar 2024 21:39:11 +0000 (22:39 +0100)]
Merge pull request #31565 from YHNdnzj/safe_dlclose
dlfcn-util: use safe_dlclose for dlclosep
Lennart Poettering [Fri, 1 Mar 2024 13:43:20 +0000 (14:43 +0100)]
hostnamectl: display product uuid + hardware serial in regular status output
hostnamed provides this, hence hostnamectl should show it
Lennart Poettering [Fri, 1 Mar 2024 13:46:27 +0000 (14:46 +0100)]
hostnamed: add explicit BUS_ERROR_NO_HARDWARE_SERIAL error
For the very similar case of the product UUID we have its own error
BUS_ERROR_NO_PRODUCT_UUID if we have no UUID. Let's mirror this for the
hardware serial, and expose the same, to keep things nicely symmteric.
Lennart Poettering [Fri, 1 Mar 2024 13:46:00 +0000 (14:46 +0100)]
hostnamed: do some validation of the hw serial before we return it
Let's make sure the serial contains not control chars, and is UTF-8
clean. In particular the latter matters as D-Bus shouldn't kick us
from the bus.
Lennart Poettering [Fri, 1 Mar 2024 13:45:37 +0000 (14:45 +0100)]
hostnamed: in get_hardware_firmware_data() don't dup a string if we shan't return it
Lennart Poettering [Fri, 1 Mar 2024 13:44:27 +0000 (14:44 +0100)]
hostnamed: our base indentation is 8 spaces, not 9 spaces
No idea what was going on here...
Lennart Poettering [Fri, 1 Mar 2024 13:47:52 +0000 (14:47 +0100)]
bus-util: add generic parser for extracting id128 values from bus messages
Lennart Poettering [Tue, 27 Feb 2024 14:05:26 +0000 (15:05 +0100)]
update TODO
Lennart Poettering [Fri, 23 Feb 2024 21:50:30 +0000 (22:50 +0100)]
test: add integration test for importctl
(these are explicit tests, on top of the existing machinectl tests that
are now chainload importctl)
Lennart Poettering [Tue, 27 Feb 2024 08:39:57 +0000 (09:39 +0100)]
man: document new importctl/importd functionality
This also replaces the Fedora download example with another one from
Ubuntu, since Fedora's images these days no longer qualify as DDIs, they
have no distinctive partition type UUIDs set for multiple of their
partitions, hence the images cannot be booted. A bit sad. Let's provide
a command that just works in its place.
Lennart Poettering [Tue, 27 Feb 2024 10:08:49 +0000 (11:08 +0100)]
importd: add command to list downloaded images
It's a bit weird we allow importing/pulling/exporting images, but we
have no scheme for showing what#s already downloaded. Hence let's add
this, it's easy to add after all.
Lennart Poettering [Mon, 26 Feb 2024 18:04:48 +0000 (19:04 +0100)]
importd: pass log level to invoked child
Lennart Poettering [Mon, 26 Feb 2024 14:53:35 +0000 (15:53 +0100)]
import: mention explicitly which image directory we operate on
Also, let's move the similar message about sync() mode to more common
code.
Lennart Poettering [Mon, 26 Feb 2024 14:47:40 +0000 (15:47 +0100)]
import: downgrade HTTP error code log message levels
Let's downgrade log levels a bit on HTTP error codes. After all we
gracefully handle many of them, and we do generated an extra message for
the ones which are fatal anyway, hence there's no point in emphasizing
the HTTP erro message levels as we currently do.
Lennart Poettering [Mon, 26 Feb 2024 14:46:50 +0000 (15:46 +0100)]
importctl: draw a pretty progress bar while downloading
Everybody loves pretty terminal progress bar.
Lennart Poettering [Thu, 22 Feb 2024 17:54:39 +0000 (18:54 +0100)]
machinectl: chainload importctl for relevant verbs
Now that "importctl" exists, let's chainload it from machinectl for the
relevant verbs so that we only have a single implementation of the
logic.
Lennart Poettering [Fri, 23 Feb 2024 20:50:29 +0000 (21:50 +0100)]
importd: log the import callout that is going to be called
Lennart Poettering [Thu, 22 Feb 2024 17:50:32 +0000 (18:50 +0100)]
importd: make keeping pristine copy of downloaded images optional
Previously, when downloading an image, importd would first download them
into one image which it would then consider immutable (named after the
originating URL/etag), and then immediately make a copy of it (named
after the client chosen name).
This makes some sense in VM/container cases where the images are
typically mutable, and thus the original downloaded copy is of some
value.
For sysexts/confexts/portable this doesn't make much sense though, as
they are typically immutable. Hence make the concept optional.
This adds --keep-download=yes/no as a new option that controls the
above. Moreover it disables the behaviour for all image classes but
"machine". The behaviour remains enabled for "machine", for compat.
Lennart Poettering [Thu, 22 Feb 2024 11:31:03 +0000 (12:31 +0100)]
importd: validate local image names with the right helper
A while back we introduced image_name_is_valid() for validating image
file names. It's more liberal than hostname_is_valid() in many ways (and
allows version suffixes and such). Since importd deals in offline images
(as opposed to machined otherwise which deals in running machines),
let's hence use the right helper to validate the identifiers.
Lennart Poettering [Fri, 1 Mar 2024 15:13:59 +0000 (16:13 +0100)]
importlisttransfersxclient
Lennart Poettering [Thu, 22 Feb 2024 09:16:43 +0000 (10:16 +0100)]
importctl: add support for selecting image class to download
Lennart Poettering [Thu, 22 Feb 2024 10:47:34 +0000 (11:47 +0100)]
importd: tighten checks in fds passed to us
Lennart Poettering [Thu, 22 Feb 2024 08:43:01 +0000 (09:43 +0100)]
importd: add support for downloading sysext/confext/portable images too
This adds "Ex" versions of all bus calls import implements, that make
two changes:
1. A "class" parameter is added that allows choosing between
machine/sysext/confext/portable images to download. Depending on the
chose class the target directory is selected differently (i.e. not
just /var/lib/machines/, but alternatively /var/lib/portables/,
/var/lib/extensions/, /var/lib/confexts/.
2. The boolean flags are replaced by a 64bit flags parameter.
Lennart Poettering [Thu, 22 Feb 2024 12:32:35 +0000 (13:32 +0100)]
import: merge PullFlags enum into ImportFlags
The two enums are mostly the same, the former is just an extension of
the latter. Let's merge them, to simplify things. This is particularly
useful as we then can reuse this systematically as D-Bus method call
flags too, in a generic fashion that works for both imports and pulls
the same.
Pretty much just renaming of flags.
Lennart Poettering [Wed, 21 Feb 2024 15:42:40 +0000 (16:42 +0100)]
importctl: port tabular output for format-table.h APIs
Lennart Poettering [Fri, 16 Feb 2024 17:55:21 +0000 (18:55 +0100)]
importctl: modernize signal handling
Lennart Poettering [Fri, 16 Feb 2024 17:40:47 +0000 (18:40 +0100)]
importctl: add standalone client to importd
This is pretty much a 1:1 copy of the importd specific part of
machinectl.
We turn this into a separate tool, so that we can eventually make the
tool generic to also download other DDIs, not just machine images.
Lennart Poettering [Fri, 16 Feb 2024 17:20:51 +0000 (18:20 +0100)]
importd: modernize signal handling a bit
Lennart Poettering [Fri, 16 Feb 2024 17:20:36 +0000 (18:20 +0100)]
importd: trivial modernizations
Lennart Poettering [Fri, 16 Feb 2024 17:20:24 +0000 (18:20 +0100)]
importd: switch to pidref
Lennart Poettering [Fri, 23 Feb 2024 17:22:40 +0000 (18:22 +0100)]
curl-util: fix downloads from file:// URLs
if we try to open file:// URLs that don't exist, we'll not get IO/timer
events about it, hence it is not sufficient to check for completion in
these events. Let's add a defer event, to deal with that.
Also, curl_multi_info_read() is a queue, make sure to handle all events
that might be queued.
Lennart Poettering [Fri, 23 Feb 2024 20:51:02 +0000 (21:51 +0100)]
sd-event: make return code of sd_event_get_exit_code() optional
Lennart Poettering [Fri, 23 Feb 2024 21:46:04 +0000 (22:46 +0100)]
fd-util: O_DIRECTORY is fine in fd_verify_safe_flags() too
Lennart Poettering [Fri, 1 Mar 2024 14:10:56 +0000 (15:10 +0100)]
test74: create ssh empty dir all at the same place
A follow up for
8fddb50fd4de43993c4906baf19dae89ff8a021b, which mirrors
the change also in test 74.
Lennart Poettering [Fri, 1 Mar 2024 14:22:13 +0000 (15:22 +0100)]
machinectl: mention -V in --help text
Follow-up for
f82dcc3fc35883a73c8a03ad82d35abffc458676
Lennart Poettering [Fri, 1 Mar 2024 13:42:34 +0000 (14:42 +0100)]
busctl: don't hit an assert if we call invalid bus method names
We should validate this explicitly and generate a clear error string,
rather then hit an assert() later in the code.
Lennart Poettering [Fri, 1 Mar 2024 13:47:57 +0000 (14:47 +0100)]
vmspawn: actually pass UUID down to qemu
qemu then adds this to SMBIOS product uuid, and we can actually read it
from the payload.
Followup for
b0dc766852b2022080f123ac52aa90f2692c12e2
Luca Boccassi [Fri, 1 Mar 2024 16:53:50 +0000 (16:53 +0000)]
CI: free up diskspace before mkosi jobs
The runner has a lot of useless things installed, taking ~10GB, and
jobs have started to fail when booting images due to lack of disk
space, so delete some directories to make room.
2024-02-27T20:20:58.0998709Z ##[warning]You are running out of disk space. The runner will stop working when the machine runs out of disk space. Free space left: 0 MB
Co-authored-by: Daan De Meyer <daan.j.demeyer@gmail.com>
Luca Boccassi [Sun, 11 Feb 2024 00:34:19 +0000 (00:34 +0000)]
ukify: add support for engine signing of PCR signatures
Luca Boccassi [Sat, 10 Feb 2024 23:51:57 +0000 (23:51 +0000)]
measure: add support for --certificate and --private-key-source for engine/provider signing
Allow signing with an OpenSSL engine/provider, such as PKCS11. A public key is
not enough, a full certificate is needed for PKCS11, so a new parameter is
added for that too.
Luca Boccassi [Sun, 11 Feb 2024 20:15:51 +0000 (20:15 +0000)]
repart: add --private-key-source and drop --private-key-uri
It turns out it's mostly PKCS11 that supports the URI format,
and other engines just take files. For example the tpm2-tss-openssl
engine just takes a sealed private key file path as the key input,
and the engine needs to be specified separately.
Add --private-key-source=file|engine:foo|provider:bar to
manually specify how to use the private key parameter.
Follow-up for
0a8264080a5d4b5e13e65eed80ac98a476f7fe43
Adrian Vovk [Mon, 5 Feb 2024 00:21:29 +0000 (19:21 -0500)]
user-record: Add preferredSession{Type,Launcher}
These will be used by display managers to pre-select the user's
preferred desktop environment and display server type. On homed, the
display manager will also be able to set these fields to cache the
user's last selection.
Lennart Poettering [Fri, 1 Mar 2024 09:12:48 +0000 (10:12 +0100)]
tree-wide: switch dlopen hooks over to DLSYM_PROTOTYPE()/DLSYM_FUNCTION()
We have these pretty macros, let's use them everywhere (so far we mostly
used them for newer additions only).
This PR is mostly an excercise in "perl -p -i -e", but there are some
special cases:
* idn-util.c exposes a function whose prototype in the official library
headers is marked with the "const" attribute, and this apparently does
not propagate along typeof() correctly and then
__builtin_types_compatible_p() fails later because it detects that
prototype and original function don't match in prototype.
* libbpf removed some symbols in newer versions, hence we need to define
some prototypes manually to still be able to build.
* libcryptsetup marked a symbol as deprecated we want to use (knowing it
is deprecated). By using the macros this is detected by the compiler.
We work around it via the usual warning off macros.
Note by using these macros we assume that all symbols are known during
build time. Which might not be the case. We might need to revert this
commit for some symbols if this trips up builds on older distros.
Mike Yuan [Fri, 1 Mar 2024 13:48:23 +0000 (21:48 +0800)]
core/service: remove unused function param and minor cleanup
Xiaotian Wu [Thu, 16 Nov 2023 12:01:50 +0000 (20:01 +0800)]
uki: Support zboot efistub kernel
Generic EFI zboot added since kernel 6.1
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/firmware/efi/libstub/Makefile.zboot?h=v6.1
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/firmware/efi/libstub/zboot-header.S?h=v6.1
Mike Yuan [Fri, 1 Mar 2024 13:43:12 +0000 (21:43 +0800)]
core/service: rearrange variables, use ASSERT_PTR
Mike Yuan [Fri, 1 Mar 2024 13:45:32 +0000 (21:45 +0800)]
core/service: reorder two functions
dependabot[bot] [Fri, 1 Mar 2024 09:59:59 +0000 (09:59 +0000)]
build(deps): bump meson from 1.3.1 to 1.3.2 in /.github/workflows
Bumps [meson](https://github.com/mesonbuild/meson) from 1.3.1 to 1.3.2.
- [Release notes](https://github.com/mesonbuild/meson/releases)
- [Commits](https://github.com/mesonbuild/meson/compare/1.3.1...1.3.2)
---
updated-dependencies:
- dependency-name: meson
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Mike Yuan [Fri, 1 Mar 2024 10:57:13 +0000 (18:57 +0800)]
dlfcn-util: use safe_dlclose for dlclosep
Mike Yuan [Fri, 1 Mar 2024 10:48:39 +0000 (18:48 +0800)]
shared/userdb: remove unneeded cast for dlsym
dependabot[bot] [Fri, 1 Mar 2024 09:18:57 +0000 (09:18 +0000)]
build(deps): bump actions/upload-artifact from 4.3.0 to 4.3.1
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.3.0 to 4.3.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/
26f96dfa697d77e81fd5907df203aa23a56210a8...
5d5d22a31266ced268874388b861e4b58bb5c2f3)
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Luca Boccassi [Thu, 29 Feb 2024 20:47:46 +0000 (20:47 +0000)]
test: enable PAM debug logs in TEST-46-HOMED
dependabot[bot] [Fri, 1 Mar 2024 09:19:02 +0000 (09:19 +0000)]
build(deps): bump github/codeql-action from 3.22.12 to 3.24.6
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.22.12 to 3.24.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/
012739e5082ff0c22ca6d6ab32e07c36df03c4a4...
8a470fddafa5cbb6266ee11b37ef4d8aae19c571)
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
dependabot[bot] [Fri, 1 Mar 2024 09:19:11 +0000 (09:19 +0000)]
build(deps): bump redhat-plumbers-in-action/differential-shellcheck
Bumps [redhat-plumbers-in-action/differential-shellcheck](https://github.com/redhat-plumbers-in-action/differential-shellcheck) from 5.0.2 to 5.1.0.
- [Release notes](https://github.com/redhat-plumbers-in-action/differential-shellcheck/releases)
- [Changelog](https://github.com/redhat-plumbers-in-action/differential-shellcheck/blob/main/docs/CHANGELOG.md)
- [Commits](https://github.com/redhat-plumbers-in-action/differential-shellcheck/compare/
91e2582e40236f831458392d905578d680baa138...
b9df2a9417f69c056e0aeaf870abd9a2065a403e)
---
updated-dependencies:
- dependency-name: redhat-plumbers-in-action/differential-shellcheck
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Yu Watanabe [Fri, 1 Mar 2024 03:45:52 +0000 (12:45 +0900)]
Merge pull request #31498 from ssahani/bond
netdev: bond - add support for peer_notif_delay
Yu Watanabe [Fri, 1 Mar 2024 03:18:53 +0000 (12:18 +0900)]
Merge pull request #31502 from yuwata/network-lldp-json
network: support to dump LLDP neighbors in JSON format
Yu Watanabe [Fri, 1 Mar 2024 03:18:19 +0000 (12:18 +0900)]
Merge pull request #31555 from yuwata/sd-ndisc-trivial-cleanups
sd-ndisc: trivial cleanups
Yu Watanabe [Thu, 29 Feb 2024 03:37:26 +0000 (12:37 +0900)]
sd-ndisc: drop unused sd_ndisc_router_get_raw()
Yu Watanabe [Thu, 29 Feb 2024 03:46:48 +0000 (12:46 +0900)]
sd-ndisc: use _packed_ attribute
Luca Boccassi [Fri, 1 Mar 2024 00:44:52 +0000 (00:44 +0000)]
Merge pull request #31551 from keszybz/rpm-macro-kernel-install
New rpm macro %_kernel_install_dir
Yu Watanabe [Fri, 1 Mar 2024 00:21:55 +0000 (09:21 +0900)]
icmp6-packet: check the alignment of struct nd_opt_hdr for safety
Addresses https://github.com/systemd/systemd/pull/31492#discussion_r1507481748.
Yu Watanabe [Mon, 26 Feb 2024 02:46:55 +0000 (11:46 +0900)]
test-network: add more test cases for LLDP
Yu Watanabe [Mon, 26 Feb 2024 06:48:49 +0000 (15:48 +0900)]
sd-lldp-rx: drop unused functions
These are not used anymore.
Yu Watanabe [Mon, 26 Feb 2024 06:47:46 +0000 (15:47 +0900)]
network/lldp: do not save LLDP neighbors under /run/systemd
Now LLDP neighbors are exposed through varlink. Hence, it is not
necessary to save to a file.
Yu Watanabe [Sun, 25 Feb 2024 06:31:23 +0000 (15:31 +0900)]
networkctl: use varlink method to dump LLDP neighbors
`networkctl lldp` and `networkctl status INTERFACE` now use varlink
call to the networkd to query LLDP neighbors.
Then, this allows to dump LLDP neighbors in JSON format.
Co-authored-by: Tomáš Pecka <tomas.pecka@cesnet.cz>
Yu Watanabe [Mon, 26 Feb 2024 01:32:51 +0000 (10:32 +0900)]
networkctl: rename check_netns_match() -> varlink_connect_networkd()
Then optionally return the varlink connection to the caller.
Yu Watanabe [Sun, 25 Feb 2024 05:16:47 +0000 (14:16 +0900)]
network/varlink: add varlink method to get LLDP neighbors
The method provides the list of LLDP neighbors.
Co-authored-by: Tomáš Pecka <tomas.pecka@cesnet.cz>
Tomáš Pecka [Thu, 7 Oct 2021 09:16:57 +0000 (11:16 +0200)]
sd-lldp-rx: serialize LLDP neighbors to JSON format
Add functions serializing LLDP neighbors to JSON (JsonVariant).
The entry contains a chassis id, system name and port id of the remote
neighbor. Also it possibly contains an integer coding the enabled system
capabilities and port description.
Yu Watanabe [Fri, 1 Mar 2024 00:18:52 +0000 (09:18 +0900)]
Merge pull request #31492 from yuwata/icmp6-packet
sd-ndisc: introduce ICMP6Packet and relevant functions, and use them
Eli Schwartz [Wed, 21 Feb 2024 02:59:13 +0000 (21:59 -0500)]
fix the value of default shells to use /bin and not /usr/bin
Partially reverts commit
b0d3095fd6cc1791a38f57a1982116b4475244ba.
While it is generally worthwhile for systemd to drop split-usr support,
these options are NOT about split-usr support. The universal location of
POSIX sh is always /bin/sh. Bash is pretty reasonably standardized there
too.
This happens irrespective of /bin being a symlink to /usr/bin.
Ramifications of this change include things like:
- portably running shell scripts that might run very nearly anywhere
- /etc/shells support
For standardization and compatibility reasons, these commands with these
paths need to be consistently found on any system, and thus distros make
sure this works, although even on split-usr systems /usr/bin/bash may be
a symlink to /bin/bash.
Embedding the *access path* of bash as /usr/bin/bash in systemd, for
example in libnss_systemd.so, means that login shells must agree with
systemd on how they invoke the shell. End result: users fail to login
because of access violations.
This cannot be fixed by "fixing PAM" because PAM does not follow
symlinks by design: one example is that it needs to treat rbash as
different from bash.
Fixes: https://bugs.gentoo.org/919749
Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
Lennart Poettering [Thu, 29 Feb 2024 17:19:07 +0000 (18:19 +0100)]
ssh-generator: don't do AF_VSOCK stuff if we run in a container
Tighten our VM check: whether we run in a VM is not enough to do
AF_VSOCK. We also need to check if we are run in a container, because if
we run in a container inside a VM then we should *not* do the AF_VSOCK
stuff, but leave the port free for the VM itself.
As discussed here:
https://github.com/systemd/systemd/pull/31544#issuecomment-
1971455401
Zbigniew Jędrzejewski-Szmek [Thu, 29 Feb 2024 20:38:03 +0000 (21:38 +0100)]
rpm/macros: add %_kernel_install_dir
This makes it easier for people packaging kernel-install plugins
to get the path right.
E.g. https://src.fedoraproject.org/rpms/python-virt-firmware/pull-request/3
fixes an issue where %{_libdir}/kernel/install.d was used,
which gives incorrect results on 64-bit architectures.
%_kernel_install_dir will make this even easier.