diff --git a/projects/apache-httpd/Dockerfile b/projects/apache-httpd/Dockerfile index 3e416d0ef..4acfe8101 100644 --- a/projects/apache-httpd/Dockerfile +++ b/projects/apache-httpd/Dockerfile @@ -15,10 +15,17 @@ ################################################################################ FROM gcr.io/oss-fuzz-base/base-builder -RUN apt-get update && apt-get install -y make autoconf automake libtool wget libpcre3 \ - libpcre3-dev uuid-dev pkg-config libtool-bin \ +RUN apt-get update && apt-get install -y make autoconf automake libtool wget \ + uuid-dev pkg-config libtool-bin \ libbsd-dev +RUN svn co svn://vcs.exim.org/pcre2/code/trunk pcre2 && \ + cd pcre2 && \ + ./autogen.sh && \ + ./configure && \ + make && \ + make install + RUN git clone https://github.com/AdaLogics/fuzz-headers RUN wget https://github.com/libexpat/libexpat/releases/download/R_2_4_1/expat-2.4.1.tar.gz && \ diff --git a/projects/apache-httpd/build.sh b/projects/apache-httpd/build.sh index 28e1695d3..4584bfedb 100755 --- a/projects/apache-httpd/build.sh +++ b/projects/apache-httpd/build.sh @@ -33,6 +33,8 @@ svn checkout https://svn.apache.org/repos/asf/apr/apr/trunk/ srclib/apr ./configure --with-included-apr --enable-pool-debug make +static_pcre=($(find /src/pcre2 -name "libpcre2-8.a")) + # Build the fuzzers for fuzzname in utils parse tokenize addr_parse uri request preq; do $CC $CFLAGS $LIB_FUZZING_ENGINE \ @@ -46,5 +48,5 @@ for fuzzname in utils parse tokenize addr_parse uri request preq; do ./server/mpm/event/.libs/libevent.a \ ./os/unix/.libs/libos.a \ ./srclib/apr/.libs/libapr-2.a \ - -Wl,--end-group -luuid -lpcre -lcrypt -lexpat -l:libbsd.a + -Wl,--end-group -luuid -lcrypt -lexpat -l:libbsd.a ${static_pcre} done