summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-base/luasrc/sgi
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2020-04-10 21:03:19 +0200
committerJo-Philipp Wich <jo@mein.io>2020-04-10 21:03:19 +0200
commit465891ff0239b8fdafb737d01e3f05205a14319b (patch)
tree9cb2c71b3a03fde922e73c5bf27f61fdd29d94e0 /modules/luci-base/luasrc/sgi
parent2dfcca23e4f3edaea2fa5a68a7626a3ab65d3d65 (diff)
luci-base: uhttpd.lua: expose all CGI variables
Fixes: #3873 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'modules/luci-base/luasrc/sgi')
-rw-r--r--modules/luci-base/luasrc/sgi/uhttpd.lua14
1 files changed, 12 insertions, 2 deletions
diff --git a/modules/luci-base/luasrc/sgi/uhttpd.lua b/modules/luci-base/luasrc/sgi/uhttpd.lua
index 2836bf00cf..4cd3649c62 100644
--- a/modules/luci-base/luasrc/sgi/uhttpd.lua
+++ b/modules/luci-base/luasrc/sgi/uhttpd.lua
@@ -18,7 +18,17 @@ function handle_request(env)
SCRIPT_NAME = env.SCRIPT_NAME:gsub("/+$", ""),
SCRIPT_FILENAME = env.SCRIPT_NAME,
SERVER_PROTOCOL = env.SERVER_PROTOCOL,
- QUERY_STRING = env.QUERY_STRING
+ QUERY_STRING = env.QUERY_STRING,
+ DOCUMENT_ROOT = env.DOCUMENT_ROOT,
+ HTTPS = env.HTTPS,
+ REDIRECT_STATUS = env.REDIRECT_STATUS,
+ REMOTE_ADDR = env.REMOTE_ADDR,
+ REMOTE_NAME = env.REMOTE_NAME,
+ REMOTE_PORT = env.REMOTE_PORT,
+ REMOTE_USER = env.REMOTE_USER,
+ SERVER_ADDR = env.SERVER_ADDR,
+ SERVER_NAME = env.SERVER_NAME,
+ SERVER_PORT = env.SERVER_PORT
}
local k, v
@@ -44,7 +54,7 @@ function handle_request(env)
local req = luci.http.Request(
renv, recv, luci.ltn12.sink.file(io.stderr)
)
-
+
local x = coroutine.create(luci.dispatcher.httpdispatch)
local hcache = { }