seteuid man page on NeXTSTEP

Man page or keyword search:  
man Server   1419 pages
apropos Keyword Search (all sections)
Output format
NeXTSTEP logo
[printable version]


SETUID(3)							     SETUID(3)

NAME
       setuid, setgid- set user and group ID

SYNOPSIS
       #include <sys/types.h>

       int setuid(uid_t uid);

       int setgid(gid_t gid);

(ALSO AVAILABLE IN BSD)
       int seteuid(uid_t euid);

       int setruid(uid_t ruid);

       int setegid(gid_t egid);

       int setrgid(gid_t rgid);

DESCRIPTION
       Setuid  (setgid)	 sets  the  real  and effective user ID (group ID) and
       saved set-user-ID (set-group-ID) of the current process to uid (gid) if
       the  calling  process is super-user.  If the process is not super-user,
       but uid (gid) is equal to the real user ID or  the  saved  set-user-ID,
       setuid (setgid) sets the effective user ID to uid (gid).

       The BSD routines seteuid, setruid, setegid, and setrgid set either just
       the effective or just the real user or group ID as above.

RETURN VALUE
       Upon successful completion a value of zero is returned.	Otherwise a -1
       is returned and errno is set to indicate the error.

ERRORS
       Setuid  and  setgid  shall return -1 and set errno to the corresponding
       value:

       [EINVAL]	      The value of the uid (gid) argument is invalid  and  not
		      supported by the implementation.

       [EPERM]	      The process does not have appropriate privileges and uid
		      (gid) does not match the real user ID or the saved  set-
		      user-ID.

SEE ALSO
       setreuid(2), setregid(2), getuid(2), getgid(2)

4.2 Berkeley Distribution	August 1, 1992			     SETUID(3)
[top]

List of man pages available for NeXTSTEP

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net