diff --git a/projects/apache-httpd/Dockerfile b/projects/apache-httpd/Dockerfile index 4acfe8101..7fe951bb2 100644 --- a/projects/apache-httpd/Dockerfile +++ b/projects/apache-httpd/Dockerfile @@ -39,4 +39,3 @@ RUN git clone --depth=1 https://github.com/apache/httpd WORKDIR httpd COPY build.sh $SRC/ COPY fuzz_*.c $SRC/ -#COPY patches.diff $SRC/ diff --git a/projects/apache-httpd/build.sh b/projects/apache-httpd/build.sh index 4584bfedb..d56d7ff6a 100755 --- a/projects/apache-httpd/build.sh +++ b/projects/apache-httpd/build.sh @@ -19,12 +19,6 @@ unset CPP unset CXX export LDFLAGS="-l:libbsd.a" -# We used to patch out assert statements. But since https://github.com/apache/httpd/commit/a6e5a92b0d0e74ead5a43f20f81f5cf880ea4fb8 -# This does not seem to be relevant anymore. -# I will keep the lines and let the fuzzers runs for a while, then remove the patch entirely -# if it proves no longer needed. -#git apply --ignore-space-change --ignore-whitespace $SRC/patches.diff - # Download apr and place in httpd srclib folder. Apr-2.0 includes apr-utils svn checkout https://svn.apache.org/repos/asf/apr/apr/trunk/ srclib/apr diff --git a/projects/apache-httpd/patches.diff b/projects/apache-httpd/patches.diff deleted file mode 100644 index d93b12b98..000000000 --- a/projects/apache-httpd/patches.diff +++ /dev/null @@ -1,44 +0,0 @@ -diff --git a/server/apreq_parser_header.c b/server/apreq_parser_header.c -index 19588be..7067e58 100644 ---- a/server/apreq_parser_header.c -+++ b/server/apreq_parser_header.c -@@ -89,7 +89,7 @@ static apr_status_t split_header_line(apreq_param_t **p, - if (s != APR_SUCCESS) - return s; - -- assert(nlen >= len); -+ if (!(nlen >= len)) { return APR_EBADARG; } assert(nlen >= len); - end->iov_len = len; - nlen -= len; - -@@ -103,13 +103,13 @@ static apr_status_t split_header_line(apreq_param_t **p, - if (s != APR_SUCCESS) - return s; - -- assert(glen >= dlen); -+ if (!(glen >= dlen)) { return APR_EBADARG; } assert(glen >= dlen); - glen -= dlen; - e = APR_BUCKET_NEXT(e); - } - - /* copy value */ -- assert(vlen > 0); -+ if (!(vlen > 0)) { return APR_EBADARG; } assert(vlen > 0); - dest = v->data; - while (vlen > 0) { - -@@ -119,12 +119,12 @@ static apr_status_t split_header_line(apreq_param_t **p, - - memcpy(dest, data, dlen); - dest += dlen; -- assert(vlen >= dlen); -+ if (!(vlen >= dlen)) { return APR_EBADARG; } assert(vlen >= dlen); - vlen -= dlen; - e = APR_BUCKET_NEXT(e); - } - -- assert(dest[-1] == '\n'); -+ if (!(dest[-1] == '\n')) { return APR_EBADARG; } assert(dest[-1] == '\n'); - - if (dest[-2] == '\r') - --dest;