Lines Matching refs:prefix

1953                 if (!p->prefix[t])  in build_environment()
1966 prefixed = path_join(p->prefix[t], c->directories[t].items[i].path); in build_environment()
1981 if (exec_context_has_credentials(c) && p->prefix[EXEC_DIRECTORY_RUNTIME]) { in build_environment()
1982 … x = strjoin("CREDENTIALS_DIRECTORY=", p->prefix[EXEC_DIRECTORY_RUNTIME], "/credentials/", u->id); in build_environment()
2087 if (params && !params->prefix[t]) in exec_needs_mount_namespace()
2331 if (!params->prefix[type]) in setup_exec_directory()
2344 p = path_join(params->prefix[type], context->directories[type].items[i].path); in setup_exec_directory()
2380 pp = path_join(params->prefix[type], "private"); in setup_exec_directory()
2449 … q = path_join(params->prefix[type], "private", context->directories[type].items[i].path); in setup_exec_directory()
2529 r = create_many_symlinks(params->prefix[type], in setup_exec_directory()
3141 if (!params->prefix[EXEC_DIRECTORY_RUNTIME]) in setup_credentials()
3146 q = path_join(params->prefix[EXEC_DIRECTORY_RUNTIME], "credentials"); in setup_credentials()
3172 … t = path_join(params->prefix[EXEC_DIRECTORY_RUNTIME], "systemd/temporary-credentials"); in setup_credentials()
3300 if (!params->prefix[t]) in compile_bind_mounts()
3344 if (!params->prefix[t]) in compile_bind_mounts()
3358 private_root = path_join(params->prefix[t], "private"); in compile_bind_mounts()
3373 … s = path_join(params->prefix[t], "private", context->directories[t].items[i].path); in compile_bind_mounts()
3375 … s = path_join(params->prefix[t], context->directories[t].items[i].path); in compile_bind_mounts()
3386 … d = path_join(params->prefix[t], context->directories[t].items[i].path); in compile_bind_mounts()
3441 … src_abs = path_join(params->prefix[dt], context->directories[dt].items[i].path); in compile_symlinks()
3442 dst_abs = path_join(params->prefix[dt], *symlink); in compile_symlinks()
3454 … private_path = path_join(params->prefix[dt], "private", context->directories[dt].items[i].path); in compile_symlinks()
3458 … path = path_join(params->prefix[dt], context->directories[dt].items[i].path); in compile_symlinks()
3604 params->prefix[EXEC_DIRECTORY_RUNTIME] && in apply_mount_namespace()
3606 … creds_path = path_join(params->prefix[EXEC_DIRECTORY_RUNTIME], "credentials", u->id); in apply_mount_namespace()
3984 if (!p->prefix[t]) in compile_suggested_paths()
3991 … e = path_join(p->prefix[t], "private", c->directories[t].items[i].path); in compile_suggested_paths()
3993 e = path_join(p->prefix[t], c->directories[t].items[i].path); in compile_suggested_paths()
4525 …error_errno(unit, r, "Failed to set up special execution directory in %s: %m", params->prefix[dt]); in exec_child()
5715 static void strv_dump(FILE* f, const char *prefix, const char *name, char **strv) { in strv_dump() argument
5717 assert(prefix); in strv_dump()
5721 fprintf(f, "%s%s:", prefix, name); in strv_dump()
5727 void exec_context_dump(const ExecContext *c, FILE* f, const char *prefix) { in exec_context_dump() argument
5733 prefix = strempty(prefix); in exec_context_dump()
5760 prefix, c->umask, in exec_context_dump()
5761 prefix, empty_to_root(c->working_directory), in exec_context_dump()
5762 prefix, empty_to_root(c->root_directory), in exec_context_dump()
5763 prefix, yes_no(c->non_blocking), in exec_context_dump()
5764 prefix, yes_no(c->private_tmp), in exec_context_dump()
5765 prefix, yes_no(c->private_devices), in exec_context_dump()
5766 prefix, yes_no(c->protect_kernel_tunables), in exec_context_dump()
5767 prefix, yes_no(c->protect_kernel_modules), in exec_context_dump()
5768 prefix, yes_no(c->protect_kernel_logs), in exec_context_dump()
5769 prefix, yes_no(c->protect_clock), in exec_context_dump()
5770 prefix, yes_no(c->protect_control_groups), in exec_context_dump()
5771 prefix, yes_no(c->private_network), in exec_context_dump()
5772 prefix, yes_no(c->private_users), in exec_context_dump()
5773 prefix, protect_home_to_string(c->protect_home), in exec_context_dump()
5774 prefix, protect_system_to_string(c->protect_system), in exec_context_dump()
5775 prefix, yes_no(exec_context_get_effective_mount_apivfs(c)), in exec_context_dump()
5776 prefix, yes_no(c->ignore_sigpipe), in exec_context_dump()
5777 prefix, yes_no(c->memory_deny_write_execute), in exec_context_dump()
5778 prefix, yes_no(c->restrict_realtime), in exec_context_dump()
5779 prefix, yes_no(c->restrict_suid_sgid), in exec_context_dump()
5780 prefix, exec_keyring_mode_to_string(c->keyring_mode), in exec_context_dump()
5781 prefix, yes_no(c->protect_hostname), in exec_context_dump()
5782 prefix, protect_proc_to_string(c->protect_proc), in exec_context_dump()
5783 prefix, proc_subset_to_string(c->proc_subset)); in exec_context_dump()
5786 fprintf(f, "%sRootImage: %s\n", prefix, c->root_image); in exec_context_dump()
5789 fprintf(f, "%sRootImageOptions:", prefix); in exec_context_dump()
5802 fprintf(f, "%sRootHash: %s\n", prefix, encoded); in exec_context_dump()
5806 fprintf(f, "%sRootHash: %s\n", prefix, c->root_hash_path); in exec_context_dump()
5813 fprintf(f, "%sRootHashSignature: base64:%s\n", prefix, encoded); in exec_context_dump()
5817 fprintf(f, "%sRootHashSignature: %s\n", prefix, c->root_hash_sig_path); in exec_context_dump()
5820 fprintf(f, "%sRootVerity: %s\n", prefix, c->root_verity); in exec_context_dump()
5823 fprintf(f, "%sEnvironment: %s\n", prefix, *e); in exec_context_dump()
5826 fprintf(f, "%sEnvironmentFile: %s\n", prefix, *e); in exec_context_dump()
5829 fprintf(f, "%sPassEnvironment: %s\n", prefix, *e); in exec_context_dump()
5832 fprintf(f, "%sUnsetEnvironment: %s\n", prefix, *e); in exec_context_dump()
5834 …fprintf(f, "%sRuntimeDirectoryPreserve: %s\n", prefix, exec_preserve_mode_to_string(c->runtime_dir… in exec_context_dump()
5837 …fprintf(f, "%s%sMode: %04o\n", prefix, exec_directory_type_to_string(dt), c->directories[dt].mode); in exec_context_dump()
5840 …fprintf(f, "%s%s: %s\n", prefix, exec_directory_type_to_string(dt), c->directories[dt].items[i].pa… in exec_context_dump()
5843 …fprintf(f, "%s%s: %s:%s\n", prefix, exec_directory_type_symlink_to_string(dt), c->directories[dt].… in exec_context_dump()
5847 …fprintf(f, "%sTimeoutCleanSec: %s\n", prefix, FORMAT_TIMESPAN(c->timeout_clean_usec, USEC_PER_SEC)… in exec_context_dump()
5850 fprintf(f, "%sNice: %i\n", prefix, c->nice); in exec_context_dump()
5853 fprintf(f, "%sOOMScoreAdjust: %i\n", prefix, c->oom_score_adjust); in exec_context_dump()
5856 fprintf(f, "%sCoredumpFilter: 0x%"PRIx64"\n", prefix, c->coredump_filter); in exec_context_dump()
5861 prefix, rlimit_to_string(i), c->rlimit[i]->rlim_max); in exec_context_dump()
5863 prefix, rlimit_to_string(i), c->rlimit[i]->rlim_cur); in exec_context_dump()
5871 fprintf(f, "%sIOSchedulingClass: %s\n", prefix, class_str); in exec_context_dump()
5873 fprintf(f, "%sIOPriority: %d\n", prefix, ioprio_prio_data(c->ioprio)); in exec_context_dump()
5881 fprintf(f, "%sCPUSchedulingPolicy: %s\n", prefix, policy_str); in exec_context_dump()
5886 prefix, c->cpu_sched_priority, in exec_context_dump()
5887 prefix, yes_no(c->cpu_sched_reset_on_fork)); in exec_context_dump()
5894 fprintf(f, "%sCPUAffinity: %s\n", prefix, affinity); in exec_context_dump()
5901 … fprintf(f, "%sNUMAPolicy: %s\n", prefix, mpol_to_string(numa_policy_get_type(&c->numa_policy))); in exec_context_dump()
5902 fprintf(f, "%sNUMAMask: %s\n", prefix, strnull(nodes)); in exec_context_dump()
5906 fprintf(f, "%sTimerSlackNSec: "NSEC_FMT "\n", prefix, c->timer_slack_nsec); in exec_context_dump()
5912 prefix, exec_input_to_string(c->std_input), in exec_context_dump()
5913 prefix, exec_output_to_string(c->std_output), in exec_context_dump()
5914 prefix, exec_output_to_string(c->std_error)); in exec_context_dump()
5917 … fprintf(f, "%sStandardInputFileDescriptorName: %s\n", prefix, c->stdio_fdname[STDIN_FILENO]); in exec_context_dump()
5919 … fprintf(f, "%sStandardOutputFileDescriptorName: %s\n", prefix, c->stdio_fdname[STDOUT_FILENO]); in exec_context_dump()
5921 … fprintf(f, "%sStandardErrorFileDescriptorName: %s\n", prefix, c->stdio_fdname[STDERR_FILENO]); in exec_context_dump()
5924 fprintf(f, "%sStandardInputFile: %s\n", prefix, c->stdio_file[STDIN_FILENO]); in exec_context_dump()
5926 fprintf(f, "%sStandardOutputFile: %s\n", prefix, c->stdio_file[STDOUT_FILENO]); in exec_context_dump()
5928 … fprintf(f, "%sStandardOutputFileToAppend: %s\n", prefix, c->stdio_file[STDOUT_FILENO]); in exec_context_dump()
5930 … fprintf(f, "%sStandardOutputFileToTruncate: %s\n", prefix, c->stdio_file[STDOUT_FILENO]); in exec_context_dump()
5932 fprintf(f, "%sStandardErrorFile: %s\n", prefix, c->stdio_file[STDERR_FILENO]); in exec_context_dump()
5934 … fprintf(f, "%sStandardErrorFileToAppend: %s\n", prefix, c->stdio_file[STDERR_FILENO]); in exec_context_dump()
5936 … fprintf(f, "%sStandardErrorFileToTruncate: %s\n", prefix, c->stdio_file[STDERR_FILENO]); in exec_context_dump()
5946 prefix, c->tty_path, in exec_context_dump()
5947 prefix, yes_no(c->tty_reset), in exec_context_dump()
5948 prefix, yes_no(c->tty_vhangup), in exec_context_dump()
5949 prefix, yes_no(c->tty_vt_disallocate), in exec_context_dump()
5950 prefix, c->tty_rows, in exec_context_dump()
5951 prefix, c->tty_cols); in exec_context_dump()
5968 fprintf(f, "%sSyslogFacility: %s\n", prefix, fac_str); in exec_context_dump()
5972 fprintf(f, "%sSyslogLevel: %s\n", prefix, lvl_str); in exec_context_dump()
5980 fprintf(f, "%sLogLevelMax: %s\n", prefix, strna(t)); in exec_context_dump()
5986 prefix, FORMAT_TIMESPAN(c->log_ratelimit_interval_usec, USEC_PER_SEC)); in exec_context_dump()
5989 fprintf(f, "%sLogRateLimitBurst: %u\n", prefix, c->log_ratelimit_burst); in exec_context_dump()
5992 fprintf(f, "%sLogExtraFields: ", prefix); in exec_context_dump()
6000 fprintf(f, "%sLogNamespace: %s\n", prefix, c->log_namespace); in exec_context_dump()
6007 fprintf(f, "%sSecure Bits: %s\n", prefix, str); in exec_context_dump()
6015 fprintf(f, "%sCapabilityBoundingSet: %s\n", prefix, str); in exec_context_dump()
6023 fprintf(f, "%sAmbientCapabilities: %s\n", prefix, str); in exec_context_dump()
6027 fprintf(f, "%sUser: %s\n", prefix, c->user); in exec_context_dump()
6029 fprintf(f, "%sGroup: %s\n", prefix, c->group); in exec_context_dump()
6031 fprintf(f, "%sDynamicUser: %s\n", prefix, yes_no(c->dynamic_user)); in exec_context_dump()
6033 strv_dump(f, prefix, "SupplementaryGroups", c->supplementary_groups); in exec_context_dump()
6036 fprintf(f, "%sPAMName: %s\n", prefix, c->pam_name); in exec_context_dump()
6038 strv_dump(f, prefix, "ReadWritePaths", c->read_write_paths); in exec_context_dump()
6039 strv_dump(f, prefix, "ReadOnlyPaths", c->read_only_paths); in exec_context_dump()
6040 strv_dump(f, prefix, "InaccessiblePaths", c->inaccessible_paths); in exec_context_dump()
6041 strv_dump(f, prefix, "ExecPaths", c->exec_paths); in exec_context_dump()
6042 strv_dump(f, prefix, "NoExecPaths", c->no_exec_paths); in exec_context_dump()
6043 strv_dump(f, prefix, "ExecSearchPath", c->exec_search_path); in exec_context_dump()
6046 fprintf(f, "%s%s: %s%s:%s:%s\n", prefix, in exec_context_dump()
6056 fprintf(f, "%sTemporaryFileSystem: %s%s%s\n", prefix, in exec_context_dump()
6065 prefix, c->utmp_id); in exec_context_dump()
6070 prefix, c->selinux_context_ignore ? "-" : "", c->selinux_context); in exec_context_dump()
6075 prefix, c->apparmor_profile_ignore ? "-" : "", c->apparmor_profile); in exec_context_dump()
6080 prefix, c->smack_process_label_ignore ? "-" : "", c->smack_process_label); in exec_context_dump()
6085 prefix, strna(personality_to_string(c->personality))); in exec_context_dump()
6089 prefix, yes_no(c->lock_personality)); in exec_context_dump()
6094 prefix); in exec_context_dump()
6131 prefix); in exec_context_dump()
6147 prefix, strna(s)); in exec_context_dump()
6154 fprintf(f, "%sRestrictFileSystems: %s\n", prefix, fs); in exec_context_dump()
6161 prefix, c->network_namespace_path); in exec_context_dump()
6164 fprintf(f, "%sSystemCallErrorNumber: ", prefix); in exec_context_dump()
6177 fprintf(f, "%sMountImages: %s%s:%s", prefix, in exec_context_dump()
6189 fprintf(f, "%sExtensionImages: %s%s", prefix, in exec_context_dump()
6199 strv_dump(f, prefix, "ExtensionDirectories", c->extension_directories); in exec_context_dump()
6300 char **prefix, in exec_context_get_clean_directories() argument
6308 assert(prefix); in exec_context_get_clean_directories()
6315 if (!prefix[t]) in exec_context_get_clean_directories()
6321 j = path_join(prefix[t], c->directories[t].items[i].path); in exec_context_get_clean_directories()
6331 … j = path_join(prefix[t], "private", c->directories[t].items[i].path); in exec_context_get_clean_directories()
6341 j = path_join(prefix[t], *symlink); in exec_context_get_clean_directories()
6403 void exec_status_dump(const ExecStatus *s, FILE *f, const char *prefix) { in exec_status_dump() argument
6410 prefix = strempty(prefix); in exec_status_dump()
6414 prefix, s->pid); in exec_status_dump()
6419 prefix, FORMAT_TIMESTAMP(s->start_timestamp.realtime)); in exec_status_dump()
6426 prefix, FORMAT_TIMESTAMP(s->exit_timestamp.realtime), in exec_status_dump()
6427 prefix, sigchld_code_to_string(s->code), in exec_status_dump()
6428 prefix, s->status); in exec_status_dump()
6431 static void exec_command_dump(ExecCommand *c, FILE *f, const char *prefix) { in exec_command_dump() argument
6438 prefix = strempty(prefix); in exec_command_dump()
6439 prefix2 = strjoina(prefix, "\t"); in exec_command_dump()
6444 prefix, cmd ?: strerror_safe(ENOMEM)); in exec_command_dump()
6449 void exec_command_dump_list(ExecCommand *c, FILE *f, const char *prefix) { in exec_command_dump_list() argument
6452 prefix = strempty(prefix); in exec_command_dump_list()
6455 exec_command_dump(i, f, prefix); in exec_command_dump_list()