xref: /freebsd/share/man/man9/uidinfo.9 (revision 4772483c009be91716eb583c23c484b06bdd8f50)
14772483cSRuslan Ermilov.\"
24772483cSRuslan Ermilov.\" Copyright (C) 2001 Chad David <davidc@acns.ab.ca>. All rights reserved.
34772483cSRuslan Ermilov.\"
44772483cSRuslan Ermilov.\" Redistribution and use in source and binary forms, with or without
54772483cSRuslan Ermilov.\" modification, are permitted provided that the following conditions
64772483cSRuslan Ermilov.\" are met:
74772483cSRuslan Ermilov.\" 1. Redistributions of source code must retain the above copyright
84772483cSRuslan Ermilov.\"    notice(s), this list of conditions and the following disclaimer as
94772483cSRuslan Ermilov.\"    the first lines of this file unmodified other than the possible
104772483cSRuslan Ermilov.\"    addition of one or more copyright notices.
114772483cSRuslan Ermilov.\" 2. Redistributions in binary form must reproduce the above copyright
124772483cSRuslan Ermilov.\"    notice(s), this list of conditions and the following disclaimer in the
134772483cSRuslan Ermilov.\"    documentation and/or other materials provided with the distribution.
144772483cSRuslan Ermilov.\"
154772483cSRuslan Ermilov.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY
164772483cSRuslan Ermilov.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
174772483cSRuslan Ermilov.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
184772483cSRuslan Ermilov.\" DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY
194772483cSRuslan Ermilov.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
204772483cSRuslan Ermilov.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
214772483cSRuslan Ermilov.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
224772483cSRuslan Ermilov.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
234772483cSRuslan Ermilov.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
244772483cSRuslan Ermilov.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
254772483cSRuslan Ermilov.\" DAMAGE.
264772483cSRuslan Ermilov.\"
274772483cSRuslan Ermilov.\" $FreeBSD$
284772483cSRuslan Ermilov.\"
294772483cSRuslan Ermilov.Dd July 10, 2001
304772483cSRuslan Ermilov.Dt UIDINFO 9
314772483cSRuslan Ermilov.Os
324772483cSRuslan Ermilov.Sh NAME
334772483cSRuslan Ermilov.Nm uidinfo ,
344772483cSRuslan Ermilov.Nm uihashinit ,
354772483cSRuslan Ermilov.Nm uifind ,
364772483cSRuslan Ermilov.Nm uihold ,
374772483cSRuslan Ermilov.Nm uifree
384772483cSRuslan Ermilov.Nd "functions for managing UID information"
394772483cSRuslan Ermilov.Sh SYNOPSIS
404772483cSRuslan Ermilov.In sys/param.h
414772483cSRuslan Ermilov.In sys/resourcevar.h
424772483cSRuslan Ermilov.Ft void
434772483cSRuslan Ermilov.Fn uihashinit void
444772483cSRuslan Ermilov.Ft "struct uidinfo *"
454772483cSRuslan Ermilov.Fn uifind "uid_t uid"
464772483cSRuslan Ermilov.Ft void
474772483cSRuslan Ermilov.Fn uihold "struct uidinfo *uip"
484772483cSRuslan Ermilov.Ft void
494772483cSRuslan Ermilov.Fn uifree "struct uidinfo *uip"
504772483cSRuslan Ermilov.Sh DESCRIPTION
514772483cSRuslan ErmilovThe
524772483cSRuslan Ermilov.Nm
534772483cSRuslan Ermilovfamily of functions
544772483cSRuslan Ermilovis used to manage
554772483cSRuslan Ermilov.Vt uidinfo
564772483cSRuslan Ermilovstructures.
574772483cSRuslan ErmilovThe
584772483cSRuslan Ermilov.Vt uidinfo
594772483cSRuslan Ermilovstructure maintains the process count and socket buffer space usage
604772483cSRuslan Ermilovfor a given UID.
614772483cSRuslan Ermilov.Pp
624772483cSRuslan ErmilovThe
634772483cSRuslan Ermilov.Fn uihashinit
644772483cSRuslan Ermilovfunction initializes the
654772483cSRuslan Ermilov.Vt uidinfo
664772483cSRuslan Ermilovhash table.
674772483cSRuslan ErmilovThis function should only be called during system initialization.
684772483cSRuslan Ermilov.Pp
694772483cSRuslan ErmilovThe
704772483cSRuslan Ermilov.Fn uifind
714772483cSRuslan Ermilovfunction looks up and returns the
724772483cSRuslan Ermilov.Vt uidinfo
734772483cSRuslan Ermilovstructure for the
744772483cSRuslan Ermilov.Fa uid .
754772483cSRuslan ErmilovIf the
764772483cSRuslan Ermilov.Vt uidinfo
774772483cSRuslan Ermilovis not found, a new structure is allocated.
784772483cSRuslan Ermilov.Pp
794772483cSRuslan ErmilovThe
804772483cSRuslan Ermilov.Fn uihold
814772483cSRuslan Ermilovfunction increases the reference count on the
824772483cSRuslan Ermilov.Vt uidinfo
834772483cSRuslan Ermilovstructure.
844772483cSRuslan Ermilov.Pp
854772483cSRuslan ErmilovThe
864772483cSRuslan Ermilov.Fn uifree
874772483cSRuslan Ermilovfunction decreases the reference count on the
884772483cSRuslan Ermilov.Vt uidinfo
894772483cSRuslan Ermilovstructure.
904772483cSRuslan ErmilovIf the count reaches 0, the storage for the structure is freed.
914772483cSRuslan Ermilov.Sh RETURN VALUES
924772483cSRuslan ErmilovThe functions that return values all return a pointer to a
934772483cSRuslan Ermilov.Vt uidinfo
944772483cSRuslan Ermilovstructure.
954772483cSRuslan Ermilov.Sh AUTHORS
964772483cSRuslan ErmilovThis man page was written by
974772483cSRuslan Ermilov.An Chad David Aq davidc@acns.ab.ca .
98