Yu Watanabe [Tue, 13 Dec 2022 08:59:35 +0000 (17:59 +0900)]
locale-setup: split locale_context_load() into small pieces
No functional change, just refactoring and preparation for later
commits.
Yu Watanabe [Tue, 13 Dec 2022 08:30:12 +0000 (17:30 +0900)]
localed: avoid TOCTOU in loading config
Yu Watanabe [Tue, 13 Dec 2022 08:24:19 +0000 (17:24 +0900)]
env-file: introduce parse_env_file_fd()
Yu Watanabe [Mon, 12 Dec 2022 06:53:50 +0000 (15:53 +0900)]
env-file: several cleanups
- add missing assertions,
- rename function arguments for storing results,
- add typedef for callback.
Yu Watanabe [Wed, 14 Dec 2022 11:17:56 +0000 (20:17 +0900)]
Merge pull request #25726 from dtardon/cleanups
Several small cleanups
Yu Watanabe [Wed, 14 Dec 2022 07:10:05 +0000 (16:10 +0900)]
resolve: fix NULL-pointer dereference
Fixes a bug introduced by
16a6bc5a7a5da2482d96f7dc43da360ceab1c320.
Fixes CID#
1501514.
Jiayi Chen [Wed, 14 Dec 2022 08:27:50 +0000 (16:27 +0800)]
doc: add language decorator on the code block
Add `c` decorator on the code block for applying syntax highlighting.
David Tardon [Wed, 30 Nov 2022 15:56:40 +0000 (16:56 +0100)]
btrfs-util: shorten a bit
David Tardon [Wed, 30 Nov 2022 15:46:05 +0000 (16:46 +0100)]
machine: propagate error from machine_new
David Tardon [Wed, 30 Nov 2022 15:42:08 +0000 (16:42 +0100)]
machine: use _cleanup_ in machine_new
David Tardon [Wed, 30 Nov 2022 15:18:06 +0000 (16:18 +0100)]
localed-util: use _cleanup_ harder
David Tardon [Wed, 30 Nov 2022 15:02:11 +0000 (16:02 +0100)]
busctl-introspect: use _cleanup_
Zbigniew Jędrzejewski-Szmek [Wed, 14 Dec 2022 07:37:16 +0000 (08:37 +0100)]
Merge pull request #25689 from YHNdnzj/systemctl-exit-code
systemctl: make is-* return EXIT_PROGRAM_OR_SERVICES_STATUS_UNKNOWN(4) when no unit file is found
Daan De Meyer [Tue, 13 Dec 2022 18:14:43 +0000 (18:14 +0000)]
repart: Rename --skip-partitions to --defer-partitions
Defer is better because it indicates that we still intend to
populate these partitions later.
Luca Boccassi [Wed, 14 Dec 2022 00:38:55 +0000 (01:38 +0100)]
Merge pull request #25706 from yuwata/hwdb-pointing-stick
hwdb: several fixes for pointing stick
Luca Boccassi [Wed, 14 Dec 2022 00:38:11 +0000 (01:38 +0100)]
Merge pull request #25725 from keszybz/oom-policy-fixup
Add missing integration of OOMPolicy in scope units
Daan De Meyer [Tue, 13 Dec 2022 18:04:48 +0000 (18:04 +0000)]
mkosi: Enable CONFIG_ZBOOT
Required to boot mkosi images with systemd-boot on aarch64.
Zbigniew Jędrzejewski-Szmek [Tue, 13 Dec 2022 19:24:08 +0000 (20:24 +0100)]
NEWS: add a bunch of entries for v253
During the call today we agreed to work towards -rc1 in January. Nevertheless,
I already started writing this up and I'll push it so it doesn't get lost.
I didn't include all the changes to systemd-repart, because those are still in
flux.
Mike Yuan [Mon, 12 Dec 2022 16:39:31 +0000 (00:39 +0800)]
TEST-26-SYSTEMCTL: test about systemctl return codes for is-* verbs
We should return 4 when no unit file is found.
See also: #25689 #25680
Mike Yuan [Sat, 10 Dec 2022 12:55:42 +0000 (20:55 +0800)]
systemctl: is-*: return correct code when no unit is found
According to systemctl(1), we should use LSB return code 4
(EXIT_PROGRAM_OR_SERVICES_STATUS_UNKNOWN) when the state
is "no such unit" for is-{active,failed,enabled} verbs.
Fixes #25680
Yu Watanabe [Mon, 12 Dec 2022 04:51:38 +0000 (13:51 +0900)]
hwdb: also add a generic entry for DualPoint Stick
Also mention Dell DualPoint Stick in the comment.
Yu Watanabe [Mon, 12 Dec 2022 04:41:34 +0000 (13:41 +0900)]
hwdb: add comments about matching entries
Follow-up for
57bb707d48131f4daad2b1b746eab586eb66b4f3.
This makes the comments in 60-evdev.hwdb, 60-keyboard.hwdb, and
70-pointingstick.hwdb consistent.
Yu Watanabe [Mon, 12 Dec 2022 04:57:42 +0000 (13:57 +0900)]
hwdb: drop trailing space
Yu Watanabe [Tue, 13 Dec 2022 16:44:12 +0000 (01:44 +0900)]
Merge pull request #25658 from yuwata/fuzz-etc-hosts
resolve: dedup entries in /etc/hosts
Zbigniew Jędrzejewski-Szmek [Tue, 13 Dec 2022 10:15:17 +0000 (11:15 +0100)]
coredump: cescape invalid json data before logging
In both cases, the json string is short, so we can print it, which is useful
for diagnosing invalid data in packages. But we need escape non-printable
characters.
https://bugzilla.redhat.com/show_bug.cgi?id=
2152685
I went over the rest of the codebase, and it seems that other calls to
json_parse() don't have this problem.
AndyChi [Tue, 13 Dec 2022 15:19:27 +0000 (23:19 +0800)]
hwdb: Add additional Dell models that require ACCEL_LOCATION=base (#25724)
David Tardon [Wed, 30 Nov 2022 14:44:25 +0000 (15:44 +0100)]
ratelimit: drop use of goto
David Tardon [Wed, 30 Nov 2022 14:18:15 +0000 (15:18 +0100)]
mountpoint-util: reduce variable scope
Zbigniew Jędrzejewski-Szmek [Tue, 13 Dec 2022 14:26:58 +0000 (15:26 +0100)]
core,man: add missing integration of OOMPolicy= in scopes
Fixup for
5fa098357e0ea9f05b00ed5b04a36ef9f64037db.
Zbigniew Jędrzejewski-Szmek [Tue, 13 Dec 2022 14:25:55 +0000 (15:25 +0100)]
man: rework description of OOMPolicy= a bit
One had to read to the very end of the long description to notice that
the setting is actually primarily intended for oomd. So let's mention oomd
right at the beginning.
January [Thu, 24 Nov 2022 13:13:17 +0000 (21:13 +0800)]
doc: add an example code to lock the whole disk
add an example to leverage `libsystemd` infrastructure to get the whole disk of a block device and take BSD lock on it #25046
Daan De Meyer [Tue, 13 Dec 2022 10:50:01 +0000 (10:50 +0000)]
execute: Pass AT_FDCWD instead of -1
Let's enforce that callers pass AT_FDCWD as read_dfd to load_credential()
to avoid an assert() in read_full_file_full() if read_dfd is -1.
Daan De Meyer [Tue, 13 Dec 2022 12:14:49 +0000 (12:14 +0000)]
mkosi: Drop i686 packages
These are only needed for some kernel selftests but they prevent
building the mkosi image on aarch64 systems so let's drop them
until mkosi has support for conditional configuration so we can
only add these packages on the right architecture.
Yu Watanabe [Wed, 7 Dec 2022 14:39:56 +0000 (23:39 +0900)]
resolve: dedup entries in /etc/hosts
This improves the performance of parsing the file and reduces memory pressure.
Running 'fuzz-etc-hosts timeout-strv' with valgrind,
Before:
total heap usage: 321,020 allocs, 321,020 frees, 15,820,387,193 bytes allocated
real 0m23.531s
user 0m21.458s
sys 0m1.961s
After:
total heap usage: 112,408 allocs, 112,408 frees, 7,297,480 bytes allocated
real 0m8.664s
user 0m8.545s
sys 0m0.065s
Hopefully fixes oss-fuzz#47708 (https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=47708).
Yu Watanabe [Wed, 7 Dec 2022 14:38:45 +0000 (23:38 +0900)]
resolve: introduce more hash-ops and use them
No functional changes, just refactoring.
Yu Watanabe [Tue, 13 Dec 2022 11:36:19 +0000 (20:36 +0900)]
resolve: use dns_name_hash_ops_free
No functional changes, just refactoring.
Yu Watanabe [Wed, 7 Dec 2022 13:35:09 +0000 (22:35 +0900)]
dns-domain: introduce dns_name_hash_ops_free
Preparation for later commits.
Yu Watanabe [Wed, 7 Dec 2022 13:34:40 +0000 (22:34 +0900)]
in-addr-util: introduce in_addr_data_hash_ops_free and expose its compare and hash functions
Preparation for later commits.
Yu Watanabe [Wed, 7 Dec 2022 14:14:46 +0000 (23:14 +0900)]
resolve: split manager_etc_hosts_lookup() into small parts
No functional changes, just refactoring.
Yu Watanabe [Wed, 7 Dec 2022 13:55:37 +0000 (22:55 +0900)]
resolve: adjust warning
Yu Watanabe [Wed, 7 Dec 2022 13:53:46 +0000 (22:53 +0900)]
resolve: merge two boolean variables
No functional changes, just refactoring.
Yu Watanabe [Wed, 7 Dec 2022 14:30:22 +0000 (23:30 +0900)]
resolve: introduce cleanup functions for EtcHostsItemBy{Address,Name}
No functional change, just refactoring and preparation for later
commits.
Yu Watanabe [Wed, 7 Dec 2022 13:48:14 +0000 (22:48 +0900)]
resolve: make etc_hosts_item_by_{address,name}_free() accept NULL
Yu Watanabe [Wed, 7 Dec 2022 13:41:17 +0000 (22:41 +0900)]
resolve: rename EtcHostsItem -> EtcHostsItemByAddress
Yu Watanabe [Wed, 7 Dec 2022 13:30:45 +0000 (22:30 +0900)]
resolve: rename etc_hosts_free() -> etc_hosts_clear()
Yu Watanabe [Tue, 13 Dec 2022 09:13:27 +0000 (18:13 +0900)]
Merge pull request #25713 from keszybz/hwdb-matching
Restore backwards compat in 60-evdev.rules
Peter Cai [Sat, 29 Oct 2022 23:00:53 +0000 (19:00 -0400)]
cryptsetup-fido2: Try all FIDO2 key slots when opening LUKS volume
After #25268, it is now possible to check whether a credential
is present on a FIDO2 token without actually attempting to retrieve said
credential. However, when cryptsetup plugins are not enabled, the
fallback unlock routines are not able to make multiple attempts with
multiple different FIDO2 key slots.
Instead of looking for one FIDO2 key slot when trying to unlock, we now
attempt to use all key slots applicable.
Fixes #19208.
Luca Boccassi [Mon, 12 Dec 2022 20:48:09 +0000 (21:48 +0100)]
Merge pull request #25375 from PeterCxy/fido2-fixups
Fixups for FIDO2 pre-flight checks
uerdogan [Mon, 12 Dec 2022 20:46:50 +0000 (21:46 +0100)]
Update 60-evdev.hwdb (#25704)
This solves Debian Bug report
1008760:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=
1008760.
Solution was inspired by this kernel bug report message:
https://bugzilla.kernel.org/show_bug.cgi?id=204967#c15.
My measured pad dimensions with a ruler were 85x44mm.
But I decided to take the 2x size reported by the current kernel
when invoking the touchpad-edge-detector command from the
libdev-tools package. Because this comment claims that the old
vs new kernel reportings differ by factor 2:
https://bugzilla.kernel.org/show_bug.cgi?id=204967#c3 .
Therefore I have used this command to get the new entry to 60-evdev.hwdb:
"root@pb:~# touchpad-edge-detector 80x34 /dev/input/event2
Touchpad ETPS/2 Elantech Touchpad on /dev/input/event2
Move one finger around the touchpad to detect the actual edges
Kernel says: x [0..1254], y [0..528]
Touchpad sends: x [0..2472], y [-524..528] -^C
Touchpad size as listed by the kernel: 40x17mm
User-specified touchpad size: 80x34mm
Calculated ranges: 2472/1052
Suggested udev rule:
# <Laptop model description goes here>
evdev:name:ETPS/2 Elantech Touchpad:dmi:bvnPackardBell:bvrV1.21:bd08/09/2012:br21.240:svnPackardBell:pnEasyNoteTS11HR:pvrV1.21:rvnPackardBell:rnSJV50_HR:rvrBaseBoardVersion:cvnPackardBell:ct10:cvrV1.21:*
EVDEV_ABS_00=0:2472:31
EVDEV_ABS_01=-524:528:31
EVDEV_ABS_35=0:2472:31
EVDEV_ABS_36=-524:528:31
"
Zbigniew Jędrzejewski-Szmek [Mon, 12 Dec 2022 13:11:46 +0000 (14:11 +0100)]
udevadm: emit deprecation notice in udevadm hwdb
This tool was "deprecated" back in
65eb4378c3e1de25383d8cd606909e64c71edc80,
but only by removing documentation. This is somewhat surprising, but udevadm
hwdb --update and systemd-hwdb update generate different databases. udevadm
runs in compat mode and (as far as I have been able to figure out from a quick
look), it omits filename information and does some other changes to the
datastructures. The consuming code (udev) is the same in both cases, so this
"compatibility mode" seems very strange. But I don't think it's worth trying to
figure out why things were done this way. Let's just push people towards the
new code.
Inspired by https://github.com/systemd/systemd/issues/25698#issuecomment-
1346298094.
Will Fancher [Sun, 11 Dec 2022 01:44:17 +0000 (20:44 -0500)]
sysroot: Support x-systemd.makefs
Luca Boccassi [Mon, 12 Dec 2022 20:42:36 +0000 (21:42 +0100)]
Merge pull request #25646 from yuwata/sd-id128-enomedium
sd-id128: make sd_id128_get_machine() return -ENOMEDIUM when not initialized
Lennart Poettering [Mon, 12 Dec 2022 14:43:38 +0000 (15:43 +0100)]
update TODO
Luca Boccassi [Mon, 12 Dec 2022 14:30:07 +0000 (15:30 +0100)]
Merge pull request #25615 from DaanDeMeyer/mkosi-kconfig
mkosi: Rework kconfig handling
Luca Boccassi [Mon, 12 Dec 2022 13:13:16 +0000 (14:13 +0100)]
Merge pull request #25692 from yuwata/resolve-rr-txt
resolve: drop recurstion from TXT field handling
Yu Watanabe [Thu, 8 Dec 2022 20:37:12 +0000 (05:37 +0900)]
sd-id128: fold do_sync flag into Id128FormatFlag
Yu Watanabe [Thu, 8 Dec 2022 06:49:02 +0000 (15:49 +0900)]
man: mention that sd_id128_get_boot() and friend may return -ENOSYS
And drop to mention sd_id128_get_boot_app_specific() may return -ENOENT
or -ENOMEDIUM. The function does not read /etc/machine-id. But reads a
file in the procfs, which is a kind of the kernel API. Hence the
failures are caused only when the system has wrong setup.
Yu Watanabe [Mon, 12 Dec 2022 13:03:52 +0000 (22:03 +0900)]
sd-id128: make sd_id128_get_boot() and friend return -ENOSYS when /proc/ is not mounted
Yu Watanabe [Thu, 8 Dec 2022 06:48:25 +0000 (15:48 +0900)]
sd-id128: make sd_id128_get_boot() and friend return -ENOMEDIUM
Yu Watanabe [Thu, 8 Dec 2022 06:43:26 +0000 (15:43 +0900)]
man: mention sd_id128_get_machine() or friend may return -ENOPKG
Yu Watanabe [Thu, 8 Dec 2022 06:18:28 +0000 (15:18 +0900)]
test: add tests for "uninitialized" string handling by id128_read_fd()
Yu Watanabe [Thu, 8 Dec 2022 05:30:31 +0000 (14:30 +0900)]
sd-id128: make id128_read() or friends return -ENOPKG when the file contents is "uninitialized"
Then, this drops ID128_PLAIN_OR_UNINIT. Also, this renames
Id128Format -> Id128FormatFlag, and make it bitfield.
Fixes #25634.
Yu Watanabe [Thu, 8 Dec 2022 05:20:03 +0000 (14:20 +0900)]
sd-id128: several cleanups
- use SD_ID128_STRING_MAX or friend,
- use sizeof(sd_id128_t),
- use newly introduced ascii_ishex().
Yu Watanabe [Thu, 8 Dec 2022 05:13:47 +0000 (14:13 +0900)]
string-util: introduce ascii_ishex()
Zbigniew Jędrzejewski-Szmek [Mon, 12 Dec 2022 12:37:08 +0000 (13:37 +0100)]
udev-builtin-keyboard: update description
Zbigniew Jędrzejewski-Szmek [Mon, 12 Dec 2022 11:52:12 +0000 (12:52 +0100)]
udev: rework 60-evdev.rules to be "additive"
We would execute up to four hwdb match patterns (+ the keyboard builtin):
After the first hit, we would skip the other patterns, because of the GOTO="evdev_end"
action.
57bb707d48131f4daad2b1b746eab586eb66b4f3 (rules: Add extended evdev/input match
rules for event nodes with the same name), added an additional match with
":phys:<phys>:ev:<ev>" inserted. This breaks backwards compatibility for user
hwdb patterns, because we quit after the first match.
In general hwdb properties are "additive". We often have a general rule that
matches a wider class and then some specific overrides. E.g. in this particular
case, we have a match for all trackpoints, and then a bunch of model-specific
settings.
So let's change the rules to try all the match patterns and combine the
received properties. We execute builtin-keyboard once at the end, if there was
at least one match.
Fixes #25698. Fixes https://bugzilla.redhat.com/show_bug.cgi?id=
2152226.
This also impacts other cases which I think would be very confusing for users.
Since we quit after a first successful match, if we had e.g. a match for
'evdev:input:b*v*p*' in out database, and the user added a match using
'evdev:name:*', which is the approach we document in the .hwdb files and which
users quite often use, it would be silently ignored. What's worse, if we added
our 'evdev:input:b*v*p*' match at a later point, user's match would stop
working. If we combine all the properties, we get more stable behaviour.
Luca Boccassi [Mon, 12 Dec 2022 12:26:42 +0000 (13:26 +0100)]
Merge pull request #25707 from yuwata/sd-device-fix-double-free
sd-device: fix double-free
Lennart Poettering [Mon, 12 Dec 2022 11:59:16 +0000 (12:59 +0100)]
update TODO
Yu Watanabe [Mon, 12 Dec 2022 06:04:02 +0000 (15:04 +0900)]
test: name_assign_type sysattr never exists for enumerated devices
As we filtered out network devices in the test.
Yu Watanabe [Mon, 12 Dec 2022 05:16:09 +0000 (14:16 +0900)]
sd-device: fix double-free
If an attribute is read but the value is not used (i.e. ret_value is NULL),
then sd_device_get_sysattr_value() mistakenly frees the read data even though
it is cached internally.
Fixes a bug introduced by
acfc2a1d15560084e077ffb3be472cd117e9020a.
Fixes #25702.
Hugo Carvalho [Sat, 10 Dec 2022 12:19:51 +0000 (13:19 +0100)]
po: Translated using Weblate (Portuguese)
Currently translated at 100.0% (193 of 193 strings)
Co-authored-by: Hugo Carvalho <hugokarvalho@hotmail.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/pt/
Translation: systemd/main
Lycowolf [Sun, 11 Dec 2022 11:16:52 +0000 (12:16 +0100)]
Add mount matrix for VisionBook 12Wr Tab
Peter Cai [Wed, 23 Nov 2022 13:43:22 +0000 (08:43 -0500)]
libfido2-util: Refactor pre-flight failure handling
`fido2_is_cred_in_specific_token()` should simply not return error codes
for non-fatal errors. For example, `-ENODEV` can be safely translated to
a `false` return value. When the pre-flight request is not supported, we
should simply return true to instruct the caller to attempt to use the
device anyway.
All error codes returned by the funtion should now be fatal and logged
at error level. Non-fatal errors should only appear in debug logs.
Peter Cai [Mon, 14 Nov 2022 02:58:43 +0000 (21:58 -0500)]
libfido2-util: Perform pre-flight checks as well when a specific device path is given
This prevents unnecessary user interactions when `fido2-device` is set to
something other than `auto` -- a case overlooked in the original PR #23577
(and later #25268).
We do not move pre-flight checks to `fido2_use_hmac_hash_specific_token`
because the behaviors are different between different cases: when the
device path is NULL, we try to automatically choose the correct device,
in which case pre-flight errors should be "soft" errors, without
spamming the tty with error outputs; but when a specific device path is
given, a pre-flight request that determined the non-existence of the
credential should be treated the same as a failed assertion request.
Peter Cai [Mon, 14 Nov 2022 02:12:45 +0000 (21:12 -0500)]
libfido2-util: Disable pre-flight checks for credentials with UV
According to the FIDO2 spec, tokens may not support pre-flight checks
for credentials requiring UV, at least not without at least
`pinUvAuthParam` or `uv = true`. Originally, in #25268, this was
handled by passing a PIN to satisfy `pinUvAuthParams`, but this is not
ideal, since `pinUvAuthParam` can be obtained from either a PIN
or a UV verification. Forcing the user to enter the PIN here (which is
often just the fallback option on UV devices) is no better than just
trying out each device with the actual assertion request.
As a result, this commit disables pre-flight checks when the credential
requires UV, and instead reverts to the old behavior (trying out each
device and each key slot, requiring multiple user interactions) for this
type of credentials.
Lennart Poettering [Fri, 9 Dec 2022 15:08:54 +0000 (16:08 +0100)]
repart: support erofs
So, i think "erofs" is probably the better, more modern alternative to
"squashfs". Many of the benefits don't matter too much to us I guess,
but there's one thing that stands out: erofs has a UUID in the
superblock, squashfs has not. Having an UUID in the superblock matters
if the file systems are used in an overlayfs stack, as overlayfs uses
the UUIDs to robustly and persistently reference inodes on layers in
case of metadata copy-up.
Since we probably want to allow such uses in overlayfs as emplyoed by
sysext (and the future syscfg) we probably should ramp up our erofs game
early on. Hence let's natively support erofs, test it, and in fact
mention it in the docs before squashfs even.
jcg [Fri, 9 Dec 2022 12:45:39 +0000 (20:45 +0800)]
mount-setup: don't need to mount /sys/fs/pstore if there is no ENABLE_PSTORE
Yu Watanabe [Sat, 10 Dec 2022 01:25:53 +0000 (10:25 +0900)]
resolve: add missing assertion
Yu Watanabe [Sat, 10 Dec 2022 01:25:38 +0000 (10:25 +0900)]
resolve: shorten code a bit
Yu Watanabe [Sat, 10 Dec 2022 01:21:41 +0000 (10:21 +0900)]
resolve: drop recursion in TXT field handling
Fixes #25683.
Daan De Meyer [Fri, 9 Dec 2022 11:10:09 +0000 (12:10 +0100)]
ci: Labeler improvements
- Mention "/please-review" in the contributing guide
- Remove "needs-rebase" on push
- Don't add "please-review" if a green label is set
- Don't add please-review label to draft PRs
- Add please-review when a PR moves out of draft
Zbigniew Jędrzejewski-Szmek [Fri, 9 Dec 2022 14:03:45 +0000 (15:03 +0100)]
Merge pull request #25636 from thom311/th/wcast-align-fixes
all: avoid various "-Wcast-align=strict" warnings
Thomas Haller [Thu, 1 Dec 2022 13:07:22 +0000 (14:07 +0100)]
all: avoid various "-Wcast-align=strict" warnings
Zbigniew Jędrzejewski-Szmek [Thu, 8 Dec 2022 20:22:32 +0000 (21:22 +0100)]
Merge pull request #25653 from yuwata/base64_append
hexdecoct: several fixes for base64_append()
Yu Watanabe [Thu, 8 Dec 2022 19:58:01 +0000 (04:58 +0900)]
Yu Watanabe [Wed, 7 Dec 2022 00:35:41 +0000 (09:35 +0900)]
resolve: optimize conversion of TXT fields to json
Fixes oss-fuzz#54080 (https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54080).
Fixes #25654.
Yu Watanabe [Wed, 7 Dec 2022 00:06:48 +0000 (09:06 +0900)]
hexdecoct: fix NULL pointer dereferences in hexmem()
Fixes oss-fuzz#54090 (https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54090).
Fixes #25655.
Yu Watanabe [Tue, 6 Dec 2022 21:58:23 +0000 (06:58 +0900)]
hexdecoct: add missing NULL check
Fixes oss-fuzz#54065 (https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=54065).
Fixes #25650.
Yu Watanabe [Tue, 6 Dec 2022 22:01:48 +0000 (07:01 +0900)]
test: add tests for base64_append()
Yu Watanabe [Tue, 6 Dec 2022 21:49:17 +0000 (06:49 +0900)]
hexdecoct: several cleanups for base64_append()
- add missing assertions,
- use size_t for buffser size or memory index,
- handle empty input more gracefully,
- return the length or the result string,
- fix off-by-one issue when the prefix is already long enough.
Edson Juliano Drosdeck [Thu, 8 Dec 2022 19:51:09 +0000 (16:51 -0300)]
hwdb: add Positivo-vaio Pro PW key toggle touchpad (#25669)
Daan De Meyer [Thu, 8 Dec 2022 15:25:03 +0000 (16:25 +0100)]
ci: Add/Drop labels on pull request activity and comment
When a pull request is opened/updated, add "please-review" and
remove a few other labels.
When a comment is made with /please-review on a PR. Add the
"please-review" label to the PR.
Lennart Poettering [Thu, 8 Dec 2022 16:48:34 +0000 (17:48 +0100)]
socket-util: add CMSG_TYPED_DATA() as type-safe wrapper around CMSG_DATA()
Thomas Haller [Mon, 5 Dec 2022 22:11:13 +0000 (23:11 +0100)]
fundamental: add CAST_ALIGN_PTR() macro
Lennart Poettering [Thu, 8 Dec 2022 16:24:52 +0000 (17:24 +0100)]
Merge pull request #25662 from msizanoen1/s2h-nosuspend-user-proc
sleep: always thaw user.slice even if freezing failed
Lennart Poettering [Thu, 8 Dec 2022 16:24:17 +0000 (17:24 +0100)]
Merge pull request #25667 from poettering/sha256-align-fix
sha256 alignment fixes/rework
Lennart Poettering [Thu, 8 Dec 2022 16:23:15 +0000 (17:23 +0100)]
Merge pull request #25665 from poettering/dissect-memory
dissect: add a mode for operating on an in-memory copy of a DDI, inst…
Yu Watanabe [Wed, 7 Dec 2022 00:51:30 +0000 (09:51 +0900)]
fs-util: make chmod_and_chown_at() work with empty path and AT_FDCWD
Follow-up for
7d000133c2fbf4b5986185ccfc0273a2428972a9.
Fixes CID#
1500608.
Lennart Poettering [Wed, 7 Dec 2022 17:19:29 +0000 (18:19 +0100)]
sha256: port to new generic IS_ALIGNED32() macro
This drops the special casing for s390 and other archs, which was
cargo-culted from glibc. Given it's not obvious why it exists, and is at
best an optimization let's simply avoid it, in particular as the archs
are relatively non-mainstream.
Inspired by: #25636
Lennart Poettering [Wed, 7 Dec 2022 17:31:27 +0000 (18:31 +0100)]
macro: add generic IS_ALIGNED32() anf friends
Let's generalize (and invert) the UNALIGNED32_P() macro from the sha256
code, and let's add a test for it.