diff --git a/projects/hiredis/Dockerfile b/projects/hiredis/Dockerfile new file mode 100644 index 000000000..616330f49 --- /dev/null +++ b/projects/hiredis/Dockerfile @@ -0,0 +1,20 @@ +# Copyright 2018 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +################################################################################ + +FROM gcr.io/oss-fuzz-base/base-builder +RUN git clone --depth 1 https://github.com/redis/hiredis +WORKDIR hiredis +COPY build.sh $SRC/ diff --git a/projects/hiredis/build.sh b/projects/hiredis/build.sh new file mode 100755 index 000000000..9159e8d18 --- /dev/null +++ b/projects/hiredis/build.sh @@ -0,0 +1,25 @@ +#!/bin/bash -eu +# Copyright 2020 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +################################################################################ + +make USE_SSL=0 +mv fuzzing/format_command_fuzzer.c . + +$CC $CFLAGS -std=c99 -pedantic -c -O3 -fPIC \ + format_command_fuzzer.c -o format_command_fuzzer.o + +$CC $CFLAGS -O3 -fPIC $LIB_FUZZING_ENGINE format_command_fuzzer.o \ + -o $OUT/format_command_fuzzer libhiredis.a diff --git a/projects/hiredis/project.yaml b/projects/hiredis/project.yaml new file mode 100755 index 000000000..9264b769a --- /dev/null +++ b/projects/hiredis/project.yaml @@ -0,0 +1,9 @@ +homepage: "https://github.com/redis/hiredis" +primary_contact: "michael.grunder@gmail.com" +language: c +fuzzing_engines: + - libfuzzer + - honggfuzz +auto_ccs: + - "Adam@adalogics.com" +main_repo: "https://github.com/redis/hiredis"