diff options
author | Miklos Szeredi <mszeredi@suse.cz> | 2014-04-01 11:08:43 -0400 |
---|---|---|
committer | Miklos Szeredi <mszeredi@suse.cz> | 2014-04-01 11:08:43 -0400 |
commit | 0b3974eb04c4874e85fa1d4fc70450d12f28611d (patch) | |
tree | 146a9237225aca523fc09c954a8221fd3f080d9a /fs/namei.c | |
parent | 0a7c3937a1f23f8cb5fc77ae01661e9968a51d0c (diff) |
security: add flags to rename hooks
Add flags to security_path_rename() and security_inode_rename() hooks.
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Reviewed-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/namei.c b/fs/namei.c index 0e9d186b7f77..4096d589bb3f 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
@@ -4062,7 +4062,8 @@ int vfs_rename(struct inode *old_dir, struct dentry *old_dentry, | |||
4062 | return error; | 4062 | return error; |
4063 | } | 4063 | } |
4064 | 4064 | ||
4065 | error = security_inode_rename(old_dir, old_dentry, new_dir, new_dentry); | 4065 | error = security_inode_rename(old_dir, old_dentry, new_dir, new_dentry, |
4066 | flags); | ||
4066 | if (error) | 4067 | if (error) |
4067 | return error; | 4068 | return error; |
4068 | 4069 | ||
@@ -4217,7 +4218,7 @@ retry_deleg: | |||
4217 | goto exit5; | 4218 | goto exit5; |
4218 | 4219 | ||
4219 | error = security_path_rename(&oldnd.path, old_dentry, | 4220 | error = security_path_rename(&oldnd.path, old_dentry, |
4220 | &newnd.path, new_dentry); | 4221 | &newnd.path, new_dentry, flags); |
4221 | if (error) | 4222 | if (error) |
4222 | goto exit5; | 4223 | goto exit5; |
4223 | error = vfs_rename(old_dir->d_inode, old_dentry, | 4224 | error = vfs_rename(old_dir->d_inode, old_dentry, |