config: cached user info: expose new any_privs_below
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
0bed1f2956
commit
2c69b69108
|
@ -179,6 +179,16 @@ impl CachedUserInfo {
|
||||||
|
|
||||||
(privs, propagated_privs)
|
(privs, propagated_privs)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Checks whether the `auth_id` has any of the privilegs `privs` on any object below `path`.
|
||||||
|
pub fn any_privs_below(
|
||||||
|
&self,
|
||||||
|
auth_id: &Authid,
|
||||||
|
path: &[&str],
|
||||||
|
privs: u64,
|
||||||
|
) -> Result<bool, Error> {
|
||||||
|
self.acl_tree.any_privs_below(auth_id, path, privs)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl UserInformation for CachedUserInfo {
|
impl UserInformation for CachedUserInfo {
|
||||||
|
|
Loading…
Reference in New Issue