pub enum PatternMatcher {
Any,
Exact(String),
Prefix(String),
Suffix(String),
}Expand description
Pre-compiled pattern matcher for tool/function ID segments.
SECURITY (FIND-SEM-003, R227-TYP-1): Pattern strings are normalized through
normalize_full() (NFKC + lowercase + homoglyph mapping) at compile time.
This prevents fullwidth Unicode, circled letters, and mathematical variants
from bypassing exact-match Deny policies. The evaluation path must also
normalize action tool/function names via normalize_full() before matching.
Variants§
Any
Matches anything (“*”)
Exact(String)
Exact string match (pattern is homoglyph-normalized at compile time)
Prefix(String)
Prefix match (“prefix*”) (normalize_full at compile time)
Suffix(String)
Suffix match (“*suffix”) (normalize_full at compile time)
Trait Implementations§
Source§impl Clone for PatternMatcher
impl Clone for PatternMatcher
Source§fn clone(&self) -> PatternMatcher
fn clone(&self) -> PatternMatcher
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for PatternMatcher
impl RefUnwindSafe for PatternMatcher
impl Send for PatternMatcher
impl Sync for PatternMatcher
impl Unpin for PatternMatcher
impl UnsafeUnpin for PatternMatcher
impl UnwindSafe for PatternMatcher
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