[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]
Base Operating System and Extensions Technical Reference, Volume 1

getuid or geteuid Subroutine

Purpose

Gets the real or effective user ID of the current process.

Library

Standard C Library (libc.a)

Syntax

#include <sys/types.h>
#include <unistd.h>
uid_t getuid(void)
uid_t geteuid(void)

Description

The getuid subroutine returns the real user ID of the current process. The geteuid subroutine returns the effective user ID of the current process.

Return Values

The getuid and geteuid subroutines return the corresponding user ID.

Note: The getuid and geteuid subroutines always succeed.

Implementation Specifics

These subroutines are part of Base Operating System (BOS) Runtime.

Related Information

The setuid subroutine.

List of Security and Auditing Subroutines, Subroutines Overview in AIX Version 4.3 General Programming Concepts: Writing and Debugging Programs.


[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]