summaryrefslogtreecommitdiffhomepage
path: root/applications
diff options
context:
space:
mode:
authorHannu Nyman <hannu.nyman@iki.fi>2017-08-08 20:45:07 +0300
committerGitHub <noreply@github.com>2017-08-08 20:45:07 +0300
commitbbcf73f9bf5b5dbbf3eba44ced77c019a0ce0be6 (patch)
tree4f3226a8974d352910bddd920e664ab895a267f9 /applications
parent102199fcbffe80c3b9fef38270f1f69bf3d7c65a (diff)
parent76a4609c6692e61f859e7c729d9f510a4a8768d5 (diff)
Merge pull request #1289 from yousong/shadowsocks-libev
luci-app-shadowsocks-libev: hide key, password value in instance overview
Diffstat (limited to 'applications')
-rw-r--r--applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua
index 63f7ba3c25..0a14f33554 100644
--- a/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua
+++ b/applications/luci-app-shadowsocks-libev/luasrc/model/shadowsocks-libev.lua
@@ -156,6 +156,9 @@ function cfgvalue_overview_(sdata, lines, names)
for _, n in ipairs(names) do
local v = sdata[n]
if v ~= nil then
+ if n == "key" or n == "password" then
+ v = translate("<hidden>")
+ end
local fv = "<var>%s</var>" % ut.pcdata(v)
if sdata[".type"] ~= "ss_server" and n == "server" then
fv = '<a class="label" href="%s">%s</a>' % {