【Nginx 安全修复】安装openresty-1.29.2.4编译报错,如何解呢?
·
运维圈近期关注到:Nginx 18年老漏洞爆发,5月13日,nginx官网已经发布补丁,nginx-1.30.1的版本,就一直在等,终于在昨日 OpenResty 更新了最新的版本openresty-1.29.2.4
下载地址:https://openresty.org/download/openresty-1.29.2.4.tar.gz
更新说明:
- CVE-2026-42945: Buffer overflow in the ngx_http_rewrite_module
- CVE-2026-42946: Buffer overread in the ngx_http_scgi_module and ngx_http_uwsgi_module
- CVE-2026-42934: Buffer overread in the ngx_http_charset_module
- CVE-2026-40460: HTTP/3 address spoofing
- CVE-2026-40701: resolver use-after-free in OCSP
操作系统:centos 7.8
但是下载安装中发现,编译报如下错误:
[app@ng20 openresty-1.29.2.4]$ make -j2
cd /data/openresty-1.29.2.4/build/LuaJIT-2.1-20260415 && make TARGET_STRIP=@: CCDEBUG=-g XCFLAGS='-DLUAJIT_ENABLE_LUA52COMPAT' CC=cc PREFIX=/data/openresty_nginx/luajit
make[1]: Entering directory `/data/openresty-1.29.2.4/build/LuaJIT-2.1-20260415'
==== Building LuaJIT 2.1 ====
make -C src
make[2]: Entering directory `/data/openresty-1.29.2.4/build/LuaJIT-2.1-20260415/src'
make[2]: Nothing to be done for `default'.
make[2]: Leaving directory `/data/openresty-1.29.2.4/build/LuaJIT-2.1-20260415/src'
==== Successfully built LuaJIT 2.1 ====
make[1]: Leaving directory `/data/openresty-1.29.2.4/build/LuaJIT-2.1-20260415'
cd /data/openresty-1.29.2.4/build/lua-cjson-2.1.0.17 && make DESTDIR= LUA_INCLUDE_DIR=/data/openresty-1.29.2.4/build/luajit-root/data/openresty_nginx/luajit/include/luajit-2.1 LUA_CMODULE_DIR=/data/openresty_nginx/lualib LUA_MODULE_DIR=/data/openresty_nginx/lualib CJSON_CFLAGS="-g -fpic" CC=cc
make[1]: Entering directory `/data/openresty-1.29.2.4/build/lua-cjson-2.1.0.17'
cc -c -O3 -Wall -pedantic -DNDEBUG -g -I/data/openresty-1.29.2.4/build/luajit-root/data/openresty_nginx/luajit/include/luajit-2.1 -g -fpic -o lua_cjson.o lua_cjson.c
cc -c -O3 -Wall -pedantic -DNDEBUG -g -I/data/openresty-1.29.2.4/build/luajit-root/data/openresty_nginx/luajit/include/luajit-2.1 -g -fpic -o strbuf.o strbuf.c
strbuf.c: In function ‘debug_stats’:
strbuf.c:89:17: warning: ISO C90 does not support the ‘z’ gnu_printf length modifier [-Wformat=]
(void *) s, s->reallocs, s->length, s->size);
^
strbuf.c:89:17: warning: ISO C90 does not support the ‘z’ gnu_printf length modifier [-Wformat=]
strbuf.c: In function ‘strbuf_resize’:
strbuf.c:168:17: warning: ISO C90 does not support the ‘z’ gnu_printf length modifier [-Wformat=]
(void *) s, s->size, newsize);
^
strbuf.c:168:17: warning: ISO C90 does not support the ‘z’ gnu_printf length modifier [-Wformat=]
In file included from lua_cjson.c:49:0:
fpconv.h:15:5: warning: C++ style comments are not allowed in ISO C90 [enabled by default]
// Add one to try and avoid core id multiplier alignment
^
fpconv.h:15:5: warning: (this will be reported only once per input file) [enabled by default]
lua_cjson.c: In function ‘json_append_newline_and_indent’:
lua_cjson.c:706:5: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int i = 0; i < depth; i++)
^
lua_cjson.c:706:5: note: use option -std=c99 or -std=gnu99 to compile your code
lua_cjson.c: In function ‘json_next_number_token’:
lua_cjson.c:1261:10: warning: ISO C90 does not support ‘long long’ [-Wlong-long]
long long tmpval = strtoll(json->ptr, &endptr, 10);
^
make[1]: *** [lua_cjson.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/data/openresty-1.29.2.4/build/lua-cjson-2.1.0.17'
make: *** [all] Error 2
PS:当前机器已测试,可成功安装nginx-1.30.1及openresty-1.29.2.3
更多推荐

所有评论(0)