diff options
author | Guido Vranken <guidovranken@users.noreply.github.com> | 2020-03-04 15:02:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-04 06:02:31 -0800 |
commit | f669d3e9f6f2afcc546335f43e60cfeccd5a4ae1 (patch) | |
tree | 38fa9c1c0256e3d96c187432198db64c2f39409d /projects/cryptofuzz | |
parent | 3a6104700b1b99f9a44c0354f202db00c7f623a1 (diff) | |
download | oss-fuzz-f669d3e9f6f2afcc546335f43e60cfeccd5a4ae1.tar.gz |
[cryptofuzz] Fix NSS coverage (#3459)
Diffstat (limited to 'projects/cryptofuzz')
-rw-r--r-- | projects/cryptofuzz/Dockerfile | 1 | ||||
-rwxr-xr-x | projects/cryptofuzz/build.sh | 12 |
2 files changed, 4 insertions, 9 deletions
diff --git a/projects/cryptofuzz/Dockerfile b/projects/cryptofuzz/Dockerfile index 1629cecd9..ec94d4a9f 100644 --- a/projects/cryptofuzz/Dockerfile +++ b/projects/cryptofuzz/Dockerfile @@ -42,5 +42,6 @@ RUN git clone --depth 1 https://github.com/ARMmbed/mbed-crypto.git RUN hg clone https://hg.mozilla.org/projects/nspr RUN hg clone https://hg.mozilla.org/projects/nss RUN apt-get remove -y libunwind8 +RUN apt-get install -y libssl-dev COPY build.sh $SRC/ diff --git a/projects/cryptofuzz/build.sh b/projects/cryptofuzz/build.sh index 053ff4c47..621fbfb6b 100755 --- a/projects/cryptofuzz/build.sh +++ b/projects/cryptofuzz/build.sh @@ -67,15 +67,9 @@ then mv $SRC/nss $SRC/nss-nspr/ mv $SRC/nspr $SRC/nss-nspr/ cd $SRC/nss-nspr/ - if [[ $CFLAGS = *sanitize=address* ]] - then - CFLAGS="" CXXFLAGS="" nss/build.sh --asan --static - elif [[ $CFLAGS = *sanitize=memory* ]] - then - CFLAGS="" CXXFLAGS="" nss/build.sh --msan --static - else - CFLAGS="" CXXFLAGS="" nss/build.sh --ubsan --static - fi + + CXX="$CXX -stdlib=libc++" LDFLAGS="$CFLAGS" nss/build.sh --enable-fips --static --disable-tests --fuzz=oss + export NSS_NSPR_PATH=$(realpath $SRC/nss-nspr/) export CXXFLAGS="$CXXFLAGS -DCRYPTOFUZZ_NSS" export LINK_FLAGS="$LINK_FLAGS -lsqlite3" |