Data Structures | |
| struct | zxfoundation::dgp::cap::cap_token |
| Opaque 64-bit capability token. More... | |
Enumerations | |
| enum class | zxfoundation::dgp::cap::cap_rights : u16 { none = 0 , read = 1U << 0 , write = 1U << 1 , exec = 1U << 2 , destroy = 1U << 3 , delegate = 1U << 4 , admin = 1U << 5 , map = 1U << 6 , all = 0xFFFFU } |
| Standard access rights usable with any capability type. More... | |
| enum class | zxfoundation::dgp::cap::cap_type : u16 { none = 0 , domain = 1 , gate = 2 , portal = 3 , io_device = 5 , memory = 6 , service = 7 , admin = 8 , memory_extent = 9 } |
| Discriminator for the kind of resource a capability token refers to. More... | |
Functions | |
| constexpr | cap_token (u64 v) noexcept |
| constexpr auto | zxfoundation::dgp::cap::cap_type_name (cap_type t) noexcept -> const char * |
| Return a human-readable label for a capability type. | |
| constexpr auto | derive (cap_rights subset) const noexcept -> cap_token |
| Derive a new token with a subset of the rights. | |
| constexpr auto | generation () const noexcept -> u16 |
| Extract the generation field. | |
| constexpr auto | has_right (cap_rights r) const noexcept -> bool |
| Check whether a specific right is present. | |
| static constexpr auto | make (cap_type type, u16 obj_id, u16 gen, cap_rights rights) noexcept -> cap_token |
| Construct a token from its components. | |
| constexpr auto | object_id () const noexcept -> u16 |
| Extract the object ID field. | |
| constexpr | operator bool () const noexcept |
| Check whether the token is valid (non-null). | |
| constexpr auto | operator!= (cap_token o) const noexcept -> bool |
| constexpr auto | zxfoundation::dgp::cap::operator& (cap_rights a, cap_rights b) noexcept -> cap_rights |
| constexpr auto | operator== (cap_token o) const noexcept -> bool |
| Compare two tokens for equality. | |
| constexpr auto | zxfoundation::dgp::cap::operator| (cap_rights a, cap_rights b) noexcept -> cap_rights |
| constexpr auto | zxfoundation::dgp::cap::operator~ (cap_rights r) noexcept -> cap_rights |
| constexpr auto | rights () const noexcept -> cap_rights |
| Extract the rights mask. | |
| constexpr auto | type () const noexcept -> cap_type |
| Extract the type field. | |
Variables | |
| constexpr u64 | zxfoundation::dgp::cap::CAP_ERROR_SENTINEL = ~0ULL |
| Sentinel value indicating an error from capability operations. | |
| constexpr cap_token | zxfoundation::dgp::cap::CAP_TOKEN_NULL {} |
| Null / invalid capability token sentinel. | |
| u64 | raw {0} |
| Raw 64-bit encoding. | |
Files | |
| file | zxfoundation/dgp/cap.zcomponent/types.cxxm |
| Capability system type definitions — opaque resource tokens for the DGP kernel's capability-based authorization model. | |