From 4e5eafa37849062dcfa48155fe91dc8d733dbc81 Mon Sep 17 00:00:00 2001 From: Alexandru Geana Date: Tue, 31 Oct 2023 12:52:58 +0100 Subject: [PATCH] Fuzzing: initial build and fuzz workflow --- .github/workflows/build_and_fuzz.yml | 31 ++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/build_and_fuzz.yml diff --git a/.github/workflows/build_and_fuzz.yml b/.github/workflows/build_and_fuzz.yml new file mode 100644 index 00000000..b1ed7fd2 --- /dev/null +++ b/.github/workflows/build_and_fuzz.yml @@ -0,0 +1,31 @@ +name: Build and Fuzz + +on: [push, pull_request] + +jobs: + fuzz_msan: + name: fuzz with MemorySanitizer + runs-on: ubuntu-latest + container: ghcr.io/yubico/yubihsm-shell/fuzzing-msan:latest + + steps: + + - name: clone the Yubico/yubihsm-shell repository + uses: actions/checkout@v3 + with: + path: yubihsm-shell + + - name: do build + working-directory: yubihsm-shell + env: + CC: ${{ matrix.cc }} + VERBOSE: 1 + run: | + cmake \ + -DFUZZING=ON \ + -DFUZZING_MSAN=ON \ + -DWITHOUT_MANPAGES=ON \ + -DDISABLE_LTO=ON \ + -DENABLE_STATIC=ON \ + -B build-msan + cmake --build build-msan