lkml.org 
[lkml]   [1996]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: BEWARE! Linux seteuid is broken!
>Huh, this Linux bug was discussed in linux-kernel.
>I do not know why it was not fixed in standard kernel,
>apaprently it was lost.
>
>kernel/exit.c:
>
>int send_sig(unsigned long sig,struct task_struct * p,int priv)
>{
> if (!p || sig > 32)
> return -EINVAL;
> if (!priv && ((sig != SIGCONT) || (current->session != p->session)) &&
>#ifdef NO_ANK_FIX
> (current->euid ^ p->euid) && (current->euid ^ p->uid) &&
> (current->uid ^ p->euid) && (current->uid ^ p->uid) &&
>#else
> (current->uid ^ p->suid) && (current->euid ^ p->uid) &&
^^^ umm... this should be euid, right?

> (current->uid ^ p->suid) && (current->uid ^ p->uid) &&
>#endif
> !suser())
> return -EPERM;

-- Aaron Ucko (ucko@vax1.rockhurst.edu; finger for PGP public key) | httyp!
"That's right," he said. "We're philosophers. We think, therefore we am."
-- Terry Pratchett, _Small Gods_ | Geek Code 3.1 [for explanation, finger
hayden@mankato.msus.edu]: GCS/M/S/C d- s: a18 C++(+++)>++++ UL++>++++ P++
L++>+++++ E- W(-) N++(+) o+ K- w--- O M@ V-(--) PS++(+++) PE- Y(+) PGP(+) t(+)
!5 X-- R(-) tv-@ b++(+++) DI+ !D-- G++(+++) e->+++++(*) h!>+ r-(--)>+++ y?


\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.037 / U:3.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site