Re: [PATCH] seteuid.2: glibc implements seteuid calling setresuid, not setreuid

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Štěpán,

On Wed, Feb 07, 2024 at 09:13:36PM +0100, Štěpán Němec wrote:
> Analogously with set*gid.
> 
> This has been the case since more than two decades, e.g.:
> 
>   commit eae59a5681a6 glibc-2.3.2-793-geae59a5681a6
>   Commit: Ulrich Drepper <drepper@xxxxxxxxxx>
>   CommitDate: Sun Jun 8 22:37:53 2003 +0000
> 
>   Update.
> 
>           * sysdeps/unix/sysv/linux/seteuid.c (seteuid): Use setresuid32
>           syscall directly if possible.  If __ASSUME_SETRESUID_SYSCALL is
>           defined drop compatibility code.
>   [...]
> 
> The change in implementation from setreuid/setregid is also
> already mentioned two paragraphs earlier in the same man page.
> 
> Fixes: a36b2bb0eca4 ("seteuid.2: seteuid() and setegid() are implemented as library functions")
> Fixes: 8554dd0324b0 ("seteuid.2: tfix")
> Signed-off-by: Štěpán Němec <stepnem@xxxxxxxx>

Patch applied.  Thanks.

Have a lovely day!
Alex

> ---
>  man2/seteuid.2 | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/man2/seteuid.2 b/man2/seteuid.2
> index 312ed1f9e002..0eae04f79fc9 100644
> --- a/man2/seteuid.2
> +++ b/man2/seteuid.2
> @@ -117,9 +117,9 @@ .SS C library/kernel differences
>  and
>  .BR setegid ()
>  are implemented as library functions that call, respectively,
> -.BR setreuid (2)
> +.BR setresuid (2)
>  and
> -.BR setregid (2).
> +.BR setresgid (2).
>  .SH STANDARDS
>  POSIX.1-2008.
>  .SH HISTORY
> 
> base-commit: 452f15569fc3cb1697b6482754dd51a56fcab970
> prerequisite-patch-id: 79eb7cb4939079d7fa9f00007856784f30801886
> -- 
> 2.43.0
> 

-- 
<https://www.alejandro-colomar.es/>
Looking for a remote C programming job at the moment.

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux