openresty / lua-resty-core

New FFI-based API for lua-nginx-module
811 stars 272 forks source link

feature: Add parse_der_cert and parse_der_priv_key functions #455

Closed devicenull closed 10 months ago

devicenull commented 10 months ago

This is the corresponding Lua side of https://github.com/openresty/lua-nginx-module/pull/2278 and https://github.com/openresty/stream-lua-nginx-module/pull/336 and should not be merged until those make it in.

I hereby granted the copyright of the changes in this pull request to the authors of this lua-resty-core project.

devicenull commented 10 months ago

Tests failing is entirely expected right now, they won't pass until the lua-nginx-module changes are merged

zhuizhuhaomeng commented 10 months ago

This is the corresponding Lua side of openresty/lua-nginx-module#2278 and should not be merged until that makes it in.

I hereby granted the copyright of the changes in this pull request to the authors of this lua-resty-core project.

You also need to check if the CI is passed.

devicenull commented 10 months ago

This is the corresponding Lua side of openresty/lua-nginx-module#2278 and should not be merged until that makes it in. I hereby granted the copyright of the changes in this pull request to the authors of this lua-resty-core project.

You also need to check if the CI is passed.

Tests here cannot pass until the C side of this is in. Error message is currently:

2024/01/17 20:47:55 [error] 31953#0: *4 lua entry thread aborted: runtime error: ./lib/ngx/ssl.lua:114: /opt/luajit21/lib/libluajit-5.1.so.2: undefined symbol: ngx_http_lua_ffi_parse_der_cert" (req 0)

This functionality was only added here and here and has not been merged yet.

zhuizhuhaomeng commented 10 months ago

merged with small modifications.