summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-24 02:00:02 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-24 02:00:02 +0000
commit594b810b9f0a36ac69ae9ba8c3216f3a86524c5c (patch)
tree4c8fd9a1e71eb4a73390ab7c9df85c462ebc7e51
parentReleasing progress-linux version 1:0.5.47-1~progress7.99u1. (diff)
downloadlibhtp-594b810b9f0a36ac69ae9ba8c3216f3a86524c5c.tar.xz
libhtp-594b810b9f0a36ac69ae9ba8c3216f3a86524c5c.zip
Merging upstream version 1:0.5.48.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
-rw-r--r--ChangeLog7
-rw-r--r--VERSION2
-rw-r--r--configure.ac29
-rw-r--r--htp/htp_decompressors.c2
4 files changed, 23 insertions, 17 deletions
diff --git a/ChangeLog b/ChangeLog
index d1d2396..af6398c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+0.5.48 (22 April 2024)
+----------------------
+
+- decompressor: only take erroneous data on first try
+
+- autotools: run autoupdate to modernize build system
+
0.5.47 (19 March 2024)
----------------------
diff --git a/VERSION b/VERSION
index a42c9e0..21e46bb 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
# This file is intended to be sourced by sh
-PKG_VERSION=0.5.47
+PKG_VERSION=0.5.48
diff --git a/configure.ac b/configure.ac
index 1ad3308..c28441b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3,7 +3,7 @@ dnl ----------------------
dnl Initialization macros
dnl ----------------------
-AC_INIT([LibHTP], m4_esyscmd([./get-version.sh VERSION]))
+AC_INIT([LibHTP],[m4_esyscmd(./get-version.sh VERSION)])
AM_INIT_AUTOMAKE()
AC_CONFIG_HEADERS([htp_config_auto_gen.h])
@@ -86,7 +86,7 @@ dnl -----------------------------------------------
AC_PROG_CC
AM_PROG_CC_C_O
AC_PROG_CXX
-AM_PROG_LIBTOOL
+LT_INIT
AM_SANITY_CHECK
# Checks for library functions
@@ -99,7 +99,7 @@ AM_SANITY_CHECK
dnl -----------------------------------------------
dnl Checks for libs.
dnl -----------------------------------------------
-AC_CHECK_HEADER(zlib.h,,[AC_ERROR(zlib.h not found ...)])
+AC_CHECK_HEADER(zlib.h,,[AC_MSG_ERROR(zlib.h not found ...)])
ZLIB=""
AC_CHECK_LIB(z, inflate,, ZLIB="no")
if test "$ZLIB" = "no"; then
@@ -161,13 +161,11 @@ AC_MSG_CHECKING(for iconvctl)
TMPLIBS="${LIBS}"
LIBS="${LIBS} ${LIBICONV}"
-AC_TRY_LINK([#include <stdlib.h>
- #include <iconv.h>],
- [int iconv_param = 0;
+AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdlib.h>
+ #include <iconv.h>]], [[int iconv_param = 0;
iconv_t cd = iconv_open("","");
iconvctl(cd, ICONV_SET_DISCARD_ILSEQ, &iconv_param);
- iconv_close(cd);],
- [ac_cv_func_iconvctl=yes])
+ iconv_close(cd);]])],[ac_cv_func_iconvctl=yes],[])
AC_MSG_RESULT($ac_cv_func_iconvctl)
if test "$ac_cv_func_iconvctl" == yes; then
AC_DEFINE(HAVE_ICONVCTL,1,"Define to 1 if you have the `iconvctl' function.")
@@ -185,7 +183,7 @@ dnl -----------------------------------------------
AC_MSG_CHECKING(for gcc support of -Wstrict-overflow=1)
TMPCFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} -Wstrict-overflow=1"
-AC_TRY_COMPILE(,,[gcc_have_strict_overflow=yes],[gcc_have_strict_overflow=no])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[gcc_have_strict_overflow=yes],[gcc_have_strict_overflow=no])
AC_MSG_RESULT($gcc_have_strict_overflow)
if test "$gcc_have_strict_overflow" != "yes"; then
CFLAGS="${TMPCFLAGS}"
@@ -198,7 +196,7 @@ dnl -----------------------------------------------
AC_MSG_CHECKING(for gcc support of stack smashing protection)
TMPCFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} -fstack-protector"
-AC_TRY_COMPILE(,,[gcc_have_fstack_protector=yes],[gcc_have_fstack_protector=no])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[gcc_have_fstack_protector=yes],[gcc_have_fstack_protector=no])
AC_MSG_RESULT($gcc_have_fstack_protector)
if test "$gcc_have_fstack_protector" != "yes"; then
CFLAGS="${TMPCFLAGS}"
@@ -211,7 +209,7 @@ dnl -----------------------------------------------
AC_MSG_CHECKING(for gcc support of FORTIFY_SOURCE)
TMPCFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} -D_FORTIFY_SOURCE=2"
-AC_TRY_COMPILE(,,[gcc_have_fortify_source=yes],[gcc_have_fortify_source=no])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[gcc_have_fortify_source=yes],[gcc_have_fortify_source=no])
AC_MSG_RESULT($gcc_have_fortify_source)
if test "$gcc_have_fortify_source" != "yes"; then
CFLAGS="${TMPCFLAGS}"
@@ -223,7 +221,7 @@ dnl -----------------------------------------------
AC_MSG_CHECKING(for gcc support of -Wformat -Wformat-security)
TMPCFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} -Wformat -Wformat-security"
-AC_TRY_COMPILE(,,[gcc_have_format_security=yes],[gcc_have_format_security=no])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[gcc_have_format_security=yes],[gcc_have_format_security=no])
AC_MSG_RESULT($gcc_have_format_security)
if test "$gcc_have_format_security" != "yes"; then
CFLAGS="${TMPCFLAGS}"
@@ -232,7 +230,7 @@ fi
AC_MSG_CHECKING(for gcc support of -fPIC)
TMPCFLAGS="${CFLAGS}"
CFLAGS="${CFLAGS} -fPIC"
-AC_TRY_COMPILE(,,[gcc_have_fpic=yes],[gcc_have_fpic=no])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[gcc_have_fpic=yes],[gcc_have_fpic=no])
AC_MSG_RESULT($gcc_have_fpic)
if test "$gcc_have_fpic" != "yes"; then
CFLAGS="${TMPCFLAGS}"
@@ -266,10 +264,11 @@ dnl Generates Makefiles, configuration files and scripts
dnl -----------------------------------------------
AC_PREFIX_DEFAULT(/usr/local)
-AC_OUTPUT(Makefile \
+AC_CONFIG_FILES([Makefile \
htp.pc \
htp/Makefile \
htp/lzma/Makefile \
test/Makefile \
docs/Makefile
-)
+])
+AC_OUTPUT
diff --git a/htp/htp_decompressors.c b/htp/htp_decompressors.c
index fe12833..02ebae3 100644
--- a/htp/htp_decompressors.c
+++ b/htp/htp_decompressors.c
@@ -317,7 +317,7 @@ restart:
return HTP_ERROR;
}
if (GZIP_BUF_SIZE > drec->stream.avail_out) {
- if (rc == Z_DATA_ERROR) {
+ if (rc == Z_DATA_ERROR && drec->restart == 0) {
// There is data even if there is an error
// So use this data and log a warning
htp_log(d->tx->connp, HTP_LOG_MARK, HTP_LOG_WARNING, 0, "GZip decompressor: inflate failed with %d", rc);