@@ -577,7 +577,7 @@ void ctrl_alt_del(void)
else
kill_cad_pid (SIGINT, 1 );
}
/*
* Unprivileged users may change the real gid to the effective gid
* or vice versa. (BSD-style)
@@ -591,7 +591,7 @@ void ctrl_alt_del(void)
*
* The general idea is that a program which uses just setregid() will be
* 100% compatible with BSD. A program which uses just setgid() will be
* 100% compatible with POSIX with saved IDs.
* 100% compatible with POSIX with saved IDs.
*
* SMP: There are not races, the GIDs are checked only by filesystem
* operations (as far as semantic preservation is concerned).
@@ -639,7 +639,7 @@ SYSCALL_DEFINE2(setregid, gid_t, rgid, gid_t, egid)
}
/*
* setgid() is implemented like SysV w/ SAVED_IDS
* setgid() is implemented like SysV w/ SAVED_IDS
*
* SMP: Same implicit races as above.
*/
@@ -712,7 +712,7 @@ static int set_user(struct cred *new)
*
* The general idea is that a program which uses just setreuid() will be
* 100% compatible with BSD. A program which uses just setuid() will be
* 100% compatible with POSIX with saved IDs.
* 100% compatible with POSIX with saved IDs.
*/
SYSCALL_DEFINE2 (setreuid, uid_t , ruid, uid_t , euid)
{
@@ -763,17 +763,17 @@ SYSCALL_DEFINE2(setreuid, uid_t, ruid, uid_t, euid)
abort_creds (new);
return retval;
}
/*
* setuid() is implemented like SysV with SAVED_IDS
*
* setuid() is implemented like SysV with SAVED_IDS
*
* Note that SAVED_ID's is deficient in that a setuid root program
* like sendmail, for example, cannot set its uid to be a normal
* like sendmail, for example, cannot set its uid to be a normal
* user and then switch back, because if you're root, setuid() sets
* the saved uid too. If you don't like this, blame the bright people
* in the POSIX committee and/or USG. Note that the BSD-style setreuid()
* will allow a root program to temporarily drop privileges and be able to
* regain them by swapping the real and effective uid.
* regain them by swapping the real and effective uid.
*/
SYSCALL_DEFINE1 (setuid, uid_t , uid)
{
@@ -1205,7 +1205,7 @@ SYSCALL_DEFINE0(setsid)
write_unlock_irq (&tasklist_lock);
if (err > 0 ) {
proc_sid_connector (group_leader);
}
return err;
}
@@ -1415,7 +1415,7 @@ SYSCALL_DEFINE2(getrlimit, unsigned int, resource, struct rlimit __user *, rlim)
/*
* Back compatibility for getrlimit. Needed for some apps.
*/
SYSCALL_DEFINE2 (old_getrlimit, unsigned int , resource,
struct rlimit __user *, rlim)
{
@@ -2170,9 +2170,6 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, arg2, unsigned long, arg3,
error = prctl_set_vma (arg2, arg3, arg4, arg5);
break ;
case PR_SET_TIMERSLACK_PID:
if (task_pid_vnr (current) != (pid_t )arg3 &&
!capable (CAP_SYS_NICE))
return -EPERM;
rcu_read_lock ();
tsk = find_task_by_vpid ((pid_t )arg3);
if (tsk == NULL ) {