blob: be2d9b6eb68f4d8f0ae13ded2f36dbaa5e371abd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
module("ffluci.controller.admin.system", package.seeall)
require("ffluci.sys")
require("ffluci.http")
menu = {
descr = "System",
order = 20,
entries = {
{action = "passwd", descr = "Passwort"},
}
}
function action_passwd()
local p1 = ffluci.http.formvalue("pwd1")
local p2 = ffluci.http.formvalue("pwd2")
local msg = nil
local cm
if p1 or p2 then
msg = ffluci.sys.user.setpasswd("root", p1, p2)
end
ffluci.template.render("admin_system/passwd", {msg=msg})
end
|