core: drop incorrect comment about SD_BUS_VTABLE_CAPABILITY(CAP_SYS_BOOT)
The comment about `SD_BUS_VTABLE_CAPABILITY(CAP_SYS_BOOT)` is incorrect. To quote @YHNdnzj: ``` nah, the capability-based permission model is a legacy from kdbus. We cannot do it race-freely without it. Please simply drop the comment. ``` Thanks to @YHNdnzj for suggesting this.
This commit is contained in:
@@ -431,9 +431,6 @@ static int manager_do_set_objective(sd_varlink *link, sd_json_variant *parameter
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
/* dbus uses SD_BUS_VTABLE_CAPABILITY(CAP_SYS_BOOT) in its checking. We cannot do the same
|
||||
* because reading capabilities from /proc is racy (TOCTOU). So we use the stricter check
|
||||
* TODO: figure out a way to check for CAP_SYS_BOOT */
|
||||
r = varlink_check_privileged_peer(link);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
Reference in New Issue
Block a user