]> git.saurik.com Git - apple/security.git/blobdiff - Security/authd/ccaudit.h
Security-57031.1.35.tar.gz
[apple/security.git] / Security / authd / ccaudit.h
diff --git a/Security/authd/ccaudit.h b/Security/authd/ccaudit.h
new file mode 100644 (file)
index 0000000..4ce4ffa
--- /dev/null
@@ -0,0 +1,26 @@
+/* Copyright (c) 2012-2013 Apple Inc. All Rights Reserved. */
+
+#ifndef _SECURITY_AUTH_CCAUDIT_H_
+#define _SECURITY_AUTH_CCAUDIT_H_
+
+#include <bsm/audit_uevents.h>
+
+AUTH_WARN_RESULT AUTH_MALLOC AUTH_NONNULL_ALL AUTH_RETURNS_RETAINED
+ccaudit_t ccaudit_create(process_t, auth_token_t, int32_t event);
+
+AUTH_NONNULL_ALL
+void ccaudit_log_authorization(ccaudit_t, const char * right, OSStatus err);
+
+AUTH_NONNULL_ALL
+void ccaudit_log_success(ccaudit_t, credential_t cred, const char * right);
+
+AUTH_NONNULL_ALL
+void ccaudit_log_failure(ccaudit_t, const char * credName, const char * right);
+
+AUTH_NONNULL1
+void ccaudit_log_mechanism(ccaudit_t, const char * right, const char * mech, uint32_t status, const char * interrupted);
+
+AUTH_NONNULL1
+void ccaudit_log(ccaudit_t, const char * right, const char * msg, OSStatus err);
+
+#endif /* !_SECURITY_AUTH_CCAUDIT_H_ */