diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-12-28 14:43:54 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-12-28 14:43:54 -0500 |
commit | bb26c6c29b7cc9f39e491b074b09f3c284738d36 (patch) | |
tree | c7867af2bb4ff0feae889183efcd4d79b0f9a325 /arch/mips/kernel | |
parent | e14e61e967f2b3bdf23f05e4ae5b9aa830151a44 (diff) | |
parent | cbacc2c7f066a1e01b33b0e27ae5efbf534bc2db (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6: (105 commits)
SELinux: don't check permissions for kernel mounts
security: pass mount flags to security_sb_kern_mount()
SELinux: correctly detect proc filesystems of the form "proc/foo"
Audit: Log TIOCSTI
user namespaces: document CFS behavior
user namespaces: require cap_set{ug}id for CLONE_NEWUSER
user namespaces: let user_ns be cloned with fairsched
CRED: fix sparse warnings
User namespaces: use the current_user_ns() macro
User namespaces: set of cleanups (v2)
nfsctl: add headers for credentials
coda: fix creds reference
capabilities: define get_vfs_caps_from_disk when file caps are not enabled
CRED: Allow kernel services to override LSM settings for task actions
CRED: Add a kernel_service object class to SELinux
CRED: Differentiate objective and effective subjective credentials on a task
CRED: Documentation
CRED: Use creds in file structs
CRED: Prettify commoncap.c
CRED: Make execve() take advantage of copy-on-write credentials
...
Diffstat (limited to 'arch/mips/kernel')
-rw-r--r-- | arch/mips/kernel/kspd.c | 4 | ||||
-rw-r--r-- | arch/mips/kernel/mips-mt-fpaff.c | 5 | ||||
-rw-r--r-- | arch/mips/kernel/vpe.c | 4 |
3 files changed, 7 insertions, 6 deletions
diff --git a/arch/mips/kernel/kspd.c b/arch/mips/kernel/kspd.c index b0591ae0ce56..fd6e51224034 100644 --- a/arch/mips/kernel/kspd.c +++ b/arch/mips/kernel/kspd.c | |||
@@ -174,8 +174,8 @@ static unsigned int translate_open_flags(int flags) | |||
174 | 174 | ||
175 | static void sp_setfsuidgid( uid_t uid, gid_t gid) | 175 | static void sp_setfsuidgid( uid_t uid, gid_t gid) |
176 | { | 176 | { |
177 | current->fsuid = uid; | 177 | current->cred->fsuid = uid; |
178 | current->fsgid = gid; | 178 | current->cred->fsgid = gid; |
179 | 179 | ||
180 | key_fsuid_changed(current); | 180 | key_fsuid_changed(current); |
181 | key_fsgid_changed(current); | 181 | key_fsgid_changed(current); |
diff --git a/arch/mips/kernel/mips-mt-fpaff.c b/arch/mips/kernel/mips-mt-fpaff.c index dc9eb72ed9de..5e77a3a21f98 100644 --- a/arch/mips/kernel/mips-mt-fpaff.c +++ b/arch/mips/kernel/mips-mt-fpaff.c | |||
@@ -51,6 +51,7 @@ asmlinkage long mipsmt_sys_sched_setaffinity(pid_t pid, unsigned int len, | |||
51 | int retval; | 51 | int retval; |
52 | struct task_struct *p; | 52 | struct task_struct *p; |
53 | struct thread_info *ti; | 53 | struct thread_info *ti; |
54 | uid_t euid; | ||
54 | 55 | ||
55 | if (len < sizeof(new_mask)) | 56 | if (len < sizeof(new_mask)) |
56 | return -EINVAL; | 57 | return -EINVAL; |
@@ -76,9 +77,9 @@ asmlinkage long mipsmt_sys_sched_setaffinity(pid_t pid, unsigned int len, | |||
76 | */ | 77 | */ |
77 | get_task_struct(p); | 78 | get_task_struct(p); |
78 | 79 | ||
80 | euid = current_euid(); | ||
79 | retval = -EPERM; | 81 | retval = -EPERM; |
80 | if ((current->euid != p->euid) && (current->euid != p->uid) && | 82 | if (euid != p->euid && euid != p->uid && !capable(CAP_SYS_NICE)) { |
81 | !capable(CAP_SYS_NICE)) { | ||
82 | read_unlock(&tasklist_lock); | 83 | read_unlock(&tasklist_lock); |
83 | goto out_unlock; | 84 | goto out_unlock; |
84 | } | 85 | } |
diff --git a/arch/mips/kernel/vpe.c b/arch/mips/kernel/vpe.c index a1b3da6bad5c..010b27e01f7b 100644 --- a/arch/mips/kernel/vpe.c +++ b/arch/mips/kernel/vpe.c | |||
@@ -1085,8 +1085,8 @@ static int vpe_open(struct inode *inode, struct file *filp) | |||
1085 | v->load_addr = NULL; | 1085 | v->load_addr = NULL; |
1086 | v->len = 0; | 1086 | v->len = 0; |
1087 | 1087 | ||
1088 | v->uid = filp->f_uid; | 1088 | v->uid = filp->f_cred->fsuid; |
1089 | v->gid = filp->f_gid; | 1089 | v->gid = filp->f_cred->fsgid; |
1090 | 1090 | ||
1091 | #ifdef CONFIG_MIPS_APSP_KSPD | 1091 | #ifdef CONFIG_MIPS_APSP_KSPD |
1092 | /* get kspd to tell us when a syscall_exit happens */ | 1092 | /* get kspd to tell us when a syscall_exit happens */ |