This commit is contained in:
Robin Malley 2021-04-09 20:15:01 +00:00
parent e5d1904b1f
commit 3b6a631dc4
1 changed files with 1 additions and 1 deletions

View File

@ -35,7 +35,7 @@ local function login_post(req)
local hash = sha3(todigest)
if hash == passhash then
local mysession = session.start(id)
local domain_no_port = config.domain:match("(.*):.*")
local domain_no_port = config.domain:match("(.*):.*") or config.domain
http_response_header(req,"set-cookie",string.format(
[[session=%s; SameSite=Lax; Path=/; Domain=%s; HttpOnly; Secure]],mysession,domain_no_port
))