Actions
Support #3418
closedapp-layer-htp.c:880:9: error: implicit declaration of function 'htp_connp_req_close' is invalid in C99
Status:
Closed
Priority:
Normal
Assignee:
-
Affected Versions:
Label:
Description
the most recent development branch seems calling undeclared/defined function htp_connp_req_close ? result in compiling error
CC=clang CFLAGS="-ggdb -O0" ./configure --prefix=/usr/ --sysconfdir=/etc/ --localstatedir=/var/ --enable-ebpf --enable-ebpf-build --enable-debug make[2]: Entering directory '/usr/src/suricata/src' CC app-layer-htp.o app-layer-htp.c:880:9: error: implicit declaration of function 'htp_connp_req_close' is invalid in C99 [-Werror,-Wimplicit-function-declaration] htp_connp_req_close(hstate->connp, &ts); ^ app-layer-htp.c:880:9: note: did you mean 'htp_connp_close'? ./../libhtp/htp/htp_connection_parser.h:59:6: note: 'htp_connp_close' declared here void htp_connp_close(htp_connp_t *connp, const htp_time_t *timestamp); ^ app-layer-htp.c:880:9: warning: this function declaration is not a prototype [-Wstrict-prototypes] htp_connp_req_close(hstate->connp, &ts); ^ 1 warning and 1 error generated. Makefile:1814: recipe for target 'app-layer-htp.o' failed make[2]: *** [app-layer-htp.o] Error 1 make[2]: Leaving directory '/usr/src/suricata/src' Makefile:499: recipe for target 'all-recursive' failed make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory '/usr/src/suricata' Makefile:425: recipe for target 'all' failed make: *** [all] Error 2
this is the commit
commit 040aff5197ba19caef1113c1c5c323eef72a9f69 Author: Victor Julien <victor@inliniac.net> Date: Wed Dec 11 20:57:57 2019 +0100 htp: close request only from request side This allows the response side to keep going for just a bit longer. diff --git a/src/app-layer-htp.c b/src/app-layer-htp.c index e8b05e193..67da98189 100644 --- a/src/app-layer-htp.c +++ b/src/app-layer-htp.c @@ -877,7 +877,7 @@ static int HTPHandleRequestData(Flow *f, void *htp_state, if (AppLayerParserStateIssetFlag(pstate, APP_LAYER_PARSER_EOF) && !(hstate->flags & HTP_FLAG_STATE_CLOSED_TS)) { - htp_connp_close(hstate->connp, &ts); + htp_connp_req_close(hstate->connp, &ts); hstate->flags |= HTP_FLAG_STATE_CLOSED_TS; SCLogDebug("stream eof encountered, closing htp handle for ts"); }
Updated by Victor Julien over 4 years ago
- Tracker changed from Bug to Support
You'll have to update your libhtp to 0.5.32.
Actions