summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-mwan3/root/usr/share
diff options
context:
space:
mode:
authorFlorian Eckert <fe@dev.tdt.de>2021-07-02 15:23:39 +0200
committerFlorian Eckert <fe@dev.tdt.de>2021-07-09 08:38:11 +0200
commitf5f6b3e4f8e3faed4e9c9926e283c9cf226d4bd8 (patch)
treee2718f194ede046a90274443f6b61198f35a0961 /applications/luci-app-mwan3/root/usr/share
parent12067c8308936abb567001650105b33bec9a56a9 (diff)
luci-app-mwan3: convert to JS
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
Diffstat (limited to 'applications/luci-app-mwan3/root/usr/share')
-rw-r--r--applications/luci-app-mwan3/root/usr/share/luci/menu.d/luci-app-mwan3.json103
-rw-r--r--applications/luci-app-mwan3/root/usr/share/rpcd/acl.d/luci-app-mwan3.json23
2 files changed, 125 insertions, 1 deletions
diff --git a/applications/luci-app-mwan3/root/usr/share/luci/menu.d/luci-app-mwan3.json b/applications/luci-app-mwan3/root/usr/share/luci/menu.d/luci-app-mwan3.json
new file mode 100644
index 0000000000..e646155743
--- /dev/null
+++ b/applications/luci-app-mwan3/root/usr/share/luci/menu.d/luci-app-mwan3.json
@@ -0,0 +1,103 @@
+{
+ "admin/status/mwan3": {
+ "title": "MultiWAN Manager",
+ "order": "600",
+ "action": {
+ "type": "firstchild"
+ },
+ "depends": {
+ "acl": [ "luci-app-mwan3" ]
+ }
+ },
+ "admin/status/mwan3/overview": {
+ "title": "Overview",
+ "order": 10,
+ "action": {
+ "type": "view",
+ "path": "mwan3/status/overview"
+ }
+ },
+ "admin/status/mwan3/detail": {
+ "title": "Status",
+ "order": 20,
+ "action": {
+ "type": "view",
+ "path": "mwan3/status/detail"
+ }
+ },
+ "admin/status/mwan3/diagnostics": {
+ "title": "Diagnostics",
+ "order": 30,
+ "action": {
+ "type": "view",
+ "path": "mwan3/status/diagnostics"
+ }
+ },
+ "admin/status/mwan3/troubleshooting": {
+ "title": "Troubleshooting",
+ "order": 40,
+ "action": {
+ "type": "view",
+ "path": "mwan3/status/troubleshooting"
+ }
+ },
+
+ "admin/network/mwan3": {
+ "title": "MultiWAN Manager",
+ "order": "600",
+ "action": {
+ "type": "firstchild"
+ },
+ "depends": {
+ "acl": [ "luci-app-mwan3" ]
+ }
+ },
+ "admin/network/mwan3/globals": {
+ "title": "Globals",
+ "order": 10,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/globals"
+ }
+ },
+ "admin/network/mwan3/interface": {
+ "title": "Interface",
+ "order": 20,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/interface"
+ }
+ },
+ "admin/network/mwan3/member": {
+ "title": "Member",
+ "order": 30,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/member"
+ }
+ },
+ "admin/network/mwan3/policy": {
+ "title": "Policy",
+ "order": 40,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/policy"
+ }
+ },
+ "admin/network/mwan3/rule": {
+ "title": "Rule",
+ "order": 50,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/rule"
+ }
+ },
+ "admin/network/mwan3/notify": {
+ "title": "Notify",
+ "order": 60,
+ "action": {
+ "type": "view",
+ "path": "mwan3/network/notify"
+ }
+ }
+}
diff --git a/applications/luci-app-mwan3/root/usr/share/rpcd/acl.d/luci-app-mwan3.json b/applications/luci-app-mwan3/root/usr/share/rpcd/acl.d/luci-app-mwan3.json
index 539ed0fb90..91dd225358 100644
--- a/applications/luci-app-mwan3/root/usr/share/rpcd/acl.d/luci-app-mwan3.json
+++ b/applications/luci-app-mwan3/root/usr/share/rpcd/acl.d/luci-app-mwan3.json
@@ -2,9 +2,30 @@
"luci-app-mwan3": {
"description": "Grant UCI access for luci-app-mwan3",
"read": {
- "uci": [ "mwan3" ]
+ "file": {
+ "/etc/mwan3.user": [ "read" ],
+ "/usr/bin/httping": [ "list" ],
+ "/usr/bin/nping": [ "list" ],
+ "/usr/bin/arping": [ "list" ],
+ "/usr/sbin/mwan3 status": [ "exec" ],
+ "/usr/sbin/mwan3 ifup *": [ "exec" ],
+ "/usr/sbin/mwan3 ifdown *": [ "exec" ],
+ "/usr/sbin/mwan3 internal ipv4": [ "exec" ],
+ "/usr/sbin/mwan3 internal ipv6": [ "exec" ],
+ "/usr/libexec/luci-mwan3 diag * *": [ "exec" ],
+ "/usr/libexec/luci-mwan3 ipset *": [ "exec" ]
+ },
+ "ubus": {
+ "mwan3": [ "status" ]
+ },
+ "uci": [ "mwan3", "network" ]
},
"write": {
+ "file": {
+ "/etc/mwan3.user": ["write"],
+ "/usr/sbin/mwan3 ifup *": [ "exec" ],
+ "/usr/sbin/mwan3 ifdown *": [ "exec" ]
+ },
"uci": [ "mwan3" ]
}
}