pub struct LogSanitizer { /* private fields */ }
Expand description
Log sanitizer for removing sensitive information
Implementations§
Source§impl LogSanitizer
impl LogSanitizer
Sourcepub fn with_config(config: SanitizationConfig) -> Self
pub fn with_config(config: SanitizationConfig) -> Self
Create a new log sanitizer with custom configuration
Sourcepub fn sanitize(&self, message: &str) -> String
pub fn sanitize(&self, message: &str) -> String
Sanitize a log message by removing or redacting sensitive information
Sourcepub fn sanitize_error(&self, error: &dyn Error) -> String
pub fn sanitize_error(&self, error: &dyn Error) -> String
Sanitize error messages for production logging
Sourcepub fn sanitize_context(&self, context: &Value) -> Value
pub fn sanitize_context(&self, context: &Value) -> Value
Create a sanitized version of structured logging context
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LogSanitizer
impl RefUnwindSafe for LogSanitizer
impl Send for LogSanitizer
impl Sync for LogSanitizer
impl Unpin for LogSanitizer
impl UnwindSafe for LogSanitizer
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