aboutsummaryrefslogtreecommitdiffstats
path: root/msb-core/openresty-ext/src/assembly/resources/openresty/nginx/luaext/login.lua
blob: 7d6bfd853f5c8dd482c173d252c20136c866d063 (plain)
1
2
3
4
5
6
7
8
9
local h = ngx.resp.get_headers()
if h["openoauth"] and h["openoauth"] == "true" then
	local cache = ngx.shared.ceryx
	local client_ip = ngx.var.remote_addr
	local succ, err, forcible = cache:set(client_ip, "place_holder", 3600)
	if not succ then
		ngx.log(ngx.WARN, err)
	end
end