Improved English
[unix-history] / usr / src / lib / libc / sys / getuid.2
CommitLineData
42a92ee6
KM
1.\" Copyright (c) 1980 Regents of the University of California.
2.\" All rights reserved. The Berkeley software License Agreement
3.\" specifies the terms and conditions for redistribution.
4.\"
9c9177ce 5.\" @(#)getuid.2 6.1 (Berkeley) %G%
42a92ee6 6.\"
9c9177ce 7.TH GETUID 2 ""
42a92ee6
KM
8.UC 4
9.SH NAME
6db89aec 10getuid, geteuid \- get user identity
42a92ee6 11.SH SYNOPSIS
6db89aec
KM
12.ft B
13.nf
14uid = getuid()
15int uid;
42a92ee6 16.PP
6db89aec
KM
17.ft B
18euid = geteuid()
19int euid;
20.fi
42a92ee6
KM
21.SH DESCRIPTION
22.I Getuid
23returns the real user ID of the current process,
24.I geteuid
25the effective user ID.
42a92ee6 26.PP
6db89aec
KM
27The real user ID identifies the person who is logged in.
28The effective user ID
29gives the process additional permissions during
30execution of \*(lqset-user-ID\*(rq mode processes, which use
31\fIgetuid\fP to determine the real-user-id of the process which
32invoked them.
42a92ee6 33.SH "SEE ALSO"
6db89aec 34getgid(2), setreuid(2)