pub struct SmbParser { /* private fields */ }Available on crate feature
smb only.Implementations§
Trait Implementations§
Source§impl SessionParser for SmbParser
impl SessionParser for SmbParser
Source§fn on_gap(
&mut self,
side: FlowSide,
_missing: u64,
_ts: Timestamp,
_out: &mut Vec<SmbMessage>,
) -> GapResponse
Available on crate feature session only.
fn on_gap( &mut self, side: FlowSide, _missing: u64, _ts: Timestamp, _out: &mut Vec<SmbMessage>, ) -> GapResponse
session only.Drop the partial PDU and resume at the next NBSS + SMB header.
Source§type Message = SmbMessage
type Message = SmbMessage
Available on crate feature
session only.L7 message produced by this parser. Read more
Source§fn parser_kind(&self) -> ParserKind
fn parser_kind(&self) -> ParserKind
Available on crate feature
session only.Typed identity of this parser, surfaced on
crate::driver::Event::ParserClosed::parser_kind and
crate::driver::SlotHandle::parser_kind. Lifted from
&'static str to the ParserKind enum in 0.20 (#109);
originally added in 0.5.0. Read moreSource§fn feed_initiator(
&mut self,
bytes: &[u8],
_ts: Timestamp,
out: &mut Vec<Self::Message>,
)
fn feed_initiator( &mut self, bytes: &[u8], _ts: Timestamp, out: &mut Vec<Self::Message>, )
Available on crate feature
session only.Feed the next chunk of bytes from the initiator side.
ts is the observed time of the packet carrying these bytes.
Push any complete messages parsed during this call into
out. Read moreSource§fn feed_responder(
&mut self,
bytes: &[u8],
_ts: Timestamp,
out: &mut Vec<Self::Message>,
)
fn feed_responder( &mut self, bytes: &[u8], _ts: Timestamp, out: &mut Vec<Self::Message>, )
Available on crate feature
session only.Feed the next chunk of bytes from the responder side.
Source§fn fin_initiator(&mut self, _out: &mut Vec<Self::Message>)
fn fin_initiator(&mut self, _out: &mut Vec<Self::Message>)
Available on crate feature
session only.The initiator side ended cleanly: called once at flow end when
the flow ended gracefully (
EndReason::is_graceful: FIN,
idle timeout, force close) or the initiator sent a FIN — after
its final bytes were fed. Not called for a side the parser
stopped reading (GapResponse::StopSide, reassembly stop).
Default: no-op.Source§fn fin_responder(&mut self, _out: &mut Vec<Self::Message>)
fn fin_responder(&mut self, _out: &mut Vec<Self::Message>)
Available on crate feature
session only.The responder side ended cleanly; see
fin_initiator.Source§fn rst_initiator(&mut self)
fn rst_initiator(&mut self)
Available on crate feature
session only.The initiator side ended abruptly: called once at flow end
instead of
fin_initiator when the flow
was not ended gracefully (RST, eviction) and this side sent no
FIN. Not called for a stopped side. Default: no-op.Source§fn rst_responder(&mut self)
fn rst_responder(&mut self)
Available on crate feature
session only.The responder side ended abruptly; see
rst_initiator.Source§fn on_tick(&mut self, _now: Timestamp, _out: &mut Vec<Self::Message>)
fn on_tick(&mut self, _now: Timestamp, _out: &mut Vec<Self::Message>)
Available on crate feature
session only.Periodic time hook. The driver calls this on every
sweep /
finish with the sweep’s now, for every still-live parser.
Lets stateful parsers emit time-driven messages (timeouts,
unanswered requests). Emitted messages are attributed to
FlowSide::Initiator. Default: no-op.Source§fn is_poisoned(&self) -> bool
fn is_poisoned(&self) -> bool
Available on crate feature
session only.True after the parser has hit an unrecoverable error and
can no longer make progress. The engines check this after
every
feed_* / on_gap / on_tick call and close the parser
on true — it is not fed again for that flow, and the flow
itself stays tracked. Default: false (parser never poisons). Read moreSource§fn poison_reason(&self) -> Option<&str>
fn poison_reason(&self) -> Option<&str>
Available on crate feature
session only.Optional human-readable description of why the parser
poisoned. Consulted only when
is_poisoned
returns true. Default: None. Read moreAuto Trait Implementations§
impl Freeze for SmbParser
impl RefUnwindSafe for SmbParser
impl Send for SmbParser
impl Sync for SmbParser
impl Unpin for SmbParser
impl UnsafeUnpin for SmbParser
impl UnwindSafe for SmbParser
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
Mutably borrows from an owned value. Read more