summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-clamav/root/usr
diff options
context:
space:
mode:
Diffstat (limited to 'applications/luci-app-clamav/root/usr')
-rw-r--r--applications/luci-app-clamav/root/usr/share/luci/menu.d/luci-app-clamav.json50
-rw-r--r--applications/luci-app-clamav/root/usr/share/rpcd/acl.d/luci-app-clamav.json12
2 files changed, 56 insertions, 6 deletions
diff --git a/applications/luci-app-clamav/root/usr/share/luci/menu.d/luci-app-clamav.json b/applications/luci-app-clamav/root/usr/share/luci/menu.d/luci-app-clamav.json
index e0426b6155..62e29e3bef 100644
--- a/applications/luci-app-clamav/root/usr/share/luci/menu.d/luci-app-clamav.json
+++ b/applications/luci-app-clamav/root/usr/share/luci/menu.d/luci-app-clamav.json
@@ -2,12 +2,54 @@
"admin/services/clamav": {
"title": "ClamAV",
"action": {
- "type": "cbi",
- "path": "clamav",
- "post": { "cbi.submit": true }
+ "type": "alias",
+ "path": "admin/services/clamav/clamav"
},
"depends": {
- "acl": [ "luci-app-clamav" ]
+ "acl": [ "luci-app-clamav" ],
+ "fs": { "/usr/sbin/clamd": "executable" }
+ }
+ },
+
+ "admin/services/clamav/clamav": {
+ "title": "ClamAV",
+ "order": 1,
+ "action": {
+ "type": "view",
+ "path": "clamav/clamav"
+ }
+ },
+
+ "admin/services/clamav/clamav-milter": {
+ "title": "ClamAV Milter",
+ "order": 2,
+ "action": {
+ "type": "view",
+ "path": "clamav/clamav-milter"
+ },
+ "depends": {
+ "fs": { "/usr/sbin/clamav-milter": "executable" }
+ }
+ },
+
+ "admin/services/clamav/freshclam": {
+ "title": "Freshclam",
+ "order": 3,
+ "action": {
+ "type": "view",
+ "path": "clamav/freshclam"
+ },
+ "depends": {
+ "fs": { "/usr/sbin/freshclam": "executable" }
+ }
+ },
+
+ "admin/services/clamav/clamav-log": {
+ "title": "Log",
+ "order": 4,
+ "action": {
+ "type": "view",
+ "path": "clamav/clamav-log"
}
}
}
diff --git a/applications/luci-app-clamav/root/usr/share/rpcd/acl.d/luci-app-clamav.json b/applications/luci-app-clamav/root/usr/share/rpcd/acl.d/luci-app-clamav.json
index 09d46d08bb..06529a01f3 100644
--- a/applications/luci-app-clamav/root/usr/share/rpcd/acl.d/luci-app-clamav.json
+++ b/applications/luci-app-clamav/root/usr/share/rpcd/acl.d/luci-app-clamav.json
@@ -2,10 +2,18 @@
"luci-app-clamav": {
"description": "Grant UCI access for luci-app-clamav",
"read": {
- "uci": [ "clamav" ]
+ "file": [ "/tmp/*" ],
+ "uci": [ "clamav", "clamav-milter", "freshclam" ]
},
"write": {
- "uci": [ "clamav" ]
+ "file": {
+ "/etc/init.d/clamav *": [ "exec" ],
+ "/etc/init.d/clamav-milter *": [ "exec" ],
+ "/etc/init.d/freshclam *": [ "exec" ],
+ "/sbin/logread -e clamav": [ "exec" ],
+ "/usr/sbin/logread -e clamav": [ "exec" ]
+ },
+ "uci": [ "clamav", "clamav-milter", "freshclam" ]
}
}
}