Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined symbol: EVP_CIPHER_CTX_cleanup #2

Open
duanzhaoqian opened this issue Nov 22, 2021 · 2 comments
Open

undefined symbol: EVP_CIPHER_CTX_cleanup #2

duanzhaoqian opened this issue Nov 22, 2021 · 2 comments

Comments

@duanzhaoqian
Copy link

duanzhaoqian commented Nov 22, 2021

resty 0.27
nginx version: openresty/1.19.3.1
built by gcc 8.3.1 20190311 (Red Hat 8.3.1-3) (GCC)
built with OpenSSL 1.1.1h 22 Sep 2020
TLS SNI support enabled
configure arguments: --prefix=/usr/local/openresty/nginx --with-cc-opt='-O2 -DNGX_LUA_ABORT_AT_PANIC -I/usr/local/openresty/zlib/include -I/usr/local/openresty/pcre/include -I/usr/local/openresty/openssl111/include' --add-module=../ngx_devel_kit-0.3.1 --add-module=../echo-nginx-module-0.62 --add-module=../xss-nginx-module-0.06 --add-module=../ngx_coolkit-0.2 --add-module=../set-misc-nginx-module-0.32 --add-module=../form-input-nginx-module-0.12 --add-module=../encrypted-session-nginx-module-0.08 --add-module=../srcache-nginx-module-0.32 --add-module=../ngx_lua-0.10.19 --add-module=../ngx_lua_upstream-0.07 --add-module=../headers-more-nginx-module-0.33 --add-module=../array-var-nginx-module-0.05 --add-module=../memc-nginx-module-0.19 --add-module=../redis2-nginx-module-0.15 --add-module=../redis-nginx-module-0.3.7 --add-module=../ngx_stream_lua-0.0.9 --with-ld-opt='-Wl,-rpath,/usr/local/openresty/luajit/lib -L/usr/local/openresty/zlib/lib -L/usr/local/openresty/pcre/lib -L/usr/local/openresty/openssl111/lib -Wl,-rpath,/usr/local/openresty/zlib/lib:/usr/local/openresty/pcre/lib:/usr/local/openresty/openssl111/lib' --with-cc='ccache gcc -fdiagnostics-color=always' --with-pcre-jit --with-stream --with-stream_ssl_module --with-stream_ssl_preread_module --with-http_v2_module --without-mail_pop3_module --without-mail_imap_module --without-mail_smtp_module --with-http_stub_status_module --with-http_realip_module --with-http_addition_module --with-http_auth_request_module --with-http_secure_link_module --with-http_random_index_module --with-http_gzip_static_module --with-http_sub_module --with-http_dav_module --with-http_flv_module --with-http_mp4_module --with-http_gunzip_module --with-threads --with-compat --with-stream --with-http_ssl_module

@duanzhaoqian
Copy link
Author

2021/11/22 04:53:31 [warn] 29930#29930: *2 [lua] _G write guard:12: __newindex(): writing a global Lua variable ('size') which may lead to race conditions between concurrent requests, so prefer the use of 'local' variables
stack traceback:
/usr/local/openresty/lualib/resty/des.lua:106: in function 'cipher'
/usr/local/openresty/lualib/resty/des.lua:127: in function 'new'
lua_func_test.lua:10: in function 'file_gen'
init_worker_by_lua:45: in function <init_worker_by_lua:43>
[C]: in function 'xpcall'
init_worker_by_lua:52: in function <init_worker_by_lua:50>, context: ngx.timer
ERROR: /usr/local/openresty/lualib/resty/des.lua:173: /usr/local/openresty/luajit/lib/libluajit-5.1.so.2: undefined symbol: EVP_CIPHER_CTX_cleanup
stack traceback:
/usr/local/openresty/lualib/resty/des.lua:173: in function 'new'
lua_func_test.lua:10: in function 'file_gen'
init_worker_by_lua:45: in function <init_worker_by_lua:43>
[C]: in function 'xpcall'
init_worker_by_lua:52: in function <init_worker_by_lua:50>

@lx940112
Copy link

lx940112 commented Dec 9, 2021

2021/11/22 04:53:31 [warn] 29930#29930: *2 [lua] _G write guard:12: __newindex(): writing a global Lua variable ('size') which may lead to race conditions between concurrent requests, so prefer the use of 'local' variables stack traceback: /usr/local/openresty/lualib/resty/des.lua:106: in function 'cipher' /usr/local/openresty/lualib/resty/des.lua:127: in function 'new' lua_func_test.lua:10: in function 'file_gen' init_worker_by_lua:45: in function <init_worker_by_lua:43> [C]: in function 'xpcall' init_worker_by_lua:52: in function <init_worker_by_lua:50>, context: ngx.timer ERROR: /usr/local/openresty/lualib/resty/des.lua:173: /usr/local/openresty/luajit/lib/libluajit-5.1.so.2: undefined symbol: EVP_CIPHER_CTX_cleanup stack traceback: /usr/local/openresty/lualib/resty/des.lua:173: in function 'new' lua_func_test.lua:10: in function 'file_gen' init_worker_by_lua:45: in function <init_worker_by_lua:43> [C]: in function 'xpcall' init_worker_by_lua:52: in function <init_worker_by_lua:50>

我也遇到的同样的问题,我换了个openssl 1.0.x 的版本是可以的,但是1.1.x版本就不行了,我尝试着将"des.lua" 中所有的 EVP_CIPHER_CTX_cleanup 修改为 EVP_CIPHER_CTX_reset 之后,就可以成功执行了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants