Skip to content

Commit

Permalink
TOMOYO: Don't add / for allow_unmount permission check.
Browse files Browse the repository at this point in the history
"mount --bind /path/to/file1 /path/to/file2" is legal. Therefore,
"umount /path/to/file2" is also legal. Do not automatically append trailing '/'
if pathname to be unmounted does not end with '/'.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Signed-off-by: James Morris <jmorris@namei.org>
  • Loading branch information
Tetsuo Handa authored and James Morris committed Apr 18, 2011
1 parent 2a086e5 commit e4f5f26
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion security/tomoyo/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -1011,7 +1011,6 @@ int tomoyo_path_perm(const u8 operation, struct path *path)
break;
case TOMOYO_TYPE_RMDIR:
case TOMOYO_TYPE_CHROOT:
case TOMOYO_TYPE_UMOUNT:
tomoyo_add_slash(&buf);
break;
}
Expand Down

0 comments on commit e4f5f26

Please sign in to comment.