Skip to content

Commit

Permalink
feat: add fuzz test target to makefile and security with wget
Browse files Browse the repository at this point in the history
Signed-off-by: Valina Li <[email protected]>
  • Loading branch information
vli11 committed Aug 14, 2023
1 parent 902a216 commit 3ce158a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Dockerfile.fuzz
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM mcr.microsoft.com/dotnet/sdk:6.0-alpine as builder

RUN apk add --no-cache python3 py3-pip bash coreutils

RUN wget https://github.com/microsoft/restler-fuzzer/archive/refs/tags/v9.2.2.tar.gz
RUN wget -q "https://github.com/microsoft/restler-fuzzer/archive/refs/tags/v9.2.2.tar.gz"
RUN tar -xvf v9.2.2.tar.gz && mv restler-fuzzer-9.2.2 restler-fuzzer

RUN cd restler-fuzzer; mkdir -p restler_bin
Expand Down
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# SPDX-License-Identifier: Apache-2.0
#

.PHONY: build clean unittest hadolint lint test docker run sbom
.PHONY: build clean unittest hadolint lint test docker run sbom build-fuzz-test run-fuzz-test

# change the following boolean flag to include or exclude the delayed start libs for builds for most of core services except support services
INCLUDE_DELAYED_START_BUILD_CORE:="false"
Expand Down Expand Up @@ -367,3 +367,9 @@ sbom:
docker run -it --rm \
-v "$$PWD:/edgex-go" -v "$$PWD/sbom:/sbom" \
spdx/spdx-sbom-generator -p /edgex-go/ -o /sbom/ --include-license-text true

build-fuzz-test:
docker build -f Dockerfile.fuzz -t fuzz-edgex-go:latest .

run-fuzz-test:
docker run --net host -v $(pwd)/fuzz_results:/fuzz_results fuzz-edgex-go:latest

0 comments on commit 3ce158a

Please sign in to comment.