From 337d3df6665fdced8b2c8e41f77ce5ef27855e84 Mon Sep 17 00:00:00 2001 From: higuruchi Date: Thu, 17 Nov 2022 06:33:19 +0000 Subject: [PATCH] Fixed set capability fail. Signed-off-by: higuruchi --- crates/libcontainer/src/syscall/linux.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/libcontainer/src/syscall/linux.rs b/crates/libcontainer/src/syscall/linux.rs index 1602c6f44..4f06e88e5 100644 --- a/crates/libcontainer/src/syscall/linux.rs +++ b/crates/libcontainer/src/syscall/linux.rs @@ -174,7 +174,7 @@ impl Syscall for LinuxSyscall { // so we do it differently CapSet::Bounding => { // get all capabilities - let all = caps::all(); + let all = caps::read(None, CapSet::Bounding)?; // the difference will give capabilities // which are to be unset // for each such =, drop that capability