mirror of
https://github.com/systemd/systemd
synced 2025-11-06 10:24:44 +01:00
Compare commits
7 Commits
81c7c6b62e
...
666cd35be4
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
666cd35be4 | ||
|
|
3a2c46dfbe | ||
|
|
f873ac8727 | ||
|
|
4fc9e19f7f | ||
|
|
185af6ebd3 | ||
|
|
5468cd269f | ||
|
|
f91fd8d5a1 |
@ -4468,6 +4468,12 @@ static void log_command_line(
|
|||||||
|
|
||||||
static bool exec_needs_cap_sys_admin(const ExecContext *context, const ExecParameters *params) {
|
static bool exec_needs_cap_sys_admin(const ExecContext *context, const ExecParameters *params) {
|
||||||
assert(context);
|
assert(context);
|
||||||
|
assert(params);
|
||||||
|
|
||||||
|
/* We only want to ever imply PrivateUsers= for user managers, as they're not expected to setuid() to
|
||||||
|
* other users, unlike the system manager which needs all users to be around. */
|
||||||
|
if (params->runtime_scope != RUNTIME_SCOPE_USER)
|
||||||
|
return false;
|
||||||
|
|
||||||
return context->private_users != PRIVATE_USERS_NO ||
|
return context->private_users != PRIVATE_USERS_NO ||
|
||||||
context->private_tmp != PRIVATE_TMP_NO ||
|
context->private_tmp != PRIVATE_TMP_NO ||
|
||||||
|
|||||||
@ -2639,12 +2639,10 @@ static int do_queue_default_job(
|
|||||||
return log_struct_errno(LOG_EMERG, r,
|
return log_struct_errno(LOG_EMERG, r,
|
||||||
LOG_MESSAGE("Failed to isolate default target: %s", bus_error_message(&error, r)),
|
LOG_MESSAGE("Failed to isolate default target: %s", bus_error_message(&error, r)),
|
||||||
LOG_MESSAGE_ID(SD_MESSAGE_CORE_ISOLATE_TARGET_FAILED_STR));
|
LOG_MESSAGE_ID(SD_MESSAGE_CORE_ISOLATE_TARGET_FAILED_STR));
|
||||||
} else
|
}
|
||||||
log_info("Queued %s job for default target %s.",
|
|
||||||
job_type_to_string(job->type),
|
|
||||||
unit_status_string(job->unit, NULL));
|
|
||||||
|
|
||||||
m->default_unit_job_id = job->id;
|
log_info("Queued %s job for default target %s.",
|
||||||
|
job_type_to_string(job->type), unit_status_string(job->unit, NULL));
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -173,7 +173,7 @@ typedef struct Manager {
|
|||||||
LIST_HEAD(Unit, load_queue); /* this is actually more a stack than a queue, but uh. */
|
LIST_HEAD(Unit, load_queue); /* this is actually more a stack than a queue, but uh. */
|
||||||
|
|
||||||
/* Jobs that need to be run */
|
/* Jobs that need to be run */
|
||||||
struct Prioq *run_queue;
|
Prioq *run_queue;
|
||||||
|
|
||||||
/* Units and jobs that have not yet been announced via
|
/* Units and jobs that have not yet been announced via
|
||||||
* D-Bus. When something about a job changes it is added here
|
* D-Bus. When something about a job changes it is added here
|
||||||
@ -321,18 +321,15 @@ typedef struct Manager {
|
|||||||
|
|
||||||
Hashmap *watch_bus; /* D-Bus names => Unit object n:1 */
|
Hashmap *watch_bus; /* D-Bus names => Unit object n:1 */
|
||||||
|
|
||||||
bool send_reloading_done;
|
|
||||||
|
|
||||||
uint32_t current_job_id;
|
uint32_t current_job_id;
|
||||||
uint32_t default_unit_job_id;
|
|
||||||
|
|
||||||
/* Data specific to the Automount subsystem */
|
/* Data specific to the Automount subsystem */
|
||||||
int dev_autofs_fd;
|
int dev_autofs_fd;
|
||||||
|
|
||||||
/* Data specific to the cgroup subsystem */
|
/* Data specific to the cgroup subsystem */
|
||||||
Hashmap *cgroup_unit;
|
Hashmap *cgroup_unit;
|
||||||
CGroupMask cgroup_supported;
|
|
||||||
char *cgroup_root;
|
char *cgroup_root;
|
||||||
|
CGroupMask cgroup_supported;
|
||||||
|
|
||||||
/* Notifications from cgroups, when the unified hierarchy is used is done via inotify. */
|
/* Notifications from cgroups, when the unified hierarchy is used is done via inotify. */
|
||||||
int cgroup_inotify_fd;
|
int cgroup_inotify_fd;
|
||||||
@ -365,6 +362,8 @@ typedef struct Manager {
|
|||||||
bool dispatching_load_queue;
|
bool dispatching_load_queue;
|
||||||
int may_dispatch_stop_notify_queue; /* tristate */
|
int may_dispatch_stop_notify_queue; /* tristate */
|
||||||
|
|
||||||
|
bool send_reloading_done;
|
||||||
|
|
||||||
/* Have we already sent out the READY=1 notification? */
|
/* Have we already sent out the READY=1 notification? */
|
||||||
bool ready_sent;
|
bool ready_sent;
|
||||||
|
|
||||||
|
|||||||
@ -529,7 +529,7 @@ static int archive_entry_read_acl(
|
|||||||
|
|
||||||
r = acl_set_perm(p, ACL_EXECUTE, permset & ARCHIVE_ENTRY_ACL_EXECUTE);
|
r = acl_set_perm(p, ACL_EXECUTE, permset & ARCHIVE_ENTRY_ACL_EXECUTE);
|
||||||
if (r < 0)
|
if (r < 0)
|
||||||
return log_error_errno(r, "Failed to set ACL entry excute bit: %m");
|
return log_error_errno(r, "Failed to set ACL entry execute bit: %m");
|
||||||
|
|
||||||
if (sym_acl_set_permset(e, p) < 0)
|
if (sym_acl_set_permset(e, p) < 0)
|
||||||
return log_error_errno(errno, "Failed to set ACL entry permission set: %m");
|
return log_error_errno(errno, "Failed to set ACL entry permission set: %m");
|
||||||
|
|||||||
@ -467,7 +467,7 @@ static int setup_nvpcr(void) {
|
|||||||
|
|
||||||
if (c.n_already > 0 && c.n_anchored == 0 && !arg_early) {
|
if (c.n_already > 0 && c.n_anchored == 0 && !arg_early) {
|
||||||
/* If we didn't anchor anything right now, but we anchored something earlier, then it might
|
/* If we didn't anchor anything right now, but we anchored something earlier, then it might
|
||||||
* have happened in the initrd, and thus the anchor ID was not commited to /var/ or the ESP
|
* have happened in the initrd, and thus the anchor ID was not committed to /var/ or the ESP
|
||||||
* yet. Hence, let's explicitly do so now, to catch up. */
|
* yet. Hence, let's explicitly do so now, to catch up. */
|
||||||
|
|
||||||
r = tpm2_nvpcr_acquire_anchor_secret(/* ret= */ NULL, /* sync_secondary= */ true);
|
r = tpm2_nvpcr_acquire_anchor_secret(/* ret= */ NULL, /* sync_secondary= */ true);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user