Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
e48fbb69
Commit
e48fbb69
authored
Jan 14, 2009
by
Heiko Carstens
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[CVE-2009-0029] System call wrappers part 24
Signed-off-by:
Heiko Carstens
<
heiko.carstens@de.ibm.com
>
parent
5a8a82b1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
12 deletions
+13
-12
ipc/msg.c
ipc/msg.c
+6
-6
kernel/sys.c
kernel/sys.c
+7
-6
No files found.
ipc/msg.c
View file @
e48fbb69
...
...
@@ -309,7 +309,7 @@ static inline int msg_security(struct kern_ipc_perm *ipcp, int msgflg)
return
security_msg_queue_associate
(
msq
,
msgflg
);
}
asmlinkage
long
sys_msgget
(
key_t
key
,
int
msgflg
)
SYSCALL_DEFINE2
(
msgget
,
key_t
,
key
,
int
,
msgflg
)
{
struct
ipc_namespace
*
ns
;
struct
ipc_ops
msg_ops
;
...
...
@@ -466,7 +466,7 @@ static int msgctl_down(struct ipc_namespace *ns, int msqid, int cmd,
return
err
;
}
asmlinkage
long
sys_msgctl
(
int
msqid
,
int
cmd
,
struct
msqid_ds
__user
*
buf
)
SYSCALL_DEFINE3
(
msgctl
,
int
,
msqid
,
int
,
cmd
,
struct
msqid_ds
__user
*
,
buf
)
{
struct
msg_queue
*
msq
;
int
err
,
version
;
...
...
@@ -723,8 +723,8 @@ long do_msgsnd(int msqid, long mtype, void __user *mtext,
return
err
;
}
asmlinkage
long
sys_msgsnd
(
int
msqid
,
struct
msgbuf
__user
*
msgp
,
size_t
msgsz
,
int
msgflg
)
SYSCALL_DEFINE4
(
msgsnd
,
int
,
msqid
,
struct
msgbuf
__user
*
,
msgp
,
size_t
,
msgsz
,
int
,
msgflg
)
{
long
mtype
;
...
...
@@ -904,8 +904,8 @@ long do_msgrcv(int msqid, long *pmtype, void __user *mtext,
return
msgsz
;
}
asmlinkage
long
sys_msgrcv
(
int
msqid
,
struct
msgbuf
__user
*
msgp
,
size_t
msgsz
,
long
msgtyp
,
int
msgflg
)
SYSCALL_DEFINE5
(
msgrcv
,
int
,
msqid
,
struct
msgbuf
__user
*
,
msgp
,
size_t
,
msgsz
,
long
,
msgtyp
,
int
,
msgflg
)
{
long
err
,
mtype
;
...
...
kernel/sys.c
View file @
e48fbb69
...
...
@@ -1395,7 +1395,7 @@ EXPORT_SYMBOL(in_egroup_p);
DECLARE_RWSEM
(
uts_sem
);
asmlinkage
long
sys_newuname
(
struct
new_utsname
__user
*
name
)
SYSCALL_DEFINE1
(
newuname
,
struct
new_utsname
__user
*
,
name
)
{
int
errno
=
0
;
...
...
@@ -1478,7 +1478,7 @@ SYSCALL_DEFINE2(setdomainname, char __user *, name, int, len)
return
errno
;
}
asmlinkage
long
sys_getrlimit
(
unsigned
int
resource
,
struct
rlimit
__user
*
rlim
)
SYSCALL_DEFINE2
(
getrlimit
,
unsigned
int
,
resource
,
struct
rlimit
__user
*
,
rlim
)
{
if
(
resource
>=
RLIM_NLIMITS
)
return
-
EINVAL
;
...
...
@@ -1497,7 +1497,8 @@ asmlinkage long sys_getrlimit(unsigned int resource, struct rlimit __user *rlim)
* Back compatibility for getrlimit. Needed for some apps.
*/
asmlinkage
long
sys_old_getrlimit
(
unsigned
int
resource
,
struct
rlimit
__user
*
rlim
)
SYSCALL_DEFINE2
(
old_getrlimit
,
unsigned
int
,
resource
,
struct
rlimit
__user
*
,
rlim
)
{
struct
rlimit
x
;
if
(
resource
>=
RLIM_NLIMITS
)
...
...
@@ -1515,7 +1516,7 @@ asmlinkage long sys_old_getrlimit(unsigned int resource, struct rlimit __user *r
#endif
asmlinkage
long
sys_setrlimit
(
unsigned
int
resource
,
struct
rlimit
__user
*
rlim
)
SYSCALL_DEFINE2
(
setrlimit
,
unsigned
int
,
resource
,
struct
rlimit
__user
*
,
rlim
)
{
struct
rlimit
new_rlim
,
*
old_rlim
;
int
retval
;
...
...
@@ -1688,7 +1689,7 @@ int getrusage(struct task_struct *p, int who, struct rusage __user *ru)
return
copy_to_user
(
ru
,
&
r
,
sizeof
(
r
))
?
-
EFAULT
:
0
;
}
asmlinkage
long
sys_getrusage
(
int
who
,
struct
rusage
__user
*
ru
)
SYSCALL_DEFINE2
(
getrusage
,
int
,
who
,
struct
rusage
__user
*
,
ru
)
{
if
(
who
!=
RUSAGE_SELF
&&
who
!=
RUSAGE_CHILDREN
&&
who
!=
RUSAGE_THREAD
)
...
...
@@ -1696,7 +1697,7 @@ asmlinkage long sys_getrusage(int who, struct rusage __user *ru)
return
getrusage
(
current
,
who
,
ru
);
}
asmlinkage
long
sys_umask
(
int
mask
)
SYSCALL_DEFINE1
(
umask
,
int
,
mask
)
{
mask
=
xchg
(
&
current
->
fs
->
umask
,
mask
&
S_IRWXUGO
);
return
mask
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment