File tree 1 file changed +27
-0
lines changed
1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change
1
+ Access ACLs:
2
+
3
+ SecAccessRef access = NULL;
4
+ OSStatus status = SecKeychainItemCopyAccess(item, &access);
5
+ SRHandleError(status, true);
6
+
7
+ CFArrayRef aclList = NULL;
8
+ status = SecAccessCopyACLList(access, &aclList);
9
+ SRHandleError(status, true);
10
+
11
+ for (int j = 0; j < CFArrayGetCount(aclList); j++) {
12
+ SecACLRef acl = (SecACLRef)CFArrayGetValueAtIndex(aclList, j);
13
+ CFArrayRef applicationList = NULL;
14
+ CFStringRef description = NULL;
15
+ SecKeychainPromptSelector prompt = 0;
16
+ status = SecACLCopyContents(acl, &applicationList, &description, &prompt);
17
+ SRHandleError(status, true);
18
+
19
+ printf(" %s\n", SRCFStringCopyUTF8String(description));
20
+ CFShow(applicationList);
21
+
22
+ if (description) { CFRelease(description); }
23
+ if (applicationList) { CFRelease(applicationList); }
24
+ }
25
+
26
+ CFRelease(aclList);
27
+ CFRelease(access);
You can’t perform that action at this time.
0 commit comments