[Devel] [PATCH RHEL7 COMMIT] ve/fs/namei: fix capabilities check in sys_renameat2 () to support Containers

Konstantin Khorenko khorenko at virtuozzo.com
Wed Oct 28 07:22:04 PDT 2015


The commit is pushed to "branch-rh7-3.10.0-229.7.2.vz7.9.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-229.7.2.vz7.9.3
------>
commit 564e9193ba6c9ef8bc4d92848c249db3caddf363
Author: Stanislav Kinsburskiy <skinsbursky at virtuozzo.com>
Date:   Wed Oct 28 18:22:04 2015 +0400

    ve/fs/namei: fix capabilities check in sys_renameat2 () to support Containers
    
    Signed-off-by: Stanislav Kinsburskiy <skinsbursky at virtuozzo.com>
---
 fs/namei.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/namei.c b/fs/namei.c
index d3430ee..42224e6 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -4212,7 +4212,7 @@ SYSCALL_DEFINE5(renameat2, int, olddfd, const char __user *, oldname,
 	    (flags & RENAME_EXCHANGE))
 		return -EINVAL;
 
-	if ((flags & RENAME_WHITEOUT) && !capable(CAP_MKNOD))
+	if ((flags & RENAME_WHITEOUT) && !ve_capable(CAP_MKNOD))
 		return -EPERM;
 
 retry:



More information about the Devel mailing list