Module caps::runtime

source ·
Expand description

Detect kernel features at runtime.

This module exposes methods to perform detection of kernel features at runtime. This allows applications to auto-detect whether recent options are implemented by the currently running kernel.

Example

let ambient = caps::runtime::ambient_set_supported().is_ok();
println!("Supported ambient set: {}", ambient);

let all = caps::runtime::procfs_all_supported(None)
    .unwrap_or_else(|_| caps::runtime::thread_all_supported());
println!("Supported capabilities: {}", all.len());

!

Functions

Check whether the running kernel supports the ambient set.
Return the set of all capabilities supported by the running kernel.
Return the set of all capabilities supported on the current thread.