summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-opkg/root/usr/share
diff options
context:
space:
mode:
Diffstat (limited to 'applications/luci-app-opkg/root/usr/share')
-rw-r--r--applications/luci-app-opkg/root/usr/share/luci/menu.d/luci-app-opkg.json36
-rw-r--r--applications/luci-app-opkg/root/usr/share/rpcd/acl.d/luci-app-opkg.json27
2 files changed, 28 insertions, 35 deletions
diff --git a/applications/luci-app-opkg/root/usr/share/luci/menu.d/luci-app-opkg.json b/applications/luci-app-opkg/root/usr/share/luci/menu.d/luci-app-opkg.json
index 9356b586dd..8632a41b3e 100644
--- a/applications/luci-app-opkg/root/usr/share/luci/menu.d/luci-app-opkg.json
+++ b/applications/luci-app-opkg/root/usr/share/luci/menu.d/luci-app-opkg.json
@@ -3,42 +3,8 @@
"title": "Software",
"order": 30,
"action": {
- "type": "template",
+ "type": "view",
"path": "opkg"
}
- },
-
- "admin/system/opkg/list/*": {
- "action": {
- "type": "call",
- "module": "luci.controller.opkg",
- "function": "action_list"
- }
- },
-
- "admin/system/opkg/exec/*": {
- "action": {
- "type": "call",
- "post": true,
- "module": "luci.controller.opkg",
- "function": "action_exec"
- }
- },
-
- "admin/system/opkg/statvfs/*": {
- "action": {
- "type": "call",
- "module": "luci.controller.opkg",
- "function": "action_statvfs"
- }
- },
-
- "admin/system/opkg/config/*": {
- "action": {
- "type": "call",
- "post": { "data": true },
- "module": "luci.controller.opkg",
- "function": "action_config"
- }
}
}
diff --git a/applications/luci-app-opkg/root/usr/share/rpcd/acl.d/luci-app-opkg.json b/applications/luci-app-opkg/root/usr/share/rpcd/acl.d/luci-app-opkg.json
new file mode 100644
index 0000000000..66ef81f103
--- /dev/null
+++ b/applications/luci-app-opkg/root/usr/share/rpcd/acl.d/luci-app-opkg.json
@@ -0,0 +1,27 @@
+{
+ "luci-app-opkg": {
+ "description": "Grant access to opkg management",
+ "read": {
+ "cgi-io": [ "exec" ],
+ "file": {
+ "/usr/libexec/opkg-list installed": [ "exec" ],
+ "/usr/libexec/opkg-list available": [ "exec" ],
+ "/etc/opkg.conf": [ "read" ],
+ "/etc/opkg/*.conf": [ "read" ]
+ },
+ "ubus": {
+ "luci": [ "getMountPoints" ]
+ }
+ },
+ "write": {
+ "file": {
+ "/bin/opkg * install *": [ "exec" ],
+ "/bin/opkg * remove *": [ "exec" ],
+ "/bin/opkg * update": [ "exec" ],
+ "/etc/opkg.conf": [ "write" ],
+ "/etc/opkg/*.conf": [ "write" ],
+ "/tmp/upload.ipk": [ "write" ]
+ }
+ }
+ }
+}