Allow only root to look at other team's file descriptors.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15992 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2006-01-17 01:44:18 +00:00
parent 0e382a4667
commit 7817211a38
1 changed files with 4 additions and 0 deletions

View File

@ -6346,6 +6346,10 @@ _user_get_next_fd_info(team_id team, uint32 *userCookie, fd_info *userInfo,
struct fd_info info;
uint32 cookie;
// only root can do this (or should root's group be enough?)
if (geteuid() != 0)
return B_NOT_ALLOWED;
if (infoSize != sizeof(fd_info))
return B_BAD_VALUE;