]> git.saurik.com Git - apple/xnu.git/blob - osfmk/man/host_security_create_task_token.html
xnu-792.21.3.tar.gz
[apple/xnu.git] / osfmk / man / host_security_create_task_token.html
1 <h2>host_security_create_task_token</h2>
2 <hr>
3 <p>
4 <strong>Function</strong> - Create a new task with an explicit security token.
5 <h3>SYNOPSIS</h3>
6 <pre>
7 <strong>kern_return_t host_security_create_task_token</strong>
8 <strong>(host_security_t</strong> <var>host_security</var>,
9 <strong>task_t</strong> <var>parent_task</var>,
10 <strong>security_token_t</strong> <var>security_token</var>,
11 <strong>audit_token_t</strong> <var>audit_token</var>,
12 <strong>ledger_port_array_t</strong> <var>ledgers</var>,
13 <strong>boolean_t</strong> <var>inherit_memory</var>,
14 <strong>task_t</strong> <var>child_task</var><strong>);</strong>
15 </pre>
16 <h3>PARAMETERS</h3>
17 <dl>
18 <p>
19 <dt><var>host_security</var>
20 <dd>
21 [in security send right] The host's security port.
22 <p>
23 <dt><var>parent_task</var>
24 <dd>
25 [in task send right] The port for the task from which to draw the child
26 task's port rights and address space.
27 <p>
28 <dt><var>security_token</var>
29 <dd>
30 [in scalar] The task's security token.
31 <p>
32 <dt><var>audit_token</var>
33 <dd>
34 [in scalar] The task's audit token.
35 <p>
36 <dt><var>ledgers</var>
37 <dd>
38 [pointer to in array of ledger send rights] The set of ledgers from which the
39 task will draw its resources.
40 <p>
41 <dt><var>inherit_memory</var>
42 <dd>
43 [in scalar] Address space inheritance indicator. If true, the child task in-
44 herits the address space of the parent task. If false, the kernel assigns
45 the child task an empty address space.
46 <p>
47 <dt><var>child_task</var>
48 <dd>
49 [out task send right] The kernel-assigned port name for the new task.
50 </dl>
51 <h3>DESCRIPTION</h3>
52 <p>
53 The <strong><strong>host_security_create_task_token</strong> function creates a new task from
54 <var>parent_task</var> with explicit security and audit token values, returning the name of the
55 new task in the parameter specified by <var>child_task</var>. Other than the security and audit token values, the child task
56 is as if created by <strong>task_create</strong>.
57 <h3>NOTES</h3>
58 <p>
59 The host security port is a privileged port given to the system
60 bootstrap task for the use of this call.
61 <h3>RETURN VALUES</h3>
62 <dl>
63 <p>
64 <dt> <strong>KERN_INVALID_SECURITY</strong>
65 <dd>
66 The value of <var>host_security</var> does not specify the security port for the host on which task lies.
67 </dl>
68 <h3>RELATED INFORMATION</h3>
69 <p>
70 Functions:
71 <a href="task_create.html"><strong>task_create</strong></a>,
72 <a href="host_security_set_task_token.html"><strong>host_security_set_task_token</strong></a>,
73 <a href="mach_msg.html"><strong>mach_msg</strong></a>.