Gets the real or effective user ID of the current process.
#include <sys/types.h> #include <unistd.h>
uid_t getuid(void)
uid_t geteuid(void)
The getuid subroutine returns the real user ID of the current process. The geteuid subroutine returns the effective user ID of the current process.
The getuid and geteuid subroutines return the corresponding user ID.
Note: The getuid and geteuid subroutines always succeed.
These subroutines are part of Base Operating System (BOS) Runtime.
The setuid subroutine.
List of Security and Auditing Subroutines, Subroutines Overview in AIX 5L Version 5.1 General Programming Concepts: Writing and Debugging Programs.