From: Jo-Philipp Wich Date: Tue, 6 Oct 2015 20:37:23 +0000 (+0200) Subject: luci-base: switch to POST action for service reload X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=ada4a0ea98fbd8fa396cb601ace6c52f3857f5cc;p=oweals%2Fluci.git luci-base: switch to POST action for service reload Switches the service reload calls to CSRF token protected POST action. Signed-off-by: Jo-Philipp Wich --- diff --git a/modules/luci-base/luasrc/controller/admin/servicectl.lua b/modules/luci-base/luasrc/controller/admin/servicectl.lua index 5b855cb24..1d73eb4ec 100644 --- a/modules/luci-base/luasrc/controller/admin/servicectl.lua +++ b/modules/luci-base/luasrc/controller/admin/servicectl.lua @@ -6,7 +6,7 @@ module("luci.controller.admin.servicectl", package.seeall) function index() entry({"servicectl"}, alias("servicectl", "status")).sysauth = "root" entry({"servicectl", "status"}, call("action_status")).leaf = true - entry({"servicectl", "restart"}, call("action_restart")).leaf = true + entry({"servicectl", "restart"}, post("action_restart")).leaf = true end function action_status() diff --git a/modules/luci-base/luasrc/view/cbi/apply_xhr.htm b/modules/luci-base/luasrc/view/cbi/apply_xhr.htm index 1814c9393..6f63ba86b 100644 --- a/modules/luci-base/luasrc/view/cbi/apply_xhr.htm +++ b/modules/luci-base/luasrc/view/cbi/apply_xhr.htm @@ -4,7 +4,7 @@