summaryrefslogtreecommitdiff
path: root/security/apparmor/file.c
diff options
context:
space:
mode:
authorJohn Johansen <john.johansen@canonical.com>2017-05-22 13:06:52 +0300
committerJohn Johansen <john.johansen@canonical.com>2017-06-08 21:29:34 +0300
commit72c8a768641dc6ee8d1d9dcebd51bbec2817459b (patch)
treed0153542d088beddf662ffaeff25017c970093b7 /security/apparmor/file.c
parentb91deb9db12851c18ccb55719f1cd55c2400aca1 (diff)
downloadlinux-72c8a768641dc6ee8d1d9dcebd51bbec2817459b.tar.xz
apparmor: allow profiles to provide info to disconnected paths
Signed-off-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'security/apparmor/file.c')
-rw-r--r--security/apparmor/file.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/security/apparmor/file.c b/security/apparmor/file.c
index 750564c3ab71..83d43ac72134 100644
--- a/security/apparmor/file.c
+++ b/security/apparmor/file.c
@@ -285,7 +285,8 @@ int aa_path_perm(const char *op, struct aa_profile *profile,
int error;
flags |= profile->path_flags | (S_ISDIR(cond->mode) ? PATH_IS_DIR : 0);
- error = aa_path_name(path, flags, &buffer, &name, &info);
+ error = aa_path_name(path, flags, &buffer, &name, &info,
+ profile->disconnected);
if (error) {
if (error == -ENOENT && is_deleted(path->dentry)) {
/* Access to open files that are deleted are
@@ -366,13 +367,13 @@ int aa_path_link(struct aa_profile *profile, struct dentry *old_dentry,
/* buffer freed below, lname is pointer in buffer */
error = aa_path_name(&link, profile->path_flags, &buffer, &lname,
- &info);
+ &info, profile->disconnected);
if (error)
goto audit;
/* buffer2 freed below, tname is pointer in buffer2 */
error = aa_path_name(&target, profile->path_flags, &buffer2, &tname,
- &info);
+ &info, profile->disconnected);
if (error)
goto audit;