pub struct WebMcpSecurityPolicy {
pub allowed_origins: Vec<String>,
pub required_scopes: Vec<String>,
pub max_tokens_per_call: Option<u64>,
pub audit_logging: bool,
pub sandbox_mode: WebMcpSandboxMode,
}Expand description
Security policy governing WebMCP tool access.
Aligns with CELLSTATE’s intent system: the security policy determines which tools an agent can auto-execute vs. which require approval, mapping to the AutonomyLevel and DelegationBoundary primitives.
Fields§
§allowed_origins: Vec<String>Allowed origin patterns (e.g., “https://*.example.com”).
required_scopes: Vec<String>OAuth 2.1 scopes required for tool execution.
max_tokens_per_call: Option<u64>Maximum token budget per tool execution.
audit_logging: boolWhether to enforce audit logging for all tool calls.
sandbox_mode: WebMcpSandboxModeSandbox mode for tool execution.
Trait Implementations§
Source§impl Clone for WebMcpSecurityPolicy
impl Clone for WebMcpSecurityPolicy
Source§fn clone(&self) -> WebMcpSecurityPolicy
fn clone(&self) -> WebMcpSecurityPolicy
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 moreSource§impl ComposeSchema for WebMcpSecurityPolicy
impl ComposeSchema for WebMcpSecurityPolicy
Source§impl Debug for WebMcpSecurityPolicy
impl Debug for WebMcpSecurityPolicy
Source§impl<'de> Deserialize<'de> for WebMcpSecurityPolicy
impl<'de> Deserialize<'de> for WebMcpSecurityPolicy
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for WebMcpSecurityPolicy
impl PartialEq for WebMcpSecurityPolicy
Source§impl Serialize for WebMcpSecurityPolicy
impl Serialize for WebMcpSecurityPolicy
Source§impl ToSchema for WebMcpSecurityPolicy
impl ToSchema for WebMcpSecurityPolicy
impl StructuralPartialEq for WebMcpSecurityPolicy
Auto Trait Implementations§
impl Freeze for WebMcpSecurityPolicy
impl RefUnwindSafe for WebMcpSecurityPolicy
impl Send for WebMcpSecurityPolicy
impl Sync for WebMcpSecurityPolicy
impl Unpin for WebMcpSecurityPolicy
impl UnwindSafe for WebMcpSecurityPolicy
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