pub struct DelegationPolicy {
pub rules: Vec<(Name, Name)>,
pub allow_new_devices: bool,
}Expand description
A policy based on explicit delegation rules.
Each rule maps a requester name pattern to a set of allowed sub-prefixes.
Fields§
§rules: Vec<(Name, Name)>List of (requester_prefix, allowed_name_prefix) pairs.
allow_new_devices: boolWhether to allow new devices (no cert) to request under any rule’s allowed prefix.
Implementations§
Trait Implementations§
Source§impl Default for DelegationPolicy
impl Default for DelegationPolicy
Source§impl NamespacePolicy for DelegationPolicy
impl NamespacePolicy for DelegationPolicy
Source§fn evaluate(
&self,
requested_name: &Name,
requester_cert: Option<&Certificate>,
_ca_prefix: &Name,
) -> PolicyDecision
fn evaluate( &self, requested_name: &Name, requester_cert: Option<&Certificate>, _ca_prefix: &Name, ) -> PolicyDecision
Evaluate whether
requested_name may be issued to a requester holding
requester_cert (may be None for the first enrollment).Auto Trait Implementations§
impl Freeze for DelegationPolicy
impl RefUnwindSafe for DelegationPolicy
impl Send for DelegationPolicy
impl Sync for DelegationPolicy
impl Unpin for DelegationPolicy
impl UnwindSafe for DelegationPolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more