#[non_exhaustive]pub struct MatchRule {
pub by: String,
pub template: String,
pub pins: Option<String>,
pub domain: Option<String>,
}Expand description
One way to find the account: a template over the claims, and what it renders is.
[[rule]]
by = "filter"
template = "(userPrincipalName={san.upn})"Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.by: StringWhat the rendered text is: name, email or id (the directory attribute it is
looked up by), or filter (an LDAP filter, values escaped).
template: StringText with {claim} and {claim|filter|...} parts; {{ and }} are braces. The
filters are lower, upper, local (before the last @) and domain (after it).
It names at least one claim. Stripping a realm with local loses what ties the name
to it, so such a rule also needs domain or pins.
pins: Option<String>The name of a pin source (given to the builder): the one account this rule finds must also hold one of the certificate’s pins there.
domain: Option<String>The realm a local filter strips: a claim value passed through local counts only
when it ends @<domain> (any case), so alice@evil.example is not alice. A rule
that strips a domain says which, or names pins; one with no local has none.
Implementations§
Trait Implementations§
Source§impl Describe for MatchRule
impl Describe for MatchRule
impl Eq for MatchRule
impl Fields for MatchRule
impl StructuralPartialEq for MatchRule
Auto Trait Implementations§
impl Freeze for MatchRule
impl RefUnwindSafe for MatchRule
impl Send for MatchRule
impl Sync for MatchRule
impl Unpin for MatchRule
impl UnsafeUnpin for MatchRule
impl UnwindSafe for MatchRule
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.