pub struct PluginValidator {
pub max_memory: usize,
pub strict_signatures: bool,
pub enforce_sandbox: bool,
}Expand description
Plugin validator for security and compatibility checks
Fields§
§max_memory: usizeMaximum memory usage in bytes
strict_signatures: boolWhether to enforce strict signature checks
enforce_sandbox: boolWhether to enforce sandboxing
Implementations§
Source§impl PluginValidator
impl PluginValidator
Sourcepub fn with_max_memory(self, max_bytes: usize) -> Self
pub fn with_max_memory(self, max_bytes: usize) -> Self
Set maximum allowed memory usage
Sourcepub fn with_strict_signatures(self, strict: bool) -> Self
pub fn with_strict_signatures(self, strict: bool) -> Self
Set whether to enforce strict signature verification
Sourcepub fn with_sandbox(self, enforce: bool) -> Self
pub fn with_sandbox(self, enforce: bool) -> Self
Set whether to enforce sandbox constraints
Sourcepub async fn validate_plugin(
&self,
binary_path: &Path,
metadata: &PluginMetadata,
) -> Result<(), ValidationError>
pub async fn validate_plugin( &self, binary_path: &Path, metadata: &PluginMetadata, ) -> Result<(), ValidationError>
Validate a plugin binary and its metadata
Trait Implementations§
Source§impl Debug for PluginValidator
impl Debug for PluginValidator
Auto Trait Implementations§
impl Freeze for PluginValidator
impl RefUnwindSafe for PluginValidator
impl Send for PluginValidator
impl Sync for PluginValidator
impl Unpin for PluginValidator
impl UnwindSafe for PluginValidator
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