mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-15 11:28:08 +00:00
rebase
This commit is contained in:
@ -193,8 +193,8 @@ void load_custom_mutator(afl_state_t *afl, const char *fn) {
|
|||||||
|
|
||||||
/* Initialize the custom mutator */
|
/* Initialize the custom mutator */
|
||||||
if (afl->mutator->afl_custom_init)
|
if (afl->mutator->afl_custom_init)
|
||||||
afl->mutator->data =
|
afl->mutator->data = afl->mutator->afl_custom_init(
|
||||||
afl->mutator->afl_custom_init(afl, rand_below(afl, 0xFFFFFFFF));
|
afl, rand_below(afl, 0xFFFFFFFF));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -895,12 +895,12 @@ test -d ../unicorn_mode/unicornafl && {
|
|||||||
|
|
||||||
$ECHO "$BLUE[*] Testing: custom mutator"
|
$ECHO "$BLUE[*] Testing: custom mutator"
|
||||||
unset AFL_CC # Line 474 sets AFL_CC to "gcc". We reset it to use the default compiler
|
unset AFL_CC # Line 474 sets AFL_CC to "gcc". We reset it to use the default compiler
|
||||||
CUSTOM_MUTATOR_PATH=../examples/custom_mutators
|
CUSTOM_MUTATOR_PATH=$( realpath ../examples/custom_mutators )
|
||||||
test -e test-custom-mutator.c -a -e ${CUSTOM_MUTATOR_PATH}/example.c -a -e ${CUSTOM_MUTATOR_PATH}/example.c && {
|
test -e test-custom-mutator.c -a -e ${CUSTOM_MUTATOR_PATH}/example.c -a -e ${CUSTOM_MUTATOR_PATH}/example.c && {
|
||||||
# Compile the vulnerable program
|
# Compile the vulnerable program
|
||||||
../afl-clang-fast -o test-custom-mutator test-custom-mutator.c
|
../afl-clang-fast -o test-custom-mutator test-custom-mutator.c > /dev/null 2>&1
|
||||||
# Compile the custom mutator
|
# Compile the custom mutator
|
||||||
make -C ../examples/custom_mutators libexamplemutator.so
|
make -C ../examples/custom_mutators libexamplemutator.so > /dev/null 2>&1
|
||||||
test -e test-custom-mutator -a -e ${CUSTOM_MUTATOR_PATH}/libexamplemutator.so && {
|
test -e test-custom-mutator -a -e ${CUSTOM_MUTATOR_PATH}/libexamplemutator.so && {
|
||||||
# Create input directory
|
# Create input directory
|
||||||
mkdir -p in
|
mkdir -p in
|
||||||
|
Reference in New Issue
Block a user