On Mon, 2 Jul 2007, Andy Isaacson wrote: > On Sat, Jun 30, 2007 at 12:03:07PM -0700, Davide Libenzi wrote: > > I think the focus should be to find a case where under the currently > > implemented policy for MAP_NOZERO, MAP_NOZERO represent a loss of security > > WRT no MAP_NOZERO. I have not been able to find one yet, although Andy > > found a potential one in the setuid+exec/ptrace race (fixed by a patch > > that should IMO go in in any case). > > BTW, the ptrace variant of this issue is not a problem -- PTRACE_ATTACH > running as newuid gets EPERM when trying to attach at /* here */ below. > > setuid(newuid); > /* here */ > exec(...); > exit(1); > > sys_setuid sets current->mm->dumpable = suid_dumpable, so unless the > admin asked for it, there is no risk WRT PTRACE_ATTACH. However, this > risk vector does need to be considered when implementing MAP_NOZERO.
Yes, I missed that. Ptrace is fine there. The 3 lines patch is still needed for MAP_NOZERO though. - Davide - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/