X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/2d21ac55c334faf3a56e5634905ed6987fc787d4..0a7de7458d150b5d4dffc935ba399be265ef0a1a:/bsd/man/man2/getauid.2 diff --git a/bsd/man/man2/getauid.2 b/bsd/man/man2/getauid.2 index eb61c0f21..373deb2a0 100644 --- a/bsd/man/man2/getauid.2 +++ b/bsd/man/man2/getauid.2 @@ -1,5 +1,5 @@ .\" -.\" Copyright (c) 2007 Apple Inc. All rights reserved. +.\" Copyright (c) 2008-2009 Apple Inc. All rights reserved. .\" .\" @APPLE_LICENSE_HEADER_START@ .\" @@ -20,36 +20,60 @@ .\" .\" @APPLE_LICENSE_HEADER_END@ .\" -.Dd July 30, 2007 +.Dd March 5, 2009 .Dt GETAUID 2 -.Os Darwin +.Os .Sh NAME .Nm getauid -.Nd get the audit user ID of the current process +.Nd "retrieve audit user ID" .Sh SYNOPSIS -.Fd #include +.In bsm/audit.h .Ft int -.Fn getauid "au_id_t * auid" +.Fn getauid "au_id_t *auid" .Sh DESCRIPTION The .Fn getauid -function returns the audit user ID for the calling process. The variable pointed -at by -.Fa auid -holds the ID returned by the system. +system call +retrieves the active audit user ID for the current process via the +.Vt au_id_t +pointed to by +.Fa auid . .Sh RETURN VALUES -Upon successful completion a value of 0 is returned. -Otherwise, a value of -1 is returned and -.Va errno -is set to indicate the error. +.Rv -std +.Sh ERRORS +The +.Fn getauid +function will fail if: +.Bl -tag -width Er +.It Bq Er EFAULT +A failure occurred while data transferred from +the kernel failed. +.El .Sh SEE ALSO .Xr audit 2 , .Xr auditon 2 , -.Xr auditctl 2 , -.Xr setauid 2 , .Xr getaudit 2 , -.Xr setaudit 2 +.Xr getaudit_addr 2 , +.Xr setaudit 2 , +.Xr setaudit_addr 2 , +.Xr setauid 2 , +.Xr libbsm 3 .Sh HISTORY -The -.Fn getauid -function call first appeared in Mac OS X 10.3 (Panther). +The OpenBSM implementation was created by McAfee Research, the security +division of McAfee Inc., under contract to Apple Computer Inc.\& in 2004. +It was subsequently adopted by the TrustedBSD Project as the foundation for +the OpenBSM distribution. +.Sh AUTHORS +.An -nosplit +This software was created by McAfee Research, the security research division +of McAfee, Inc., under contract to Apple Computer Inc. +Additional authors include +.An Wayne Salamon , +.An Robert Watson , +and SPARTA Inc. +.Pp +The Basic Security Module (BSM) interface to audit records and audit event +stream format were defined by Sun Microsystems. +.Pp +This manual page was written by +.An Robert Watson Aq rwatson@FreeBSD.org .