dwrensha / seer

symbolic execution engine for Rust
Other
350 stars 7 forks source link

Anyway to use Seer for concolic testing? #5

Open minhnhdo opened 6 years ago

minhnhdo commented 6 years ago

Hi, I'd like to use seer for concolic testing. However, the examples are all code with main functions, and do not show how to hook into the engine for extension. I'd like to run concolic testing on library functions rather than whole programs. Could you please give me some pointers on how to achieve this?

dwrensha commented 6 years ago

I'd like to run concolic testing on library functions rather than whole programs.

Seer's logic for choosing what code to execute is here: https://github.com/dwrensha/seer/blob/0b67693be6386ff6078c4bd46b4045617b7386f2/src/driver.rs#L71

We could add the ability to run functions that have a certain attribute. E.g. Miri has the ability to run functions that are marked #[test]: https://github.com/solson/miri/blob/919604e1ead8294c8ca14f101be4380ea1ea370c/miri/bin/miri.rs#L110-L124