]>
Commit | Line | Data |
---|---|---|
d8f41ccd | 1 | /* Copyright (c) 2012-2013 Apple Inc. All Rights Reserved. */ |
427c49bc A |
2 | |
3 | #ifndef _SECURITY_AUTH_PROCESS_H_ | |
4 | #define _SECURITY_AUTH_PROCESS_H_ | |
5 | ||
6 | #include <CoreFoundation/CoreFoundation.h> | |
7 | #include <Security/SecCode.h> | |
8 | #include <mach/mach.h> | |
9 | ||
10 | #if defined(__cplusplus) | |
11 | extern "C" { | |
12 | #endif | |
13 | ||
14 | AUTH_WARN_RESULT AUTH_MALLOC AUTH_NONNULL_ALL AUTH_RETURNS_RETAINED | |
15 | process_t process_create(const audit_info_s*,session_t); | |
16 | ||
17 | AUTH_NONNULL_ALL | |
18 | const void * process_get_key(process_t); | |
19 | ||
20 | AUTH_NONNULL_ALL | |
21 | uid_t process_get_uid(process_t); | |
22 | ||
23 | AUTH_NONNULL_ALL | |
24 | pid_t process_get_pid(process_t); | |
25 | ||
26 | AUTH_NONNULL_ALL | |
27 | int32_t process_get_generation(process_t); | |
28 | ||
29 | AUTH_NONNULL_ALL | |
30 | session_id_t process_get_session_id(process_t); | |
31 | ||
32 | AUTH_NONNULL_ALL | |
33 | session_t process_get_session(process_t); | |
34 | ||
35 | AUTH_NONNULL_ALL | |
36 | uint32_t process_get_count(process_t); | |
37 | ||
38 | AUTH_NONNULL_ALL | |
39 | const audit_info_s * process_get_audit_info(process_t); | |
40 | ||
41 | AUTH_NONNULL_ALL | |
42 | SecCodeRef process_get_code(process_t); | |
43 | ||
44 | AUTH_NONNULL_ALL | |
45 | const char * process_get_code_url(process_t); | |
46 | ||
47 | AUTH_NONNULL_ALL | |
48 | CFIndex process_add_connection(process_t, connection_t); | |
49 | ||
50 | AUTH_NONNULL_ALL | |
51 | CFIndex process_remove_connection(process_t, connection_t); | |
52 | ||
53 | AUTH_NONNULL_ALL | |
54 | CFIndex process_get_connection_count(process_t); | |
55 | ||
56 | AUTH_NONNULL_ALL | |
57 | void process_add_auth_token(process_t,auth_token_t); | |
58 | ||
59 | AUTH_NONNULL_ALL | |
60 | void process_remove_auth_token(process_t,auth_token_t, uint32_t flags); | |
61 | ||
62 | AUTH_NONNULL_ALL | |
63 | auth_token_t process_find_copy_auth_token(process_t,const AuthorizationBlob*); | |
64 | ||
65 | AUTH_NONNULL_ALL | |
66 | CFIndex process_get_auth_token_count(process_t); | |
67 | ||
68 | AUTH_NONNULL_ALL | |
69 | CFTypeRef process_copy_entitlement_value(process_t, const char * entitlement); | |
70 | ||
71 | AUTH_NONNULL_ALL | |
72 | bool process_has_entitlement(process_t, const char * entitlement); | |
73 | ||
74 | AUTH_NONNULL_ALL | |
75 | bool process_has_entitlement_for_right(process_t, const char * right); | |
76 | ||
77 | AUTH_NONNULL_ALL | |
78 | const char * process_get_identifier(process_t); | |
79 | ||
80 | AUTH_NONNULL_ALL | |
81 | CFDataRef process_get_requirement_data(process_t); | |
82 | ||
83 | AUTH_NONNULL_ALL | |
84 | SecRequirementRef process_get_requirement(process_t); | |
85 | ||
86 | AUTH_NONNULL_ALL | |
87 | bool process_verify_requirment(process_t,SecRequirementRef); | |
88 | ||
89 | AUTH_NONNULL_ALL | |
90 | bool process_apple_signed(process_t proc); | |
91 | ||
92 | AUTH_NONNULL_ALL | |
93 | mach_port_t process_get_bootstrap(process_t); | |
94 | ||
95 | AUTH_NONNULL_ALL | |
96 | bool process_set_bootstrap(process_t, mach_port_t); | |
97 | ||
98 | #if defined(__cplusplus) | |
99 | } | |
100 | #endif | |
101 | ||
102 | #endif /* !_SECURITY_AUTH_PROCESS_H_ */ |