'\" te .\" Copyright (c) 2017 Peter Tribble .\" Copyright (c) 2005, Sun Microsystems, Inc. All Rights Reserved. .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] .TH AU_USER_MASK 3BSM "Mar 6, 2017" .SH NAME au_user_mask \- get user's binary preselection mask .SH SYNOPSIS .LP .nf \fBcc\fR [ \fIflag\fR... ] \fIfile\fR... \fB-lbsm\fR \fB -lsocket \fR \fB -lnsl \fR [ \fIlibrary\fR... ] #include \fBint\fR \fBau_user_mask\fR(\fBchar *\fR\fIusername\fR, \fBau_mask_t *\fR\fImask_p\fR); .fi .SH DESCRIPTION .LP The \fBau_user_mask()\fR function reads the default, system wide audit classes, combines them with the per-user audit classes, and updates the binary preselection mask pointed to by \fImask_p\fR with the combined value. .sp .LP The audit preselection mask is constructed as follows: .sp .in +2 .nf success flags = (system default success flags + per-user always success flags) - per-user never success flags failure flags = (system default failure flags + per-user always failure flags) - per-user never failure flags .fi .in -2 .sp .LP The \fBau_user_mask()\fR function fails only if the system wide audit flags could not be retrieved. .SH RETURN VALUES .LP Upon successful completion, \fBau_user_mask()\fR returns 0. .SH ATTRIBUTES .LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp .sp .TS box; c | c l | l . ATTRIBUTE TYPE ATTRIBUTE VALUE _ Interface Stability Stable _ MT-Level MT-Safe .TE .SH SEE ALSO .LP \fBlogin\fR(1), \fBgetaudit\fR(2), \fBsetaudit\fR(2), \fBau_preselect\fR(3BSM), \fBattributes\fR(5) .SH NOTES .LP The \fBau_user_mask()\fR function should be called by programs like \fBlogin\fR(1) which set a process's preselection mask with \fBsetaudit\fR(2). \fBgetaudit\fR(2) should be used to obtain audit characteristics for the current process. .sp .LP If global zone auditing is set, a local zone cannot reduce the default flags.