1
0
mirror of https://github.com/systemd/systemd synced 2024-07-09 04:26:06 +00:00
Commit Graph

24 Commits

Author SHA1 Message Date
Adrian Vovk
d94c7eef12 homework: Implement offline updates
This makes it possible to update a home record (and blob directory) of a
home area that's either completely absent (i.e. on a USB stick that's
unplugged) or just inaccessible due to lack of authentication
2024-03-23 01:05:13 +00:00
Adrian Vovk
5ec87d577f homework: Accept volume key from keyring
This bypasses authentication (i.e. user_record_authenticate) if the
volume key was loaded from the keyring and no secret section is
provided.

This also changes Update() and Resize() to always try and load the
volume key from the keyring. This makes the secret section optional for
these methods while still letting them function (as long as the home
area is active)
2024-03-23 01:05:13 +00:00
Adrian Vovk
1f8aa8456e
homed: Minor man page improvements 2024-03-18 15:31:18 -04:00
Adrian Vovk
5d490208a8
Revert "homed: Add InhibitSuspend() method"
I'm moving this functionality into logind instead.

This reverts commit 691b99160d.
2024-03-18 15:31:16 -04:00
Adrian Vovk
a4d72746c7 homework: Handle Update & Create w/ blob dir
Introduces new extended variants of the various incarnations of
Create and Update, which take a map of filenames to FDs. This map is
then used to populate the bulk directory.

FDs are used to prevent the client from abusing homed's blob directory
permissions (everything is made world-readable by homed) to open files
that they normally aren't allowed to open. Passing along an FD ensures
that the client has read access to the file it wants homed to make
world-readable.

Internally, homework uses the map to overwrite the system blob dir.
Later, homework's existing blob dir reconciliation logic will propagate
the new contents from the system blob dir into the embedded blob
dir
2024-02-19 11:18:11 +00:00
Lennart Poettering
955502121d man: update D-Bus docs with new calls 2024-02-14 15:08:03 +01:00
Adrian Vovk
691b99160d homed: Add InhibitSuspend() method
This returns an FD that can be used to temporarily inhibit the automatic
locking on system suspend behavior of homed. As long as the FD is open,
LockAllHomes() won't lock that home directory on suspend. This allows
desktop environments to implement custom more complicated behavior
2024-01-31 09:48:23 +01:00
David Tardon
eea10b26f7 man: use same version in public and system ident. 2023-12-25 15:51:47 +01:00
David Tardon
13a69c120b man: use <simplelist> for 'See also' sections
This is just a slight markup improvement; there should be no difference
in rendering.
2023-12-23 08:28:57 +01:00
Lennart Poettering
7480859a11 man,doc: document some aspects of user record management/homed a bit better
Fixes: #29759
2023-11-08 12:40:08 +01:00
Zbigniew Jędrzejewski-Szmek
e4239a34d7 man: deduplicate dbus versioning ref 2022-05-05 11:48:22 +02:00
Yu Watanabe
34b5684846 man: also add anotations for methods
Fixes #21882.
2021-12-24 10:18:11 +00:00
Lennart Poettering
4950591627 homed: add explicit API for requesting rebalancing too 2021-11-25 18:28:44 +01:00
Yu Watanabe
db9ecf0501 license: LGPL-2.1+ -> LGPL-2.1-or-later 2020-11-09 13:23:58 +09:00
Lennart Poettering
d1f6e01e47 homed: explicitly deactivate all home directories on shutdown
Let's explicitly deactivate all home dirs on shutdown, in order to
properly synchronizing unmounting and avoiding blocking devices.

Previously, we'd rely on automatic deactivation when home directories
become unused. However, that scheme is asynchronous, and ongoing
deactviations might conflicts with attempts to unmount /home. Let's fix
that by providing an explicit service systemd-homed-activate.service
whose only job is to have a ExecStop= line that explicitly deactivates
all home directories on shutdown. This service can the be ordered after
home.mount and similar, ensuring that we'll first deactivate all homes
before deactivating /home itself during shutdown.

This is kept separate from systemd-homed.service so that it is possible
to restart systemd-homed.service without deactivating all home
directories.

Fixes: #16842
2020-09-30 14:37:52 +02:00
Zbigniew Jędrzejewski-Szmek
d3fcecf3c9 man: import lxml formatting changes
lxml insists on this, see 4fb222c4b2.
2020-08-22 12:28:49 +02:00
Zbigniew Jędrzejewski-Szmek
60e3a5a252
Merge pull request #16390 from keszybz/coverity-and-typos
One coverity-inspired fix and spelling
2020-07-07 19:40:10 +02:00
Topi Miettinen
f4e1a42592 man: match parentheses
Files found with:
for f in *; do \
    l=`tr -d '[^(]' < $f | wc -c`; \
    r=`tr -d '[^)]' < $f | wc -c`; \
    if [ $l -ne $r ]; then \
       echo $f $l $r; \
    fi; \
done
2020-07-07 13:31:39 +02:00
Zbigniew Jędrzejewski-Szmek
cd990847b9 tree-wide: more repeated words 2020-07-07 12:08:22 +02:00
Zbigniew Jędrzejewski-Szmek
b7a4734551 man: fix links to various external man pages
In cases where we used both die-net and man-pages for the same reference,
I switched to use man-pages everywhere.
2020-06-25 14:41:44 +02:00
Zbigniew Jędrzejewski-Szmek
201632e314 tree-wide: s/time-out/timeout/g
See 3f9a0a522f for justification.
2020-05-26 10:28:59 +02:00
Lennart Poettering
2dffb32309 man: document homed D-Bus API 2020-05-12 11:07:01 +02:00
Lennart Poettering
55842c7326 homed: fix parameter names on D-Bus methods
These arguments contain UserRecord structures serialized to JSON,
however only the "secret" part of it, not a whole user record. We do
this since the secret part is conceptually part of the user record and
in some contexts we need a user record in full with both secret and
non-secret part, and in others just the secret and in other just the
non-secret part, but we want to keep this in memory in the same logic.

Hence, let's rename the arguments where we expect a user record
consisting only of the secret part to "secret".
2020-05-12 11:06:46 +02:00
Zbigniew Jędrzejewski-Szmek
b856b346c1 man: add stub for home1(5) 2020-05-06 09:13:42 +02:00