From 476cb7e7dcd424992041dc058483e551486d01d7 Mon Sep 17 00:00:00 2001 From: "Dongjia \"toka\" Zhang" Date: Mon, 26 Dec 2022 14:19:37 +0900 Subject: [PATCH] Frida Makefile.toml fix (#969) * frida build script fix * fix * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml * Update build_and_test.yml --- .github/workflows/build_and_test.yml | 2 +- fuzzers/frida_libpng/Makefile.toml | 7 ++----- libafl/src/bolts/cli.rs | 2 +- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 2834cc1868..80b80a0ef3 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -176,7 +176,7 @@ jobs: - name: Install python # Removing macOS things already installed in CI against failed linking if: runner.os == 'macOS' - run: rm /usr/local/bin/2to3 /usr/local/bin/idle3 /usr/local/bin/pydoc3 /usr/local/bin/python3 /usr/local/bin/python3-config; brew install --force-bottle --overwrite python + run: rm /usr/local/bin/2to3* /usr/local/bin/idle3* /usr/local/bin/pydoc3* /usr/local/bin/python3*; brew install --force-bottle --overwrite python - uses: lyricwulf/abc@v1 with: # todo: remove afl++-clang when nyx support samcov_pcguard diff --git a/fuzzers/frida_libpng/Makefile.toml b/fuzzers/frida_libpng/Makefile.toml index 58c7313b31..8d33b88c62 100644 --- a/fuzzers/frida_libpng/Makefile.toml +++ b/fuzzers/frida_libpng/Makefile.toml @@ -1,10 +1,7 @@ # Variables [env] -CARGO_TARGET_DIR = { value = "${CARGO_MAKE_WORKING_DIRECTORY}${SEP}target", condition = { env_not_set = ["CARGO_TARGET_DIR"] } } -SEP={ source = "${CARGO_MAKE_RUST_TARGET_OS}", default_value = "/", mapping = {"linux" = "/", "macos" = "/", "windows" = "\\"} } +CARGO_TARGET_DIR = { value = "target", condition = { env_not_set = ["CARGO_TARGET_DIR"] } } FUZZER_NAME={ source = "${CARGO_MAKE_RUST_TARGET_OS}", default_value = "frida_fuzzer", mapping = {"linux" = "frida_fuzzer", "macos" = "frida_fuzzer", "windows" = "frida_fuzzer.exe"} } -FUZZER = '${CARGO_TARGET_DIR}${SEP}release${SEP}${FUZZER_NAME}' - [tasks.unsupported] @@ -72,7 +69,7 @@ windows_alias = "fuzzer_windows" script_runner="@shell" script=''' cargo build --release -cp ${CARGO_TARGET_DIR}${SEP}release${SEP}${FUZZER_NAME} . +cp ${CARGO_TARGET_DIR}/release/${FUZZER_NAME} . ''' [tasks.fuzzer_windows] diff --git a/libafl/src/bolts/cli.rs b/libafl/src/bolts/cli.rs index 87be0fa296..c5d26f1373 100644 --- a/libafl/src/bolts/cli.rs +++ b/libafl/src/bolts/cli.rs @@ -282,7 +282,7 @@ pub struct FuzzerOptions { pub cores: Cores, /// port on which the broker should listen - #[arg(short = 'p', long, default_value = "1337", value_name = "PORT")] + #[arg(short = 'p', long, default_value = "31337", value_name = "PORT")] pub broker_port: u16, /// ip:port where a remote broker is already listening