pub struct SiemLog { /* private fields */ }
Expand description
This is a simple log event. It contains information about the asset that generated this log, the client if we are working in a multi-client environments aka SOC, some fields to facilitate correlation with SIGMA rules, timestamps and tags to better describe the content inside.
Implementations
sourceimpl<'a> SiemLog
impl<'a> SiemLog
pub fn new<S, M>(message: M, received: i64, origin: S) -> SiemLog where
S: Into<Cow<'static, str>>,
M: Into<String>,
pub fn message(&'a self) -> &'a str
pub fn origin(&'a self) -> &'a str
pub fn tenant(&'a self) -> &'a str
pub fn set_tenant<S>(&mut self, tenant: S) where
S: Into<Cow<'static, str>>,
pub fn product(&'a self) -> &'a str
pub fn set_product<S>(&mut self, product: S) where
S: Into<Cow<'static, str>>,
pub fn service(&'a self) -> &'a str
pub fn set_service<S>(&mut self, service: S) where
S: Into<Cow<'static, str>>,
pub fn category(&'a self) -> &'a str
pub fn set_category<S>(&mut self, category: S) where
S: Into<Cow<'static, str>>,
pub fn vendor(&'a self) -> &'a str
pub fn set_vendor<S>(&mut self, vendor: S) where
S: Into<Cow<'static, str>>,
pub fn event_received(&'a self) -> i64
pub fn event_created(&'a self) -> i64
pub fn set_event_created(&mut self, date: i64)
pub fn has_tag(&self, tag: &str) -> bool
pub fn add_tag(&mut self, tag: &str)
pub fn field(&'a self, field_name: &str) -> Option<&SiemField>
pub fn add_field(&mut self, field_name: &str, field_value: SiemField)
pub fn has_field(&self, field_name: &str) -> bool
pub fn event(&self) -> &SiemEvent
pub fn set_event(&mut self, event: SiemEvent)
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for SiemLog
impl Send for SiemLog
impl Sync for SiemLog
impl Unpin for SiemLog
impl UnwindSafe for SiemLog
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more