Struct libafl::executors::inprocess::InProcessExecutor[][src]

pub struct InProcessExecutor<'a, H, I, OT> where
    H: FnMut(&[u8]) -> ExitKind,
    I: Input + HasTargetBytes,
    OT: ObserversTuple
{ /* fields omitted */ }

The inmem executor simply calls a target function, then returns afterwards.

Implementations

impl<'a, H, I, OT> InProcessExecutor<'a, H, I, OT> where
    H: FnMut(&[u8]) -> ExitKind,
    I: Input + HasTargetBytes,
    OT: ObserversTuple
[src]

pub fn new<EM, OC, OFT, S>(
    name: &'static str,
    harness_fn: &'a mut H,
    observers: OT,
    _state: &mut S,
    _event_mgr: &mut EM
) -> Result<Self, Error> where
    EM: EventManager<I, S>,
    OC: Corpus<I>,
    OFT: FeedbacksTuple<I>,
    S: HasObjectives<OFT, I> + HasSolutions<OC, I>, 
[src]

Create a new in mem executor. Caution: crash and restart in one of them will lead to odd behavior if multiple are used, depending on different corpus or state.

  • name - the name of this executor (to address it along the way)
  • harness_fn - the harness, executiong the function
  • observers - the observers observing the target during execution This may return an error on unix, if signal handler setup fails

pub fn harness(&self) -> &H[src]

Retrieve the harness function.

pub fn harness_mut(&mut self) -> &mut H[src]

Retrieve the harness function for a mutable reference.

Trait Implementations

impl<'a, H, I, OT> Executor<I> for InProcessExecutor<'a, H, I, OT> where
    H: FnMut(&[u8]) -> ExitKind,
    I: Input + HasTargetBytes,
    OT: ObserversTuple
[src]

impl<'a, H, I, OT> HasObservers<OT> for InProcessExecutor<'a, H, I, OT> where
    H: FnMut(&[u8]) -> ExitKind,
    I: Input + HasTargetBytes,
    OT: ObserversTuple
[src]

impl<'a, H, I, OT> Named for InProcessExecutor<'a, H, I, OT> where
    H: FnMut(&[u8]) -> ExitKind,
    I: Input + HasTargetBytes,
    OT: ObserversTuple
[src]

Auto Trait Implementations

impl<'a, H, I, OT> RefUnwindSafe for InProcessExecutor<'a, H, I, OT> where
    H: RefUnwindSafe,
    I: RefUnwindSafe,
    OT: RefUnwindSafe

impl<'a, H, I, OT> Send for InProcessExecutor<'a, H, I, OT> where
    H: Send,
    I: Send,
    OT: Send

impl<'a, H, I, OT> Sync for InProcessExecutor<'a, H, I, OT> where
    H: Sync,
    I: Sync,
    OT: Sync

impl<'a, H, I, OT> Unpin for InProcessExecutor<'a, H, I, OT> where
    I: Unpin,
    OT: Unpin

impl<'a, H, I, OT> !UnwindSafe for InProcessExecutor<'a, H, I, OT>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.