Notes |
(0004879)
mkerrisk (reporter)
2020-05-21 13:09
|
On page 448 (<unistd.h> Declarations), after line 15419, insert
int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid);
int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid);
On page 448 (<unistd.h> Declarations), after line 15443, insert
int setresgid(gid_t rgid, gid_t egid, gid_t sgid);
int setresuid(uid_t ruid, uid_t euid, uid_t suid);
On page 451 (<unistd.h> SEE ALSO) at lines 15579-15581, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1028 (getegid() SEE ALSO) at line 35033, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1032 (geteuid() SEE ALSO) at line 35171, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1033 (getgid() SEE ALSO) at line 35210, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1104 (getuid() SEE ALSO) at line 37410, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1890 (setegid() SEE ALSO) at line 61214, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1893 (seteuid() SEE ALSO) at line 61308, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1894 (setgid() SEE ALSO) at line 61345, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1917 (setregid() SEE ALSO) at line 61847, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1919 (setreuid() SEE ALSO) at line 61908, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
On page 1929 (setuid() SEE ALSO) at line 62155, insert the following
entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
(Depending on whether these APIs should be part of XSI_USER_GROUPS)
On page 3794 (Subprofiling Option Groups) at lines 130234-130234,
insert the following entries into the list in sorted order:
getresgid(), getresuid(), setresgid(), setresuid()
At page 1086, insert the specifications for getresuid() and getresgid():
NAME
getresgid - get real group ID, effective group ID, and saved set-group-ID
SYNOPSIS
#include <unistd.h>
int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid);
DESCRIPTION
The getresgid() function shall return the calling process's real
group ID, effective group ID, and saved set-group-ID, storing them
in the locations pointed to by, respectively, the arguments rgid,
egid, and sgid.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1
shall be returned and errno set to indicate the error.
ERRORS
No errors are defined.
SEE ALSO
getegid(), geteuid(), getgid(), getresuid(), getuid(), setegid(),
setgid(), seteuid(), setregid(), setresgid(), setresuid(),
setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
NAME
getresuid - get real user ID, effective user ID, and saved set-user-ID
SYNOPSIS
#include <unistd.h>
int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid);
DESCRIPTION
The getresuid() function shall return the calling process's real
user ID, effective user ID, and saved set-user-ID, storing them in
the locations pointed to by, respectively, the arguments ruid,
euid, and suid.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1
shall be returned and errno set to indicate the error.
ERRORS
No errors are defined.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getuid(), setegid(),
setgid(), seteuid(), setregid(), setresgid(), setresuid(),
setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
At page 1918, insert the specifications for setresuid() and setresgid():
NAME
setresgid - set real group ID, effective group ID, and saved set-group-ID
SYNOPSIS
#include <unistd.h>
int setresgid(gid_t rgid, gid_t egid, gid_t sgid);
DESCRIPTION
The setresgid() function shall change the calling process's real
group ID, effective group ID, and saved set-group-ID, respectively,
to the values specified by rgid, egid, and sgid.
If one of the arguments is -1, the corresponding group ID shall
not be changed.
Only a process with appropriate privileges can set the real group
ID, effective group ID, and saved set-group-ID to any valid value.
A non-privileged process may set its real group ID, effective
group ID, and saved set-group-ID, each to one of the values that
it currently holds in its real group ID, effective group ID, or
saved set-group-ID.
The real group ID, effective group ID, and saved set-group-ID may
be set to different values in the same call.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1
shall be returned and errno set to indicate the error, and none of
the group IDs shall be changed.
ERRORS
The setresgid() function shall fail if:
[EINVAL]
The value of the rgid, egid, or sgid argument is invalid or out-of-range.
[EPERM]
The calling process does not have appropriate privileges,
and an attempt was made to change the real group ID,
effective group ID, or saved set-group-ID to a value that
is not currently present in one of those IDs.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getresuid(),
getuid(), setegid(), seteuid(), setgid(), setregid(), setresuid(),
setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
NAME
setresuid - set real user ID, effective user ID, and saved set-user-ID
SYNOPSIS
#include <unistd.h>
int setresuid(uid_t ruid, uid_t euid, uid_t suid);
DESCRIPTION
The setresuid() function shall change the calling process's real
user ID, effective user ID, and saved set-user-ID, respectively,
to the values specified by ruid, euid, and suid.
If one of the arguments is -1, the corresponding user ID shall not
be changed.
Only a process with appropriate privileges can set the real user
ID, effective user ID, and saved set-user-ID to any valid value.
A non-privileged process may set its real user ID, effective user
ID, and saved set-user-ID, each to one of the values that it
currently holds in its real user ID, effective user ID, or saved
set-user-ID.
The real user ID, effective user ID, and saved set-user-ID may be
set to different values in the same call.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1
shall be returned and errno set to indicate the error, and none of
the user IDs shall be changed.
ERRORS
The setresuid() function shall fail if:
[EINVAL]
The value of the ruid, euid, or suid argument is invalid or out-of-range.
[EPERM]
The calling process does not have appropriate privileges,
and an attempt was made to change the real user ID,
effective user ID, or saved set-user-ID to a value that is
not currently present in one of those IDs.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getresuid(),
getuid(), setegid(), seteuid(), setgid(), setregid(), setresgid(),
setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
|
|
(0005699)
geoffclare (manager)
2022-02-22 10:15
edited on: 2022-02-24 16:16
|
This is an updated version of Note: 0004879 with XSI shading added, parameter names removed from header prototypes, and some minor wording and formatting changes.
On page 448 (<unistd.h> Declarations), after line 15419, insert with XSI shading:int getresgid(gid_t *, gid_t *, gid_t *);
int getresuid(uid_t *, uid_t *, uid_t *);
On page 448 (<unistd.h> Declarations), after line 15443, insert with XSI shading:int setresgid(gid_t, gid_t, gid_t);
int setresuid(uid_t, uid_t, uid_t);
On page 451 (<unistd.h> SEE ALSO) at lines 15579-15581, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1028 (getegid() SEE ALSO) at line 35033, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1032 (geteuid() SEE ALSO) at line 35171, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1033 (getgid() SEE ALSO) at line 35210, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1104 (getuid() SEE ALSO) at line 37410, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1890 (setegid() SEE ALSO) at line 61214, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1893 (seteuid() SEE ALSO) at line 61308, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1894 (setgid() SEE ALSO) at line 61345, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1917 (setregid() SEE ALSO) at line 61847, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1919 (setreuid() SEE ALSO) at line 61908, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 1929 (setuid() SEE ALSO) at line 62155, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
On page 3794 (Subprofiling Option Groups) at lines 130234-130234, insert the following entries into the list in sorted order:getresgid(), getresuid(), setresgid(), setresuid()
At page 1086, insert the specifications for getresuid() and getresgid():
NAME
getresgid - get real group ID, effective group ID, and saved set-group-ID
SYNOPSIS
[XSI]#include <unistd.h>
int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid);[/XSI]
DESCRIPTION
The getresgid() function shall store the real group ID, effective group ID, and saved set-group-ID of the calling process in the locations pointed to by the arguments rgid, egid, and sgid, respectively.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1 shall be returned and errno set to indicate the error.
ERRORS
No errors are defined.
SEE ALSO
getegid(), geteuid(), getgid(), getresuid(), getuid(), setegid(), setgid(), seteuid(), setregid(), setresgid(), setresuid(), setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
NAME
getresuid - get real user ID, effective user ID, and saved set-user-ID
SYNOPSIS
[XSI]#include <unistd.h>
int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid);[/XSI]
DESCRIPTION
The getresuid() function shall store the real user ID, effective user ID, and saved set-user-ID of the calling process in the locations pointed to by the arguments ruid, euid, and suid, respectively.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1 shall be returned and errno set to indicate the error.
ERRORS
No errors are defined.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getuid(), setegid(), setgid(), seteuid(), setregid(), setresgid(), setresuid(), setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
At page 1918, insert the specifications for setresuid() and setresgid():
NAME
setresgid - set real group ID, effective group ID, and saved set-group-ID
SYNOPSIS
[XSI]#include <unistd.h>
int setresgid(gid_t rgid, gid_t egid, gid_t sgid);[/XSI]
DESCRIPTION
The setresgid() function shall change the real group ID, effective group ID, and saved set-group-ID of the calling process to the values specified by rgid, egid, and sgid, respectively.
If an argument is -1, the corresponding ID shall not be changed.
Only a process with appropriate privileges can set the real group ID, effective group ID, and saved set-group-ID to any valid value.
A non-privileged process can set its real group ID, effective group ID, and saved set-group-ID, each to one of the values that it currently holds in its real group ID, effective group ID, or saved set-group-ID.
The real group ID, effective group ID, and saved set-group-ID can be set to different values in the same call.
Any supplementary group IDs of the calling process shall remain unchanged.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1 shall be returned and errno set to indicate the error, and none of the IDs shall be changed.
ERRORS
The setresgid() function shall fail if:
[EINVAL]The value of the rgid, egid, or sgid argument is invalid or out-of-range.
[EPERM]The calling process does not have appropriate privileges and an attempt was made to change the real group ID, effective group ID, or saved set-group-ID to a value that is not currently present in one of those IDs.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getresuid(), getuid(), setegid(), seteuid(), setgid(), setregid(), setresuid(), setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
NAME
setresuid - set real user ID, effective user ID, and saved set-user-ID
SYNOPSIS
[XSI]#include <unistd.h>
int setresuid(uid_t ruid, uid_t euid, uid_t suid);[/XSI]
DESCRIPTION
The setresuid() function shall change the real user ID, effective user ID, and saved set-user-ID of the calling process to the values specified by ruid, euid, and suid, respectively.
If an argument is -1, the corresponding ID shall not be changed.
Only a process with appropriate privileges can set the real user ID, effective user ID, and saved set-user-ID to any valid value.
A non-privileged process can set its real user ID, effective user ID, and saved set-user-ID, each to one of the values that it currently holds in its real user ID, effective user ID, or saved set-user-ID.
The real user ID, effective user ID, and saved set-user-ID can be set to different values in the same call.
RETURN VALUE
Upon successful completion, 0 shall be returned. Otherwise, -1 shall be returned and errno set to indicate the error, and none of the IDs shall be changed.
ERRORS
The setresuid() function shall fail if:
[EINVAL]The value of the ruid, euid, or suid argument is invalid or out-of-range.
[EPERM]The calling process does not have appropriate privileges and either an attempt was made to change the real user ID, effective user ID, or saved set-user-ID to a value that is not currently present in one of those IDs or an attempt was made to change the real user ID to a value not permitted by the implementation.
SEE ALSO
getegid(), geteuid(), getgid(), getresgid(), getresuid(), getuid(), setegid(), seteuid(), setgid(), setregid(), setresgid(), setreuid(), setuid()
XBD <sys/types.h>, <unistd.h>
|
|
(0005922)
geoffclare (manager)
2022-07-29 14:24
|
The getresgid(), getresuid(), setresgid(), and setresuid() additions have been made in the Issue8NewAPIs branch in gitlab, based on Note: 0005699 |
|