pub enum ExtensionTrustState {
Quarantined,
Restricted,
Trusted,
}Expand description
Extension trust lifecycle states.
The trust lifecycle is a strict state machine:
Quarantined→Restricted(via promotion with operator acknowledgment)Restricted→Trusted(via promotion with operator acknowledgment)Trusted→Quarantined(via demotion, immediate)Restricted→Quarantined(via demotion, immediate)
Transitions always require an explicit reason and produce an audit event.
Variants§
Quarantined
Extension is fully quarantined: no dangerous hostcalls permitted.
Default state for extensions with Block or Review install
recommendations.
Restricted
Extension may execute read-only hostcalls but not write, exec, or network operations. Intermediate state requiring a second promotion to reach full trust.
Trusted
Extension is fully trusted and may exercise all policy-allowed capabilities.
Implementations§
Source§impl ExtensionTrustState
impl ExtensionTrustState
Sourcepub const fn allows_dangerous_hostcalls(self) -> bool
pub const fn allows_dangerous_hostcalls(self) -> bool
Whether the extension may execute dangerous hostcalls (write, exec, network, env).
Sourcepub const fn allows_read_hostcalls(self) -> bool
pub const fn allows_read_hostcalls(self) -> bool
Whether the extension may execute read-only hostcalls (read, list, stat, tool registration).
Sourcepub const fn is_quarantined(self) -> bool
pub const fn is_quarantined(self) -> bool
Whether the extension is in quarantine and cannot execute any hostcalls beyond registration.
Trait Implementations§
Source§impl Clone for ExtensionTrustState
impl Clone for ExtensionTrustState
Source§fn clone(&self) -> ExtensionTrustState
fn clone(&self) -> ExtensionTrustState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ExtensionTrustState
impl Debug for ExtensionTrustState
Source§impl<'de> Deserialize<'de> for ExtensionTrustState
impl<'de> Deserialize<'de> for ExtensionTrustState
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>,
Source§impl Display for ExtensionTrustState
impl Display for ExtensionTrustState
Source§impl Hash for ExtensionTrustState
impl Hash for ExtensionTrustState
Source§impl Ord for ExtensionTrustState
impl Ord for ExtensionTrustState
Source§fn cmp(&self, other: &ExtensionTrustState) -> Ordering
fn cmp(&self, other: &ExtensionTrustState) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for ExtensionTrustState
impl PartialEq for ExtensionTrustState
Source§impl PartialOrd for ExtensionTrustState
impl PartialOrd for ExtensionTrustState
Source§impl Serialize for ExtensionTrustState
impl Serialize for ExtensionTrustState
impl Copy for ExtensionTrustState
impl Eq for ExtensionTrustState
impl StructuralPartialEq for ExtensionTrustState
Auto Trait Implementations§
impl Freeze for ExtensionTrustState
impl RefUnwindSafe for ExtensionTrustState
impl Send for ExtensionTrustState
impl Sync for ExtensionTrustState
impl Unpin for ExtensionTrustState
impl UnsafeUnpin for ExtensionTrustState
impl UnwindSafe for ExtensionTrustState
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, _span: NoopSpan) -> Self
fn instrument(self, _span: NoopSpan) -> Self
Source§fn in_current_span(self) -> Self
fn in_current_span(self) -> Self
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> ModelDump for Twhere
T: Serialize,
impl<T> ModelDump for Twhere
T: Serialize,
Source§fn model_dump(&self, options: DumpOptions) -> Result<Value, Error>
fn model_dump(&self, options: DumpOptions) -> Result<Value, Error>
Source§fn model_dump_json(&self) -> Result<String, Error>
fn model_dump_json(&self) -> Result<String, Error>
Source§fn model_dump_json_pretty(&self) -> Result<String, Error>
fn model_dump_json_pretty(&self) -> Result<String, Error>
Source§fn model_dump_json_with_options(
&self,
options: DumpOptions,
) -> Result<String, Error>
fn model_dump_json_with_options( &self, options: DumpOptions, ) -> Result<String, Error>
Source§impl<T> ModelValidate for Twhere
T: DeserializeOwned,
impl<T> ModelValidate for Twhere
T: DeserializeOwned,
Source§fn model_validate(
input: impl Into<ValidateInput>,
options: ValidateOptions,
) -> Result<T, ValidationError>
fn model_validate( input: impl Into<ValidateInput>, options: ValidateOptions, ) -> Result<T, ValidationError>
Source§fn model_validate_json(json: &str) -> Result<Self, ValidationError>
fn model_validate_json(json: &str) -> Result<Self, ValidationError>
Source§fn model_validate_dict(
dict: HashMap<String, Value>,
) -> Result<Self, ValidationError>
fn model_validate_dict( dict: HashMap<String, Value>, ) -> Result<Self, ValidationError>
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
CompactString. Read more