Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 144818
b: refs/heads/master
c: a44ddbb
h: refs/heads/master
v: v3
  • Loading branch information
Al Viro committed May 9, 2009
1 parent f77208f commit 7a2ff38
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e24977d45f45d1675e050dc1a0aaf4bfc4ca9866
refs/heads/master: a44ddbb6d8a8ffe4e34e417048dfdd8f3dd1de4f
11 changes: 2 additions & 9 deletions trunk/fs/exec.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,7 @@ SYSCALL_DEFINE1(uselib, const char __user *, library)
if (nd.path.mnt->mnt_flags & MNT_NOEXEC)
goto exit;

error = inode_permission(nd.path.dentry->d_inode,
MAY_READ | MAY_EXEC | MAY_OPEN);
if (error)
goto exit;
error = ima_path_check(&nd.path, MAY_READ | MAY_EXEC | MAY_OPEN);
error = may_open(&nd.path, MAY_READ | MAY_EXEC | MAY_OPEN, 0);
if (error)
goto exit;

Expand Down Expand Up @@ -677,10 +673,7 @@ struct file *open_exec(const char *name)
if (nd.path.mnt->mnt_flags & MNT_NOEXEC)
goto out_path_put;

err = inode_permission(nd.path.dentry->d_inode, MAY_EXEC | MAY_OPEN);
if (err)
goto out_path_put;
err = ima_path_check(&nd.path, MAY_EXEC | MAY_OPEN);
err = may_open(&nd.path, MAY_EXEC | MAY_OPEN, 0);
if (err)
goto out_path_put;

Expand Down

0 comments on commit 7a2ff38

Please sign in to comment.