pub struct OobSession { /* private fields */ }Expand description
Engine-shared OOB session. Wrap in Arc and share across verify tasks.
Implementations§
Source§impl OobSession
impl OobSession
Sourcepub async fn start(
http: Client,
config: OobConfig,
) -> Result<Arc<Self>, InteractshError>
pub async fn start( http: Client, config: OobConfig, ) -> Result<Arc<Self>, InteractshError>
Boot the session: register with the collector and spawn the poller. Errors here are surface-level — caller logs and continues with OOB disabled rather than aborting the scan.
Sourcepub fn mint(&self) -> MintedUrl
pub fn mint(&self) -> MintedUrl
Mint a URL for a finding-in-flight. Returns the host and full URL the
caller should embed in the verification probe, plus the unique_id
to pass to wait_for.
Sourcepub fn config_default_timeout(&self) -> Duration
pub fn config_default_timeout(&self) -> Duration
Default per-finding wait timeout. Detector specs override this via
[detector.verify.oob].timeout_secs; the value is also clamped to
max_timeout inside wait_for.
Sourcepub async fn wait_for(
&self,
unique_id: &str,
accepts: OobAccept,
timeout: Duration,
) -> OobObservation
pub async fn wait_for( &self, unique_id: &str, accepts: OobAccept, timeout: Duration, ) -> OobObservation
Park until an interaction arrives for unique_id, or timeout
elapses, or shutdown — whichever comes first.
Sourcepub async fn shutdown(self: &Arc<Self>)
pub async fn shutdown(self: &Arc<Self>)
Best-effort shutdown: stop poller, wake parked waiters, deregister. Idempotent.
Sourcepub fn abort_poller_for_drop(&self)
pub fn abort_poller_for_drop(&self)
Synchronous abort path used from VerificationEngine::Drop when the
caller forgot to shutdown_oob().await. We can’t await deregister
from a sync context, so we just stop the poller and wake every
parked wait_for so they observe shutdown=true and return
Disabled instead of sleeping the rest of their per-finding
timeout. The collector prunes inactive sessions on its own
retention timer.
Idempotent. Once called, subsequent wait_for invocations return
Disabled("session shut down").
Auto Trait Implementations§
impl !Freeze for OobSession
impl !RefUnwindSafe for OobSession
impl Send for OobSession
impl Sync for OobSession
impl Unpin for OobSession
impl UnsafeUnpin for OobSession
impl !UnwindSafe for OobSession
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
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 more