Skip to content

feature: ngx_http_lua_ffi_ssl_get_client_hello_ciphers()#2419

Merged
zhuizhuhaomeng merged 3 commits into
openresty:masterfrom
climagabriel:feature_ssl_client_hello_get_ciphers
May 24, 2025
Merged

feature: ngx_http_lua_ffi_ssl_get_client_hello_ciphers()#2419
zhuizhuhaomeng merged 3 commits into
openresty:masterfrom
climagabriel:feature_ssl_client_hello_get_ciphers

Conversation

@climagabriel

@climagabriel climagabriel commented May 8, 2025

Copy link
Copy Markdown
Contributor

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

openresty/lua-resty-core#498

Partially inspired by:
	https://github.com/naofumi0628/haproxy/blob/fefb9e37714bd2e3ad2adc3a321e165fc1dafae2/src/ssl_sock.c#L2252

Relevant:
	fooinha/nginx-ssl-ja3#64
        openssl/openssl#27580

And especially:
	https://github.com/openresty/lua-nginx-module#:~:text=after%20SSL%20handshake%2C-,the%20ngx.ctx%20created,-in%20ssl_certificate_by_lua*

It might be pointless for me to pull all this data into Lua-land if I don't find a way to store those values.
I need some kind of ngx.ctx but related not a request but to a connection instead of a request.
@chensunny

Copy link
Copy Markdown
Contributor

The same like #1962

@climagabriel

climagabriel commented May 16, 2025

Copy link
Copy Markdown
Contributor Author

The same like #1962

Partially. He uses different open/boringssl calls under the hood, and his intention is to fetch the client and server ciphers from the session once it's established.
I aim merely to fetch the ciphers offered by the client in the clienthello message, before the SSL session has even been established.

But I will admit that the guy's code is clever and I can learn something from it, thx for referencing it

@zhuizhuhaomeng zhuizhuhaomeng merged commit 1f4d846 into openresty:master May 24, 2025
2 of 3 checks passed
@climagabriel climagabriel deleted the feature_ssl_client_hello_get_ciphers branch May 27, 2025 05:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants