Welcome! Log In Create A New Profile

Advanced

Nginx + lua-nginx, get ssl_session_id

November 26, 2014 11:29AM
Hi!

I'm trying to modify one of auth modules for nginx and I need to get content of either ssl_session_id or any other ssl_* variables with uniq client id to identify connection. But I've got a problems with accessing to this variables from lua.

For testing purposes I'm using self-signed ssl cert.

ngx.log(ngx.DEBUG, "session_id=", ngx.var.ssl_session_id) prints "nil" in the logs. How can I get access to this variable?

lua script is called with access_by_lua directive.

Thanks in advance!

P.S. If I do "set $test_session_id $ssl_session_id;" in config, test_session_id var is also empty.

Best regards,
Vladimir Smirnov.
Subject Author Posted

Nginx + lua-nginx, get ssl_session_id

VladimirSmirnov November 26, 2014 11:29AM

Re: Nginx + lua-nginx, get ssl_session_id

Yichun Zhang (agentzh) November 26, 2014 03:30PM

Re: Nginx + lua-nginx, get ssl_session_id

VladimirSmirnov November 27, 2014 03:07AM

Re: Nginx + lua-nginx, get ssl_session_id

Yichun Zhang (agentzh) November 29, 2014 12:04AM

Re: Nginx + lua-nginx, get ssl_session_id

Dimka May 26, 2016 07:04AM

Re: Nginx + lua-nginx, get ssl_session_id

Aapo Talvensaari May 26, 2016 08:56AM

Re: Nginx + lua-nginx, get ssl_session_id

Dimka May 26, 2016 09:46AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 105
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready