]> git.saurik.com Git - apple/xnu.git/blob - osfmk/man/host_security_set_task_token.html
xnu-517.tar.gz
[apple/xnu.git] / osfmk / man / host_security_set_task_token.html
1 <h2>host_security_set_task_token</h2> <hr> <p> <strong>Function</strong> - Change the target task's security token. <h3>SYNOPSIS</h3> <pre> <strong>kern_return_t host_security_set_task_token</strong> <strong>(host_security_t</strong> <var>host_security</var>, <strong>task_t</strong> <var>task</var>, <strong>security_token_t</strong> <var>security_token</var>, <strong>audit_token_t</strong> <var>audit_token</var>, <strong>host_t</strong> <var>host</var><strong>);</strong> </pre> <h3>PARAMETERS</h3> <dl> <p> <dt><var>host_security</var> <dd> [in security send right] The host's security port. <p> <dt><var>task</var> <dd> [in task send right] The port for the task for which the token is to be set. <p> <dt><var>security_token</var> <dd> [in scalar] The new security token. <p> <dt><var>audit_token</var> <dd> [in scalar] The new audit token. <p> <dt><var>host</var> <dd> [in host send right] The task's new host-self port. </dl> <h3>DESCRIPTION</h3> <p> The <strong>host_security_set_task_token</strong> function changes the specified task's security and audit tokens; the new tokens will be included in all subsequent messages sent from the task. The initial value of a task's security and audit tokens is that of its parent. <h3>NOTES</h3> <p> The host security port is a privileged port given to the system bootstrap task for the use of this call. <h3>RETURN VALUES</h3> <dl> <p> <dt> <strong>KERN_INVALID_SECURITY</strong> <dd> The value of <var>host_security</var> does not specify the security port for the host on which task lies. </dl> <h3>RELATED INFORMATION</h3> <p> Functions: <a href="task_create.html"><strong>task_create</strong></a>, <a href="task_info.html"><strong>task_info</strong></a>, <a href="mach_msg.html"><strong>mach_msg</strong></a>.