Fix security vulnerability
This commit is contained in:
parent
d368fb8bc0
commit
f67346231d
4
core.lua
4
core.lua
@ -192,9 +192,9 @@ local handler = function(req, res)
|
||||
|
||||
local succ, val
|
||||
if _ENV then
|
||||
succ, val = xpcall(Lyre.render, debug.traceback, tmpl, env)
|
||||
succ, val = xpcall(Lyre.render, debug.traceback, tmpl, env, true)
|
||||
else
|
||||
succ, val = pcall(Lyre.render, tmpl, env)
|
||||
succ, val = pcall(Lyre.render, tmpl, env, true)
|
||||
end
|
||||
|
||||
if succ then
|
||||
|
Loading…
Reference in New Issue
Block a user