task_for_context

Function task_for_context 

Source
pub fn task_for_context(
    task: &Task,
    context: &FsStr,
) -> Result<TaskState, Errno>
Expand description

Returns TaskState for a new Task, based on that of the provided context. The effect is similar to combining the task_alloc() and setprocattr() LSM hooks, with the difference that no access-checks are performed, and the “#” syntax may be used to have the Task assigned one of the “initial” Security Contexts, to allow components to be run prior to a policy being loaded.