1GETUID(2)                     System Calls Manual                    GETUID(2)
2
3
4

NAME

6       getuid, geteuid - get user identification
7

SYNOPSIS

9       #include <unistd.h>
10       #include <sys/types.h>
11
12       uid_t
13       getuid()
14
15       uid_t
16       geteuid()
17

DESCRIPTION

19       The  getuid  function  returns the real user ID of the calling process.
20       The geteuid function returns the  effective  user  ID  of  the  calling
21       process.
22
23       The  real  user ID is that of the user who has invoked the program.  As
24       the effective user ID gives the process additional  permissions  during
25       execution  of  ``set-user-ID'' mode processes, getuid is used to deter‐
26       mine the real-user-id of the calling process.
27

ERRORS

29       The getuid and geteuid functions are always successful, and  no  return
30       value is reserved to indicate an error.
31

SEE ALSO

33       getgid(2), setreuid(2)
34

STANDARDS

36       Geteuid and getuid conform to IEEE Std 1003.1-1988 (``POSIX'').
37
38
39
404.2 Berkeley Distribution      December 2, 1997                      GETUID(2)
Impressum