Mercurial > prosody-modules
changeset 3989:32d7f05e062f
mod_auth_custom_http: Unlock globals while loading socket.http
ltn12 tries to set a global and isn't caught by the require sandboxing.
Lua 5.2 issue?
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Thu, 23 Apr 2020 15:39:12 +0100 |
parents | 569f754bd126 |
children | daabba8fb45b |
files | mod_auth_custom_http/mod_auth_custom_http.lua |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mod_auth_custom_http/mod_auth_custom_http.lua Wed Apr 22 12:42:42 2020 +0200 +++ b/mod_auth_custom_http/mod_auth_custom_http.lua Thu Apr 23 15:39:12 2020 +0100 @@ -7,7 +7,9 @@ local new_sasl = require "util.sasl".new; local json = require "util.json"; +prosody.unlock_globals(); local http = require "socket.http"; +prosody.lock_globals(); local options = module:get_option("auth_custom_http"); local post_url = options and options.post_url;