Trait libafl::feedbacks::Feedback [−][src]
pub trait Feedback<I>: Named + Serialize + DeserializeOwned where
I: Input, { fn is_interesting<OT>(
&mut self,
input: &I,
observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error>
where
OT: ObserversTuple; fn append_metadata(
&mut self,
_testcase: &mut Testcase<I>
) -> Result<(), Error> { ... } fn discard_metadata(&mut self, _input: &I) -> Result<(), Error> { ... } }
Feedbacks evaluate the observers. Basically, they reduce the information provided by an observer to a value, indicating the “interestingness” of the last run.
Required methods
fn is_interesting<OT>(
&mut self,
input: &I,
observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
input: &I,
observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
is_interesting
should return the “Interestingness” from 0 to 255 (percent times 2.55)
Provided methods
fn append_metadata(&mut self, _testcase: &mut Testcase<I>) -> Result<(), Error>
[src]
Append to the testcase the generated metadata in case of a new corpus item
fn discard_metadata(&mut self, _input: &I) -> Result<(), Error>
[src]
Discard the stored metadata in case that the testcase is not added to the corpus
Implementations on Foreign Types
impl<I> Feedback<I> for () where
I: Input,
[src]
impl<I> Feedback<I> for () where
I: Input,
[src]Hack to use () as empty Feedback
fn is_interesting<OT>(
&mut self,
_input: &I,
_observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
_input: &I,
_observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
Implementors
impl<A, B, I> Feedback<I> for AndFeedback<A, B, I> where
A: Feedback<I>,
B: Feedback<I>,
I: Input,
[src]
impl<A, B, I> Feedback<I> for AndFeedback<A, B, I> where
A: Feedback<I>,
B: Feedback<I>,
I: Input,
[src]impl<A, B, I> Feedback<I> for OrFeedback<A, B, I> where
A: Feedback<I>,
B: Feedback<I>,
I: Input,
[src]
impl<A, B, I> Feedback<I> for OrFeedback<A, B, I> where
A: Feedback<I>,
B: Feedback<I>,
I: Input,
[src]impl<A, I> Feedback<I> for NotFeedback<A, I> where
A: Feedback<I>,
I: Input,
[src]
impl<A, I> Feedback<I> for NotFeedback<A, I> where
A: Feedback<I>,
I: Input,
[src]impl<I> Feedback<I> for CrashFeedback where
I: Input,
[src]
impl<I> Feedback<I> for CrashFeedback where
I: Input,
[src]fn is_interesting<OT>(
&mut self,
_input: &I,
_observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
_input: &I,
_observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
impl<I> Feedback<I> for TimeFeedback where
I: Input,
[src]
impl<I> Feedback<I> for TimeFeedback where
I: Input,
[src]fn append_metadata(&mut self, testcase: &mut Testcase<I>) -> Result<(), Error>
[src]
fn append_metadata(&mut self, testcase: &mut Testcase<I>) -> Result<(), Error>
[src]Append to the testcase the generated metadata in case of a new corpus item
fn discard_metadata(&mut self, _input: &I) -> Result<(), Error>
[src]
fn discard_metadata(&mut self, _input: &I) -> Result<(), Error>
[src]Discard the stored metadata in case that the testcase is not added to the corpus
fn is_interesting<OT>(
&mut self,
_input: &I,
observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
_input: &I,
observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
impl<I> Feedback<I> for TimeoutFeedback where
I: Input,
[src]
impl<I> Feedback<I> for TimeoutFeedback where
I: Input,
[src]fn is_interesting<OT>(
&mut self,
_input: &I,
_observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
_input: &I,
_observers: &OT,
exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
impl<I, O> Feedback<I> for ReachabilityFeedback<O> where
I: Input,
O: MapObserver<usize>,
[src]
impl<I, O> Feedback<I> for ReachabilityFeedback<O> where
I: Input,
O: MapObserver<usize>,
[src]impl<O, R, T, I> Feedback<I> for MapFeedback<O, R, T> where
T: Integer + Default + Copy + 'static + Serialize + DeserializeOwned,
R: Reducer<T>,
O: MapObserver<T>,
I: Input,
[src]
impl<O, R, T, I> Feedback<I> for MapFeedback<O, R, T> where
T: Integer + Default + Copy + 'static + Serialize + DeserializeOwned,
R: Reducer<T>,
O: MapObserver<T>,
I: Input,
[src]fn discard_metadata(&mut self, _input: &I) -> Result<(), Error>
[src]
fn discard_metadata(&mut self, _input: &I) -> Result<(), Error>
[src]Discard the stored metadata in case that the testcase is not added to the corpus
fn is_interesting<OT>(
&mut self,
_input: &I,
observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,
[src]
&mut self,
_input: &I,
observers: &OT,
_exit_kind: &ExitKind
) -> Result<bool, Error> where
OT: ObserversTuple,