diff options
author | Stan Grishin <stangri@melmac.ca> | 2023-08-28 21:30:42 +0000 |
---|---|---|
committer | Stan Grishin <stangri@melmac.ca> | 2023-09-03 13:57:04 +0000 |
commit | 81fc75739c13881ba339d02017ec3a5d2a32948d (patch) | |
tree | bbfeb73e3f2bd18b63bf20ab37310397a776c3ef /applications | |
parent | 324f5a3f79ac237d4ffc14624ffb4d768f7d8921 (diff) |
luci-app-adblock-fast: initial commit
* Depends on https://github.com/openwrt/packages/pull/21943
Signed-off-by: Stan Grishin <stangri@melmac.ca>
Diffstat (limited to 'applications')
-rw-r--r-- | applications/luci-app-adblock-fast/Makefile (renamed from applications/luci-app-simple-adblock/Makefile) | 10 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js | 479 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js | 385 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ar/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ar/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/bg/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/bg/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/bn_BD/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/bn_BD/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ca/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ca/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/cs/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/cs/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/da/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/da/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/de/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/de/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/el/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/el/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/en/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/en/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/es/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/es/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/fi/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/fi/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/fr/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/fr/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/he/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/he/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/hi/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/hi/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/hu/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/hu/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/it/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/it/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ja/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ja/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ko/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ko/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/lt/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/lt/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/mr/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/mr/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ms/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ms/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/nb_NO/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/nb_NO/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/pl/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/pl/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/pt/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/pt/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/pt_BR/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/pt_BR/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ro/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ro/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/ru/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/ru/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/sk/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/sk/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/sv/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/sv/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/templates/adblock-fast.pot | 586 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/tr/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/tr/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/uk/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/uk/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/vi/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/vi/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/zh_Hans/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/zh_Hans/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/po/zh_Hant/adblock-fast.po (renamed from applications/luci-app-simple-adblock/po/zh_Hant/simple-adblock.po) | 0 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/root/etc/uci-defaults/40_luci-adblock-fast (renamed from applications/luci-app-simple-adblock/root/etc/uci-defaults/40_luci-simple-adblock) | 0 | ||||
-rwxr-xr-x | applications/luci-app-adblock-fast/root/usr/libexec/rpcd/luci.adblock-fast (renamed from applications/luci-app-simple-adblock/root/usr/libexec/rpcd/luci.simple-adblock) | 70 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/root/usr/share/luci/menu.d/luci-app-adblock-fast.json | 17 | ||||
-rw-r--r-- | applications/luci-app-adblock-fast/root/usr/share/rpcd/acl.d/luci-app-adblock-fast.json | 32 | ||||
-rw-r--r-- | applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js | 323 | ||||
-rw-r--r-- | applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js | 187 | ||||
-rw-r--r-- | applications/luci-app-simple-adblock/po/templates/simple-adblock.pot | 559 | ||||
-rw-r--r-- | applications/luci-app-simple-adblock/root/usr/share/luci/menu.d/luci-app-simple-adblock.json | 17 | ||||
-rw-r--r-- | applications/luci-app-simple-adblock/root/usr/share/rpcd/acl.d/luci-app-simple-adblock.json | 27 |
47 files changed, 1562 insertions, 1130 deletions
diff --git a/applications/luci-app-simple-adblock/Makefile b/applications/luci-app-adblock-fast/Makefile index 47b9623c5b..7dcb82ba73 100644 --- a/applications/luci-app-simple-adblock/Makefile +++ b/applications/luci-app-adblock-fast/Makefile @@ -1,15 +1,15 @@ -# Copyright 2017-2022 Stan Grishin (stangri@melmac.ca) +# Copyright 2023 MOSSDeF, Stan Grishin (stangri@melmac.ca) # This is free software, licensed under the GNU General Public License v3. include $(TOPDIR)/rules.mk PKG_LICENSE:=GPL-3.0-or-later PKG_MAINTAINER:=Stan Grishin <stangri@melmac.ca> -PKG_VERSION:=1.9.5-3 +PKG_VERSION:=1.0.0-1 -LUCI_TITLE:=Simple Adblock Web UI -LUCI_DESCRIPTION:=Provides Web UI for simple-adblock service. -LUCI_DEPENDS:=+luci-base +simple-adblock +jsonfilter +LUCI_TITLE:=AdBlock-Fast Web UI +LUCI_DESCRIPTION:=Provides Web UI for adblock-fast service. +LUCI_DEPENDS:=+luci-base +adblock-fast +jsonfilter LUCI_PKGARCH:=all include ../../luci.mk diff --git a/applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js b/applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js new file mode 100644 index 0000000000..901d3d9f26 --- /dev/null +++ b/applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js @@ -0,0 +1,479 @@ +// Copyright MOSSDeF, 2023 Stan Grishin <stangri@melmac.ca> +// This code wouldn't have been possible without help from: +// - [@vsviridov](https://github.com/vsviridov) + +"require ui"; +"require rpc"; +"require form"; +"require baseclass"; + +var pkg = { + get Name() { + return "adblock-fast"; + }, + get URL() { + return "https://docs.openwrt.melmac.net/" + pkg.Name + "/"; + }, +}; + +var getFileUrlFilesizes = rpc.declare({ + object: "luci." + pkg.Name, + method: "getFileUrlFilesizes", + params: ["name", "url"], +}); + +var getInitList = rpc.declare({ + object: "luci." + pkg.Name, + method: "getInitList", + params: ["name"], +}); + +var getInitStatus = rpc.declare({ + object: "luci." + pkg.Name, + method: "getInitStatus", + params: ["name"], +}); + +var getPlatformSupport = rpc.declare({ + object: "luci." + pkg.Name, + method: "getPlatformSupport", + params: ["name"], +}); + +var _setInitAction = rpc.declare({ + object: "luci." + pkg.Name, + method: "setInitAction", + params: ["name", "action"], + expect: { result: false }, +}); + +var RPC = { + listeners: [], + on: function (event, callback) { + var pair = { event: event, callback: callback }; + this.listeners.push(pair); + return function unsubscribe() { + this.listeners = this.listeners.filter(function (listener) { + return listener !== pair; + }); + }.bind(this); + }, + emit: function (event, data) { + this.listeners.forEach(function (listener) { + if (listener.event === event) { + listener.callback(data); + } + }); + }, + setInitAction: function (name, action) { + _setInitAction(name, action).then( + function (result) { + this.emit("setInitAction", result); + }.bind(this) + ); + }, +}; + +var status = baseclass.extend({ + render: function () { + return Promise.all([L.resolveDefault(getInitStatus(pkg.Name), {})]).then( + function (data) { + var reply = { + status: (data[0] && data[0][pkg.Name]) || { + enabled: false, + status: null, + running: null, + version: null, + errors: [], + warnings: [], + force_dns_active: null, + force_dns_ports: [], + entries: null, + dns: null, + outputFile: null, + outputCache: null, + outputGzip: null, + outputFileExists: null, + outputCacheExists: null, + outputGzipExists: null, + leds: [], + }, + }; + var text = ""; + var outputFile = reply.status.outputFile; + var outputCache = reply.status.outputCache; + var statusTable = { + statusNoInstall: _("%s is not installed or not found").format( + pkg.Name + ), + statusStopped: _("Stopped"), + statusStarting: _("Starting"), + statusProcessing: _("Processing lists"), + statusRestarting: _("Restarting"), + statusForceReloading: _("Force Reloading"), + statusDownloading: _("Downloading lists"), + statusError: _("Error"), + statusWarning: _("Warning"), + statusFail: _("Fail"), + statusSuccess: _("Active"), + }; + + var header = E("h2", {}, _("AdBlock-Fast - Status")); + var statusTitle = E( + "label", + { class: "cbi-value-title" }, + _("Service Status") + ); + if (reply.status.version) { + text += _("Version %s").format(reply.status.version) + " - "; + switch (reply.status.status) { + case "statusSuccess": + text += statusTable[reply.status.status] + "."; + text += + "<br />" + + _("Blocking %s domains (with %s).").format( + reply.status.entries, + reply.status.dns + ); + if (reply.status.outputGzipExists) { + text += "<br />" + _("Compressed cache file created."); + } + if (reply.status.force_dns_active) { + text += "<br />" + _("Force DNS ports:"); + reply.status.force_dns_ports.forEach((element) => { + text += " " + element; + }); + text += "."; + } + break; + case "statusStopped": + if (reply.status.enabled) { + text += statusTable[reply.status.status] + "."; + } else { + text += + statusTable[reply.status.status] + + " (" + + _("Disabled") + + ")."; + } + if (reply.status.outputCacheExists) { + text += "<br />" + _("Cache file found."); + } else if (reply.status.outputGzipExists) { + text += "<br />" + _("Compressed cache file found."); + } + break; + case "statusRestarting": + case "statusForceReloading": + case "statusDownloading": + case "statusProcessing": + text += statusTable[reply.status.status] + "..."; + break; + default: + text += statusTable[reply.status.status] + "."; + break; + } + } else { + text = _("Not installed or not found"); + } + var statusText = E("div", {}, text); + var statusField = E("div", { class: "cbi-value-field" }, statusText); + var statusDiv = E("div", { class: "cbi-value" }, [ + statusTitle, + statusField, + ]); + + var warningsDiv = []; + if (reply.status.warnings && reply.status.warnings.length) { + var warningTable = { + warningExternalDnsmasqConfig: _( + "Use of external dnsmasq config file detected, please set '%s' option to '%s'" + ).format("dns", "dnsmasq.conf"), + warningMissingRecommendedPackages: _( + "Some recommended packages are missing" + ), + }; + var warningsTitle = E( + "label", + { class: "cbi-value-title" }, + _("Service Warnings") + ); + var text = ""; + reply.status.warnings.forEach((element) => { + text += + warningTable[element.id].format(element.extra || " ") + "<br />"; + }); + var warningsText = E("div", {}, text); + var warningsField = E( + "div", + { class: "cbi-value-field" }, + warningsText + ); + warningsDiv = E("div", { class: "cbi-value" }, [ + warningsTitle, + warningsField, + ]); + } + + var errorsDiv = []; + if (reply.status.errors && reply.status.errors.length) { + var errorTable = { + errorConfigValidationFail: _( + "Config (%s) validation failure!" + ).format("/etc/config/" + pkg.Name), + errorServiceDisabled: _("%s is currently disabled").format( + pkg.Name + ), + errorNoDnsmasqIpset: _( + "The dnsmasq ipset support is enabled, but dnsmasq is either not installed or installed dnsmasq does not support ipset" + ), + errorNoIpset: _( + "The dnsmasq ipset support is enabled, but ipset is either not installed or installed ipset does not support '%s' type" + ).format("hash:net"), + errorNoDnsmasqNftset: _( + "The dnsmasq nft set support is enabled, but dnsmasq is either not installed or installed dnsmasq does not support nft set" + ), + errorNoNft: _( + "The dnsmasq nft sets support is enabled, but nft is not installed" + ), + errorNoWanGateway: _( + "The %s failed to discover WAN gateway" + ).format(pkg.Name), + errorOutputDirCreate: _("Failed to create directory for %s file"), + errorOutputFileCreate: _("Failed to create '%s' file").format( + outputFile + ), + errorFailDNSReload: _("Failed to restart/reload DNS resolver"), + errorSharedMemory: _("Failed to access shared memory"), + errorSorting: _("Failed to sort data file"), + errorOptimization: _("Failed to optimize data file"), + errorAllowListProcessing: _("Failed to process allow-list"), + errorDataFileFormatting: _("Failed to format data file"), + errorMovingDataFile: _( + "Failed to move temporary data file to '%s'" + ).format(outputFile), + errorCreatingCompressedCache: _( + "Failed to create compressed cache" + ), + errorRemovingTempFiles: _("Failed to remove temporary files"), + errorRestoreCompressedCache: _("Failed to unpack compressed cache"), + errorRestoreCache: _("Failed to move '%s' to '%s'").format( + outputCache, + outputFile + ), + errorOhSnap: _( + "Failed to create block-list or restart DNS resolver" + ), + errorStopping: _("Failed to stop %s").format(pkg.Name), + errorDNSReload: _("Failed to reload/restart DNS resolver"), + errorDownloadingConfigUpdate: _( + "Failed to download Config Update file" + ), + errorDownloadingList: _("Failed to download %s"), + errorParsingConfigUpdate: _("Failed to parse Config Update file"), + errorParsingList: _("Failed to parse"), + errorNoSSLSupport: _("No HTTPS/SSL support on device"), + errorCreatingDirectory: _( + "Failed to create output/cache/gzip file directory" + ), + }; + var errorsTitle = E( + "label", + { class: "cbi-value-title" }, + _("Service Errors") + ); + var text = ""; + reply.status.errors.forEach((element) => { + text += + errorTable[element.id].format(element.extra || " ") + "<br />"; + }); + text += _("Errors encountered, please check the %sREADME%s!").format( + "<a href='" + pkg.URL + '" target="_blank">', + "</a><br />" + ); + var errorsText = E("div", {}, text); + var errorsField = E("div", { class: "cbi-value-field" }, errorsText); + errorsDiv = E("div", { class: "cbi-value" }, [ + errorsTitle, + errorsField, + ]); + } + + var btn_gap = E("span", {}, "  "); + var btn_gap_long = E( + "span", + {}, + "        " + ); + + var btn_start = E( + "button", + { + class: "btn cbi-button cbi-button-apply", + disabled: true, + click: function (ev) { + ui.showModal(null, [ + E( + "p", + { class: "spinning" }, + _("Starting %s service").format(pkg.Name) + ), + ]); + return RPC.setInitAction(pkg.Name, "start"); + }, + }, + _("Start") + ); + + var btn_action = E( + "button", + { + class: "btn cbi-button cbi-button-apply", + disabled: true, + click: function (ev) { + ui.showModal(null, [ + E( + "p", + { class: "spinning" }, + _("Force re-downloading %s block lists").format(pkg.Name) + ), + ]); + return RPC.setInitAction(pkg.Name, "dl"); + }, + }, + _("Force Re-Download") + ); + + var btn_stop = E( + "button", + { + class: "btn cbi-button cbi-button-reset", + disabled: true, + click: function (ev) { + ui.showModal(null, [ + E( + "p", + { class: "spinning" }, + _("Stopping %s service").format(pkg.Name) + ), + ]); + return RPC.setInitAction(pkg.Name, "stop"); + }, + }, + _("Stop") + ); + + var btn_enable = E( + "button", + { + class: "btn cbi-button cbi-button-apply", + disabled: true, + click: function (ev) { + ui.showModal(null, [ + E( + "p", + { class: "spinning" }, + _("Enabling %s service").format(pkg.Name) + ), + ]); + return RPC.setInitAction(pkg.Name, "enable"); + }, + }, + _("Enable") + ); + + var btn_disable = E( + "button", + { + class: "btn cbi-button cbi-button-reset", + disabled: true, + click: function (ev) { + ui.showModal(null, [ + E( + "p", + { class: "spinning" }, + _("Disabling %s service").format(pkg.Name) + ), + ]); + return RPC.setInitAction(pkg.Name, "disable"); + }, + }, + _("Disable") + ); + + if (reply.status.enabled) { + btn_enable.disabled = true; + btn_disable.disabled = false; + switch (reply.status.status) { + case "statusSuccess": + btn_start.disabled = true; + btn_action.disabled = false; + btn_stop.disabled = false; + break; + case "statusStopped": + btn_start.disabled = false; + btn_action.disabled = true; + btn_stop.disabled = true; + break; + default: + btn_start.disabled = false; + btn_action.disabled = true; + btn_stop.disabled = false; + btn_enable.disabled = true; + btn_disable.disabled = true; + break; + } + } else { + btn_start.disabled = true; + btn_action.disabled = true; + btn_stop.disabled = true; + btn_enable.disabled = false; + btn_disable.disabled = true; + } + + var buttonsDiv = []; + var buttonsTitle = E( + "label", + { class: "cbi-value-title" }, + _("Service Control") + ); + var buttonsText = E("div", {}, [ + btn_start, + btn_gap, + btn_action, + btn_gap, + btn_stop, + btn_gap_long, + btn_enable, + btn_gap, + btn_disable, + ]); + var buttonsField = E("div", { class: "cbi-value-field" }, buttonsText); + if (reply.status.version) { + buttonsDiv = E("div", { class: "cbi-value" }, [ + buttonsTitle, + buttonsField, + ]); + } + + return E("div", {}, [ + header, + statusDiv, + warningsDiv, + errorsDiv, + buttonsDiv, + ]); + } + ); + }, +}); + +RPC.on("setInitAction", function (reply) { + ui.hideModal(); + location.reload(); +}); + +return L.Class.extend({ + status: status, + getFileUrlFilesizes: getFileUrlFilesizes, + getPlatformSupport: getPlatformSupport, +}); diff --git a/applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js b/applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js new file mode 100644 index 0000000000..92caf6b35d --- /dev/null +++ b/applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js @@ -0,0 +1,385 @@ +// Copyright 2023 MOSSDeF, Stan Grishin <stangri@melmac.ca> +// This code wouldn't have been possible without help from: +// - [@stokito](https://github.com/stokito) +// - [@vsviridov](https://github.com/vsviridov) + +"use strict"; +"require form"; +"require uci"; +"require view"; +"require adblock-fast.status as adb"; + +var pkg = { + get Name() { + return "adblock-fast"; + }, + get URL() { + return "https://docs.openwrt.melmac.net/" + pkg.Name + "/"; + }, + humanFileSize: function (bytes, si = false, dp = 2) { + return `%${si ? 1000 : 1024}.${dp ?? 0}mB`.format(bytes); + }, +}; + +return view.extend({ + load: function () { + return Promise.all([ + L.resolveDefault(adb.getFileUrlFilesizes(pkg.Name), {}), + L.resolveDefault(adb.getPlatformSupport(pkg.Name), {}), + uci.load(pkg.Name), + uci.load("dhcp"), + ]); + }, + + render: function (data) { + var reply = { + sizes: (data[0] && data[0][pkg.Name] && data[0][pkg.Name]["sizes"]) || [], + platform: (data[1] && data[1][pkg.Name]) || { + ipset_installed: false, + nft_installed: false, + dnsmasq_installed: false, + unbound_installed: false, + dnsmasq_ipset_support: false, + dnsmasq_nftset_support: false, + leds: [], + }, + }; + var status, m, s1, s2, s3, o; + + status = new adb.status(); + m = new form.Map(pkg.Name, _("AdBlock-Fast - Configuration")); + s1 = m.section(form.NamedSection, "config", pkg.Name); + s1.tab("tab_basic", _("Basic Configuration")); + s1.tab("tab_advanced", _("Advanced Configuration")); + + var text = _( + "DNS resolution option, see the %sREADME%s for details." + ).format( + '<a href="' + pkg.URL + '#dns-resolver-option" target="_blank">', + "</a>" + ); + if (!reply.platform.dnsmasq_installed) { + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.addnhosts</i>" + ); + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.conf</i>" + ); + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.ipset</i>" + ); + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.servers</i>" + ); + } else { + if (!reply.platform.dnsmasq_ipset_support) { + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.ipset</i>" + ); + } + if (!reply.platform.dnsmasq_nftset_support) { + text += + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>dnsmasq.nftset</i>" + ); + } + } + if (!reply.platform.unbound_installed) { + text = + text + + "<br />" + + _("Please note that %s is not supported on this system.").format( + "<i>unbound.adb_list</i>" + ); + } + + o = s1.taboption( + "tab_basic", + form.ListValue, + "dns", + _("DNS Service"), + text + ); + if (reply.platform.dnsmasq_installed) { + o.value("dnsmasq.addnhosts", _("dnsmasq additional hosts")); + o.value("dnsmasq.conf", _("dnsmasq config")); + if (reply.platform.dnsmasq_ipset_support) { + o.value("dnsmasq.ipset", _("dnsmasq ipset")); + } + if (reply.platform.dnsmasq_nftset_support) { + o.value("dnsmasq.nftset", _("dnsmasq nft set")); + } + o.value("dnsmasq.servers", _("dnsmasq servers file")); + } + if (reply.platform.unbound_installed) { + o.value("unbound.adb_list", _("unbound adblock list")); + } + o.default = ("dnsmasq.servers", _("dnsmasq servers file")); + + o = s1.taboption( + "tab_basic", + form.Value, + "dnsmasq_config_file_url", + _("Dnsmasq Config File URL"), + _( + "URL to the external dnsmasq config file, see the %sREADME%s for details." + ).format( + '<a href="' + pkg.URL + '#dnsmasq_config_file_url" target="_blank">', + "</a>" + ) + ); + o.depends("dns", "dnsmasq.conf"); + + o = s1.taboption( + "tab_basic", + form.ListValue, + "dnsmasq_instance", + _("Use AdBlocking on the dnsmasq instance(s)"), + _( + "You can limit the AdBlocking to a specific dnsmasq instance(s) (%smore information%s)." + ).format( + '<a href="' + pkg.URL + "#dnsmasq_instance" + '" target="_blank">', + "</a>" + ) + ); + o.value("*", _("AdBlock on all instances")); + var sections = uci.sections("dhcp", "dnsmasq"); + sections.forEach((element) => { + var description; + var key; + if (element[".name"] === uci.resolveSID("dhcp", element[".name"])) { + key = element[".index"]; + description = "dnsmasq[" + element[".index"] + "]"; + } else { + key = element[".name"]; + description = element[".name"]; + } + o.value(key, _("AdBlock on %s only").format(description)); + }); + o.value("-", _("No AdBlock on dnsmasq")); + o.default = "*"; + o.depends("dns", "dnsmasq.addnhosts"); + o.depends("dns", "dnsmasq.servers"); + o.retain = true; + + o = s1.taboption( + "tab_basic", + form.ListValue, + "force_dns", + _("Force Router DNS"), + _("Forces Router DNS use on local devices, also known as DNS Hijacking.") + ); + o.value("0", _("Let local devices use their own DNS servers if set")); + o.value("1", _("Force Router DNS server to all local devices")); + o.default = ("1", _("Force Router DNS server to all local devices")); + + o = s1.taboption( + "tab_basic", + form.ListValue, + "verbosity", + _("Output Verbosity Setting"), + _("Controls system log and console output verbosity.") + ); + o.value("0", _("Suppress output")); + o.value("1", _("Some output")); + o.value("2", _("Verbose output")); + o.default = ("2", _("Verbose output")); + + if (reply.platform.leds.length) { + o = s1.taboption( + "tab_basic", + form.ListValue, + "led", + _("LED to indicate status"), + _( + "Pick the LED not already used in %sSystem LED Configuration%s." + ).format('<a href="' + L.url("admin", "system", "leds") + '">', "</a>") + ); + o.value("", _("none")); + reply.platform.leds.forEach((element) => { + o.value(element); + }); + } + o = s1.taboption( + "tab_advanced", + form.ListValue, + "config_update_enabled", + _("Automatic Config Update"), + _("Perform config update before downloading the block/allow-lists.") + ); + o.value("0", _("Disable")); + o.value("1", _("Enable")); + o.default = ("0", _("Disable")); + + o = s1.taboption( + "tab_advanced", + form.ListValue, + "ipv6_enabled", + _("IPv6 Support"), + _("Add IPv6 entries to block-list.") + ); + o.value("", _("Do not add IPv6 entries")); + o.value("1", _("Add IPv6 entries")); + o.depends("dns", "dnsmasq.addnhosts"); + o.depends("dns", "dnsmasq.nftset"); + o.default = ("", _("Do not add IPv6 entries")); + o.rmempty = true; + o.retain = true; + + o = s1.taboption( + "tab_advanced", + form.Value, + "download_timeout", + _("Download time-out (in seconds)"), + _("Stop the download if it is stalled for set number of seconds.") + ); + o.default = "20"; + o.datatype = "range(1,60)"; + + o = s1.taboption( + "tab_advanced", + form.Value, + "curl_max_file_size", + _("Curl maximum file size (in bytes)"), + _( + "If curl is installed and detected, it would not download files bigger than this." + ) + ); + o.default = ""; + o.datatype = "uinteger"; + o.rmempty = true; + + o = s1.taboption( + "tab_advanced", + form.Value, + "curl_retry", + _("Curl download retry"), + _( + "If curl is installed and detected, it would retry download this many times on timeout/fail." + ) + ); + o.default = "3"; + o.datatype = "range(0,30)"; + + o = s1.taboption( + "tab_advanced", + form.ListValue, + "parallel_downloads", + _("Simultaneous processing"), + _( + "Launch all lists downloads and processing simultaneously, reducing service start time." + ) + ); + o.value("0", _("Do not use simultaneous processing")); + o.value("1", _("Use simultaneous processing")); + o.default = ("1", _("Use simultaneous processing")); + + o = s1.taboption( + "tab_advanced", + form.ListValue, + "compressed_cache", + _("Store compressed cache file on router"), + _( + "Attempt to create a compressed cache of block-list in the persistent memory." + ) + ); + o.value("0", _("Do not store compressed cache")); + o.value("1", _("Store compressed cache")); + o.default = ("0", _("Do not store compressed cache")); + + o = s1.taboption( + "tab_advanced", + form.Value, + "compressed_cache_dir", + _("Directory for compressed cache file"), + _( + "Directory for compressed cache file of block-list in the persistent memory." + ) + ); + o.datatype = "string"; + o.rmempty = true; + o.default = "/etc"; + o.depends("compressed_cache", "1"); + o.retain = true; + + o = s1.taboption( + "tab_advanced", + form.ListValue, + "debug", + _("Enable Debugging"), + _("Enables debug output to /tmp/adblock-fast.log.") + ); + o.value("0", _("Disable Debugging")); + o.value("1", _("Enable Debugging")); + o.default = ("0", _("Disable Debugging")); + + s2 = m.section( + form.NamedSection, + "config", + "adblock-fast", + _("AdBlock-Fast - Allowed and Blocked Domains") + ); + o.addremove = true; + o.rmempty = true; + o = s2.option( + form.DynamicList, + "allowed_domain", + _("Allowed Domains"), + _("Individual domains to be allowed.") + ); + + o.addremove = true; + o = s2.option( + form.DynamicList, + "blocked_domain", + _("Blocked Domains"), + _("Individual domains to be blocked.") + ); + o.addremove = true; + + s3 = m.section( + form.GridSection, + "file_url", + _("AdBlock-Fast - Allowed and Blocked Lists URLs"), + _("URLs to file(s) containing lists to be allowed or blocked.") + ); + s3.rowcolors = true; + s3.sortable = true; + s3.anonymous = true; + s3.addremove = true; + o = s3.option(form.DummyValue, "_size", "Size"); + o.modalonly = false; + o.cfgvalue = function (section_id) { + let url = uci.get(pkg.Name, section_id, "url"); + let ret = _("Unknown"); + reply.sizes.forEach((element) => { + if (element.url === url) { + ret = element.size === 0 ? ret : pkg.humanFileSize(element.size); + } + }); + return _("Size: %s").format(ret); + }; + o = s3.option(form.Flag, "enabled", _("Enable")); + o.editable = true; + o.default = "1"; + o = s3.option(form.ListValue, "action", _("Action")); + o.value("allow", _("Allow")); + o.value("block", _("Block")); + o.default = "block"; + o = s3.option(form.Value, "url", _("URL")); + o.optional = false; + + return Promise.all([status.render(), m.render()]); + }, +}); diff --git a/applications/luci-app-simple-adblock/po/ar/simple-adblock.po b/applications/luci-app-adblock-fast/po/ar/adblock-fast.po index fb15dab8b7..fb15dab8b7 100644 --- a/applications/luci-app-simple-adblock/po/ar/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ar/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/bg/simple-adblock.po b/applications/luci-app-adblock-fast/po/bg/adblock-fast.po index c03c902b48..c03c902b48 100644 --- a/applications/luci-app-simple-adblock/po/bg/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/bg/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/bn_BD/simple-adblock.po b/applications/luci-app-adblock-fast/po/bn_BD/adblock-fast.po index 21493bd49e..21493bd49e 100644 --- a/applications/luci-app-simple-adblock/po/bn_BD/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/bn_BD/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ca/simple-adblock.po b/applications/luci-app-adblock-fast/po/ca/adblock-fast.po index 758a163a02..758a163a02 100644 --- a/applications/luci-app-simple-adblock/po/ca/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ca/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/cs/simple-adblock.po b/applications/luci-app-adblock-fast/po/cs/adblock-fast.po index 9b92709bc8..9b92709bc8 100644 --- a/applications/luci-app-simple-adblock/po/cs/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/cs/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/da/simple-adblock.po b/applications/luci-app-adblock-fast/po/da/adblock-fast.po index 858d27b0a5..858d27b0a5 100644 --- a/applications/luci-app-simple-adblock/po/da/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/da/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/de/simple-adblock.po b/applications/luci-app-adblock-fast/po/de/adblock-fast.po index e002b28f0c..e002b28f0c 100644 --- a/applications/luci-app-simple-adblock/po/de/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/de/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/el/simple-adblock.po b/applications/luci-app-adblock-fast/po/el/adblock-fast.po index c00f060c37..c00f060c37 100644 --- a/applications/luci-app-simple-adblock/po/el/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/el/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/en/simple-adblock.po b/applications/luci-app-adblock-fast/po/en/adblock-fast.po index 16a31bf6a0..16a31bf6a0 100644 --- a/applications/luci-app-simple-adblock/po/en/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/en/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/es/simple-adblock.po b/applications/luci-app-adblock-fast/po/es/adblock-fast.po index d8b3a82010..d8b3a82010 100644 --- a/applications/luci-app-simple-adblock/po/es/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/es/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/fi/simple-adblock.po b/applications/luci-app-adblock-fast/po/fi/adblock-fast.po index 3e87f8886b..3e87f8886b 100644 --- a/applications/luci-app-simple-adblock/po/fi/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/fi/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/fr/simple-adblock.po b/applications/luci-app-adblock-fast/po/fr/adblock-fast.po index 79af6281f5..79af6281f5 100644 --- a/applications/luci-app-simple-adblock/po/fr/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/fr/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/he/simple-adblock.po b/applications/luci-app-adblock-fast/po/he/adblock-fast.po index 52f35c48e5..52f35c48e5 100644 --- a/applications/luci-app-simple-adblock/po/he/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/he/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/hi/simple-adblock.po b/applications/luci-app-adblock-fast/po/hi/adblock-fast.po index 2cfb9553ff..2cfb9553ff 100644 --- a/applications/luci-app-simple-adblock/po/hi/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/hi/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/hu/simple-adblock.po b/applications/luci-app-adblock-fast/po/hu/adblock-fast.po index 26c8ca1e2e..26c8ca1e2e 100644 --- a/applications/luci-app-simple-adblock/po/hu/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/hu/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/it/simple-adblock.po b/applications/luci-app-adblock-fast/po/it/adblock-fast.po index f281df43b6..f281df43b6 100644 --- a/applications/luci-app-simple-adblock/po/it/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/it/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ja/simple-adblock.po b/applications/luci-app-adblock-fast/po/ja/adblock-fast.po index 8c236dc99d..8c236dc99d 100644 --- a/applications/luci-app-simple-adblock/po/ja/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ja/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ko/simple-adblock.po b/applications/luci-app-adblock-fast/po/ko/adblock-fast.po index e034445448..e034445448 100644 --- a/applications/luci-app-simple-adblock/po/ko/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ko/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/lt/simple-adblock.po b/applications/luci-app-adblock-fast/po/lt/adblock-fast.po index dda29bce15..dda29bce15 100644 --- a/applications/luci-app-simple-adblock/po/lt/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/lt/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/mr/simple-adblock.po b/applications/luci-app-adblock-fast/po/mr/adblock-fast.po index 7474db64ea..7474db64ea 100644 --- a/applications/luci-app-simple-adblock/po/mr/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/mr/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ms/simple-adblock.po b/applications/luci-app-adblock-fast/po/ms/adblock-fast.po index f638a96f14..f638a96f14 100644 --- a/applications/luci-app-simple-adblock/po/ms/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ms/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/nb_NO/simple-adblock.po b/applications/luci-app-adblock-fast/po/nb_NO/adblock-fast.po index c3e1a7fc4c..c3e1a7fc4c 100644 --- a/applications/luci-app-simple-adblock/po/nb_NO/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/nb_NO/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/pl/simple-adblock.po b/applications/luci-app-adblock-fast/po/pl/adblock-fast.po index 918ca107b7..918ca107b7 100644 --- a/applications/luci-app-simple-adblock/po/pl/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/pl/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/pt/simple-adblock.po b/applications/luci-app-adblock-fast/po/pt/adblock-fast.po index db029ffa17..db029ffa17 100644 --- a/applications/luci-app-simple-adblock/po/pt/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/pt/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/pt_BR/simple-adblock.po b/applications/luci-app-adblock-fast/po/pt_BR/adblock-fast.po index ab6395c232..ab6395c232 100644 --- a/applications/luci-app-simple-adblock/po/pt_BR/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/pt_BR/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ro/simple-adblock.po b/applications/luci-app-adblock-fast/po/ro/adblock-fast.po index 8fb5bb2d17..8fb5bb2d17 100644 --- a/applications/luci-app-simple-adblock/po/ro/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ro/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/ru/simple-adblock.po b/applications/luci-app-adblock-fast/po/ru/adblock-fast.po index aa90c9252a..aa90c9252a 100644 --- a/applications/luci-app-simple-adblock/po/ru/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/ru/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/sk/simple-adblock.po b/applications/luci-app-adblock-fast/po/sk/adblock-fast.po index 50243f556a..50243f556a 100644 --- a/applications/luci-app-simple-adblock/po/sk/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/sk/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/sv/simple-adblock.po b/applications/luci-app-adblock-fast/po/sv/adblock-fast.po index 142f670773..142f670773 100644 --- a/applications/luci-app-simple-adblock/po/sv/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/sv/adblock-fast.po diff --git a/applications/luci-app-adblock-fast/po/templates/adblock-fast.pot b/applications/luci-app-adblock-fast/po/templates/adblock-fast.pot new file mode 100644 index 0000000000..3a51e0a37f --- /dev/null +++ b/applications/luci-app-adblock-fast/po/templates/adblock-fast.pot @@ -0,0 +1,586 @@ +msgid "" +msgstr "Content-Type: text/plain; charset=UTF-8" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:223 +msgid "%s is currently disabled" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:106 +msgid "%s is not installed or not found" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:376 +msgid "Action" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:118 +msgid "Active" +msgstr "" + +#: applications/luci-app-adblock-fast/root/usr/share/luci/menu.d/luci-app-adblock-fast.json:3 +msgid "AdBlock Fast" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:168 +msgid "AdBlock on %s only" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:156 +msgid "AdBlock on all instances" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:331 +msgid "AdBlock-Fast - Allowed and Blocked Domains" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:354 +msgid "AdBlock-Fast - Allowed and Blocked Lists URLs" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:50 +msgid "AdBlock-Fast - Configuration" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:121 +msgid "AdBlock-Fast - Status" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:233 +msgid "Add IPv6 entries" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:230 +msgid "Add IPv6 entries to block-list." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:53 +msgid "Advanced Configuration" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:377 +msgid "Allow" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:338 +msgid "Allowed Domains" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:294 +msgid "" +"Attempt to create a compressed cache of block-list in the persistent memory." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:218 +msgid "Automatic Config Update" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:52 +msgid "Basic Configuration" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:378 +msgid "Block" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:346 +msgid "Blocked Domains" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:134 +msgid "Blocking %s domains (with %s)." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:160 +msgid "Cache file found." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:139 +msgid "Compressed cache file created." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:162 +msgid "Compressed cache file found." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:221 +msgid "Config (%s) validation failure!" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:192 +msgid "Controls system log and console output verbosity." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:267 +msgid "Curl download retry" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:254 +msgid "Curl maximum file size (in bytes)" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:111 +msgid "DNS Service" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:56 +msgid "DNS resolution option, see the %sREADME%s for details." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:305 +msgid "Directory for compressed cache file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:307 +msgid "" +"Directory for compressed cache file of block-list in the persistent memory." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:400 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:221 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:223 +msgid "Disable" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:323 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:325 +msgid "Disable Debugging" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:156 +msgid "Disabled" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:394 +msgid "Disabling %s service" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:134 +msgid "Dnsmasq Config File URL" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:232 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:236 +msgid "Do not add IPv6 entries" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:297 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:299 +msgid "Do not store compressed cache" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:284 +msgid "Do not use simultaneous processing" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:244 +msgid "Download time-out (in seconds)" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:114 +msgid "Downloading lists" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:381 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:222 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:373 +msgid "Enable" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:320 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:324 +msgid "Enable Debugging" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:321 +msgid "Enables debug output to /tmp/adblock-fast.log." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:375 +msgid "Enabling %s service" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:115 +msgid "Error" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:289 +msgid "Errors encountered, please check the %sREADME%s!" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:117 +msgid "Fail" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:246 +msgid "Failed to access shared memory" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:242 +msgid "Failed to create '%s' file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:264 +msgid "Failed to create block-list or restart DNS resolver" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:255 +msgid "Failed to create compressed cache" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:241 +msgid "Failed to create directory for %s file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:276 +msgid "Failed to create output/cache/gzip file directory" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:271 +msgid "Failed to download %s" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:269 +msgid "Failed to download Config Update file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:250 +msgid "Failed to format data file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:259 +msgid "Failed to move '%s' to '%s'" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:252 +msgid "Failed to move temporary data file to '%s'" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:248 +msgid "Failed to optimize data file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:273 +msgid "Failed to parse" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:272 +msgid "Failed to parse Config Update file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:249 +msgid "Failed to process allow-list" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:267 +msgid "Failed to reload/restart DNS resolver" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:257 +msgid "Failed to remove temporary files" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:245 +msgid "Failed to restart/reload DNS resolver" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:247 +msgid "Failed to sort data file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:266 +msgid "Failed to stop %s" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:258 +msgid "Failed to unpack compressed cache" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:142 +msgid "Force DNS ports:" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:343 +msgid "Force Re-Download" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:113 +msgid "Force Reloading" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:180 +msgid "Force Router DNS" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:184 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:185 +msgid "Force Router DNS server to all local devices" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:337 +msgid "Force re-downloading %s block lists" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:181 +msgid "Forces Router DNS use on local devices, also known as DNS Hijacking." +msgstr "" + +#: applications/luci-app-adblock-fast/root/usr/share/rpcd/acl.d/luci-app-adblock-fast.json:3 +msgid "Grant UCI and file access for luci-app-adblock-fast" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:229 +msgid "IPv6 Support" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:256 +msgid "" +"If curl is installed and detected, it would not download files bigger than " +"this." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:269 +msgid "" +"If curl is installed and detected, it would retry download this many times " +"on timeout/fail." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:339 +msgid "Individual domains to be allowed." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:347 +msgid "Individual domains to be blocked." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:204 +msgid "LED to indicate status" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:281 +msgid "" +"Launch all lists downloads and processing simultaneously, reducing service " +"start time." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:183 +msgid "Let local devices use their own DNS servers if set" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:170 +msgid "No AdBlock on dnsmasq" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:274 +msgid "No HTTPS/SSL support on device" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:176 +msgid "Not installed or not found" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:191 +msgid "Output Verbosity Setting" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:219 +msgid "Perform config update before downloading the block/allow-lists." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:206 +msgid "Pick the LED not already used in %sSystem LED Configuration%s." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:64 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:69 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:74 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:79 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:86 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:93 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:102 +msgid "Please note that %s is not supported on this system." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:111 +msgid "Processing lists" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:112 +msgid "Restarting" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:437 +msgid "Service Control" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:282 +msgid "Service Errors" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:125 +msgid "Service Status" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:198 +msgid "Service Warnings" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:279 +msgid "Simultaneous processing" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:371 +msgid "Size: %s" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:195 +msgid "Some output" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:192 +msgid "Some recommended packages are missing" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:324 +msgid "Start" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:110 +msgid "Starting" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:318 +msgid "Starting %s service" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:362 +msgid "Stop" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:245 +msgid "Stop the download if it is stalled for set number of seconds." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:109 +msgid "Stopped" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:356 +msgid "Stopping %s service" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:298 +msgid "Store compressed cache" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:292 +msgid "Store compressed cache file on router" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:194 +msgid "Suppress output" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:239 +msgid "The %s failed to discover WAN gateway" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:227 +msgid "" +"The dnsmasq ipset support is enabled, but dnsmasq is either not installed or " +"installed dnsmasq does not support ipset" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:230 +msgid "" +"The dnsmasq ipset support is enabled, but ipset is either not installed or " +"installed ipset does not support '%s' type" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:233 +msgid "" +"The dnsmasq nft set support is enabled, but dnsmasq is either not installed " +"or installed dnsmasq does not support nft set" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:236 +msgid "The dnsmasq nft sets support is enabled, but nft is not installed" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:380 +msgid "URL" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:136 +msgid "" +"URL to the external dnsmasq config file, see the %sREADME%s for details." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:355 +msgid "URLs to file(s) containing lists to be allowed or blocked." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:365 +msgid "Unknown" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:148 +msgid "Use AdBlocking on the dnsmasq instance(s)" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:189 +msgid "" +"Use of external dnsmasq config file detected, please set '%s' option to '%s'" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:285 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:286 +msgid "Use simultaneous processing" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:196 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:197 +msgid "Verbose output" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:128 +msgid "Version %s" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/adblock-fast/status.js:116 +msgid "Warning" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:150 +msgid "" +"You can limit the AdBlocking to a specific dnsmasq instance(s) (%smore " +"information%s)." +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:115 +msgid "dnsmasq additional hosts" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:116 +msgid "dnsmasq config" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:118 +msgid "dnsmasq ipset" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:121 +msgid "dnsmasq nft set" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:123 +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:128 +msgid "dnsmasq servers file" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:209 +msgid "none" +msgstr "" + +#: applications/luci-app-adblock-fast/htdocs/luci-static/resources/view/adblock-fast/overview.js:126 +msgid "unbound adblock list" +msgstr "" diff --git a/applications/luci-app-simple-adblock/po/tr/simple-adblock.po b/applications/luci-app-adblock-fast/po/tr/adblock-fast.po index 8136a07c0b..8136a07c0b 100644 --- a/applications/luci-app-simple-adblock/po/tr/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/tr/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/uk/simple-adblock.po b/applications/luci-app-adblock-fast/po/uk/adblock-fast.po index 3758d4305c..3758d4305c 100644 --- a/applications/luci-app-simple-adblock/po/uk/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/uk/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/vi/simple-adblock.po b/applications/luci-app-adblock-fast/po/vi/adblock-fast.po index f4c1988d28..f4c1988d28 100644 --- a/applications/luci-app-simple-adblock/po/vi/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/vi/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/zh_Hans/simple-adblock.po b/applications/luci-app-adblock-fast/po/zh_Hans/adblock-fast.po index 3b701d57fe..3b701d57fe 100644 --- a/applications/luci-app-simple-adblock/po/zh_Hans/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/zh_Hans/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/po/zh_Hant/simple-adblock.po b/applications/luci-app-adblock-fast/po/zh_Hant/adblock-fast.po index 3a9460ba38..3a9460ba38 100644 --- a/applications/luci-app-simple-adblock/po/zh_Hant/simple-adblock.po +++ b/applications/luci-app-adblock-fast/po/zh_Hant/adblock-fast.po diff --git a/applications/luci-app-simple-adblock/root/etc/uci-defaults/40_luci-simple-adblock b/applications/luci-app-adblock-fast/root/etc/uci-defaults/40_luci-adblock-fast index 080086891a..080086891a 100644 --- a/applications/luci-app-simple-adblock/root/etc/uci-defaults/40_luci-simple-adblock +++ b/applications/luci-app-adblock-fast/root/etc/uci-defaults/40_luci-adblock-fast diff --git a/applications/luci-app-simple-adblock/root/usr/libexec/rpcd/luci.simple-adblock b/applications/luci-app-adblock-fast/root/usr/libexec/rpcd/luci.adblock-fast index 8cd40ca72a..b85a93f2e6 100755 --- a/applications/luci-app-simple-adblock/root/usr/libexec/rpcd/luci.simple-adblock +++ b/applications/luci-app-adblock-fast/root/usr/libexec/rpcd/luci.adblock-fast @@ -1,21 +1,22 @@ #!/bin/sh -# Copyright 2022 Stan Grishin (stangri@melmac.ca) +# Copyright 2023 MOSSDeF, Stan Grishin (stangri@melmac.ca) # shellcheck disable=SC1091,SC2018,SC2019,SC2039,SC3043,SC3057,SC3060 # TechRef: https://openwrt.org/docs/techref/rpcd # TESTS -# ubus -v list luci.simple-adblock -# ubus -S call luci.simple-adblock getInitList '{"name": "simple-adblock" }' -# ubus -S call luci.simple-adblock getInitStatus '{"name": "simple-adblock" }' -# ubus -S call luci.simple-adblock setInitAction '{"name": "simple-adblock", "action": "start" }' -# ubus -S call luci.simple-adblock setInitAction '{"name": "simple-adblock", "action": "stop" }' -# ubus -S call luci.simple-adblock getPlatformSupport '{"name": "simple-adblock" }' +# ubus -v list luci.adblock-fast +# ubus -S call luci.adblock-fast getFileUrlFilesizes '{"name": "adblock-fast" }' +# ubus -S call luci.adblock-fast getInitList '{"name": "adblock-fast" }' +# ubus -S call luci.adblock-fast getInitStatus '{"name": "adblock-fast" }' +# ubus -S call luci.adblock-fast getPlatformSupport '{"name": "adblock-fast" }' +# ubus -S call luci.adblock-fast setInitAction '{"name": "adblock-fast", "action": "start" }' +# ubus -S call luci.adblock-fast setInitAction '{"name": "adblock-fast", "action": "stop" }' . /lib/functions.sh . /lib/functions/network.sh . /usr/share/libubox/jshn.sh -readonly packageName="simple-adblock" +readonly packageName="adblock-fast" readonly dnsmasqAddnhostsFile="/var/run/${packageName}/dnsmasq.addnhosts" readonly dnsmasqAddnhostsCache="/var/run/${packageName}/dnsmasq.addnhosts.cache" readonly dnsmasqAddnhostsGzip="${packageName}.dnsmasq.addnhosts.gz" @@ -34,7 +35,7 @@ readonly dnsmasqServersGzip="${packageName}.dnsmasq.servers.gz" readonly unboundFile="/var/lib/unbound/adb_list.${packageName}" readonly unboundCache="/var/run/${packageName}/unbound.cache" readonly unboundGzip="${packageName}.unbound.gz" -readonly jsonFile="/var/run/${packageName}/${packageName}.json" +readonly jsonFile="/dev/shm/$packageName-status.json" str_contains() { [ -n "$1" ] &&[ -n "$2" ] && [ "${1//$2}" != "$1" ]; } str_contains_word() { echo "$1" | grep -q -w "$2"; } @@ -43,10 +44,12 @@ str_to_upper() { echo "$1" | tr 'a-z' 'A-Z'; } is_enabled() { uci -q get "${1}.config.enabled"; } get_version() { grep -m1 -A2 -w "^Package: $1$" /usr/lib/opkg/status | sed -n 's/Version: //p'; } print_json_bool() { json_init; json_add_boolean "$1" "$2"; json_dump; json_cleanup; } +print_json_int() { json_init; json_add_int "$1" "$2"; json_dump; json_cleanup; } print_json_string() { json_init; json_add_string "$1" "$2"; json_dump; json_cleanup; } logger() { /usr/bin/logger -t "$packageName" "$@"; } ubus_get_status() { ubus call service list "{ 'name': '$packageName' }" | jsonfilter -e "@['${packageName}'].instances.main.data.${1}"; } ubus_get_ports() { ubus call service list "{ 'name': '$packageName' }" | jsonfilter -e "@['${packageName}'].instances.main.data.firewall.*.dest_port"; } +is_present() { command -v "$1" >/dev/null 2>&1; } sanitize_dir() { [ -d "$(readlink -fn "$1")" ] && readlink -fn "$1"; } json() { # shellcheck disable=SC2034 @@ -68,6 +71,39 @@ json() { esac } +get_url_filesize() { + local url="$1" size size_command + [ -n "$url" ] || { print_json_int 'size' '0'; return 0; } + is_present 'curl' || { print_json_int 'size' '0'; return 0; } + size_command='curl --silent --insecure --fail --head --request GET' + size="$($size_command "$url" | grep -i 'content-length:' | awk '{print $2}'; )" + echo "$size" +} + +_get_file_url_size() { + local url size + config_get url "$1" 'url' + config_get size "$1" 'size' + [ -n "$size" ] || size="$(get_url_filesize "$url")" + json_add_object + json_add_string 'url' "$url" + json_add_int 'size' "$size" + json_close_object +} + +get_file_url_filesizes() { + local name="$1" i + json_init + json_add_object "$name" + json_add_array 'sizes' + config_load "$name" + config_foreach _get_file_url_size 'file_url' + json_close_array + json_close_object + json_dump + json_cleanup +} + get_init_list() { local name name="$(basename "$1")" @@ -123,9 +159,6 @@ get_init_status() { else compressed_cache_dir="/etc" fi - errors="$(ubus_get_status errors)" - warnings="$(ubus_get_status warnings)" - ports="$(ubus_get_ports)" if [ -n "$(uci -q get $packageName.config.dnsmasq_config_file_url)" ]; then dns="dnsmasq.conf" else @@ -178,6 +211,7 @@ get_init_status() { json_add_boolean 'running' '0' fi json_add_string 'version' "$(get_version "$name")" + errors="$(ubus_get_status errors)" json_add_array 'errors' if [ -n "$errors" ]; then for i in $errors; do @@ -195,6 +229,7 @@ get_init_status() { done fi json_close_array + warnings="$(ubus_get_status warnings)" json_add_array 'warnings' if [ -n "$warnings" ]; then for i in $warnings; do @@ -213,6 +248,7 @@ get_init_status() { fi json_close_array + ports="$(ubus_get_ports)" if [ -n "$ports" ]; then json_add_boolean 'force_dns_active' '1' json_add_array 'force_dns_ports' @@ -313,6 +349,9 @@ get_platform_support() { case "$1" in list) json_init + json_add_object "getFileUrlFilesizes" + json_add_string 'name' 'name' + json_close_object json_add_object "getInitList" json_add_string 'name' 'name' json_close_object @@ -331,6 +370,13 @@ case "$1" in ;; call) case "$2" in + getFileUrlFilesizes) + read -r input + json_load "$input" + json_get_var name 'name' + json_cleanup + get_file_url_filesizes "$name" + ;; getInitList) read -r input json_load "$input" diff --git a/applications/luci-app-adblock-fast/root/usr/share/luci/menu.d/luci-app-adblock-fast.json b/applications/luci-app-adblock-fast/root/usr/share/luci/menu.d/luci-app-adblock-fast.json new file mode 100644 index 0000000000..542a75988c --- /dev/null +++ b/applications/luci-app-adblock-fast/root/usr/share/luci/menu.d/luci-app-adblock-fast.json @@ -0,0 +1,17 @@ +{ + "admin/services/adblock-fast": { + "title": "AdBlock Fast", + "action": { + "type": "view", + "path": "adblock-fast/overview" + }, + "depends": { + "acl": [ + "luci-app-adblock-fast" + ], + "uci": { + "adblock-fast": true + } + } + } +} diff --git a/applications/luci-app-adblock-fast/root/usr/share/rpcd/acl.d/luci-app-adblock-fast.json b/applications/luci-app-adblock-fast/root/usr/share/rpcd/acl.d/luci-app-adblock-fast.json new file mode 100644 index 0000000000..4ae446af6f --- /dev/null +++ b/applications/luci-app-adblock-fast/root/usr/share/rpcd/acl.d/luci-app-adblock-fast.json @@ -0,0 +1,32 @@ +{ + "luci-app-adblock-fast": { + "description": "Grant UCI and file access for luci-app-adblock-fast", + "read": { + "file": { + "/dev/shm/adblock-fast-status.json": [ "list", "read" ] + }, + "ubus": { + "luci.adblock-fast": [ + "getFileUrlFilesizes", + "getInitList", + "getInitStatus", + "getPlatformSupport" + ] + }, + "uci": [ + "adblock-fast", + "dhcp" + ] + }, + "write": { + "uci": [ + "adblock-fast" + ], + "ubus": { + "luci.adblock-fast": [ + "setInitAction" + ] + } + } + } +} diff --git a/applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js b/applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js deleted file mode 100644 index 6c5ef19c11..0000000000 --- a/applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js +++ /dev/null @@ -1,323 +0,0 @@ -// Copyright 2022 Stan Grishin <stangri@melmac.ca> -// This code wouldn't have been possible without help from [@vsviridov](https://github.com/vsviridov) - -"require ui"; -"require rpc"; -"require form"; -"require baseclass"; - -var pkg = { - get Name() { return 'simple-adblock'; }, - get URL() { return 'https://docs.openwrt.melmac.net/' + pkg.Name + '/'; }, -}; - -var getInitList = rpc.declare({ - object: "luci." + pkg.Name, - method: "getInitList", - params: ["name"], -}); - -var getInitStatus = rpc.declare({ - object: "luci." + pkg.Name, - method: "getInitStatus", - params: ["name"], -}); - -var getPlatformSupport = rpc.declare({ - object: "luci." + pkg.Name, - method: "getPlatformSupport", - params: ["name"], -}); - -var _setInitAction = rpc.declare({ - object: "luci." + pkg.Name, - method: "setInitAction", - params: ["name", "action"], - expect: { result: false }, -}); - -var RPC = { - listeners: [], - on: function on(event, callback) { - var pair = { event: event, callback: callback } - this.listeners.push(pair); - return function unsubscribe() { - this.listeners = this.listeners.filter(function (listener) { - return listener !== pair; - }); - }.bind(this); - }, - emit: function emit(event, data) { - this.listeners.forEach(function (listener) { - if (listener.event === event) { - listener.callback(data); - } - }); - }, - getInitList: function getInitList(name) { - getInitList(name).then(function (result) { - this.emit('getInitList', result); - }.bind(this)); - }, - getInitStatus: function getInitStatus(name) { - getInitStatus(name).then(function (result) { - this.emit('getInitStatus', result); - }.bind(this)); - }, - getPlatformSupport: function getPlatformSupport(name) { - getPlatformSupport(name).then(function (result) { - this.emit('getPlatformSupport', result); - }.bind(this)); - }, - setInitAction: function setInitAction(name, action) { - _setInitAction(name, action).then(function (result) { - this.emit('setInitAction', result); - }.bind(this)); - }, -} - -var status = baseclass.extend({ - render: function () { - return Promise.all([ - L.resolveDefault(getInitStatus(pkg.Name), {}), - ]).then(function (data) { - var replyStatus = data[0]; - var text =""; - var reply = replyStatus[pkg.Name]; - var outputFile = reply.outputFile; - var outputCache = reply.outputCache; - var statusTable = { - statusNoInstall: _("%s is not installed or not found").format(pkg.Name), - statusStopped: _("Stopped"), - statusStarting: _("Starting"), - statusProcessing: _("Processing lists"), - statusRestarting: _("Restarting"), - statusForceReloading: _("Force Reloading"), - statusDownloading: _("Downloading lists"), - statusError: _("Error"), - statusWarning: _("Warning"), - statusFail: _("Fail"), - statusSuccess: _("Active") - }; - - var header = E('h2', {}, _("Simple AdBlock - Status")) - var statusTitle = E('label', { class: 'cbi-value-title' }, _("Service Status")); - if (reply.version) { - text += _("Version %s").format(reply.version) + " - "; - switch (reply.status) { - case 'statusSuccess': - text += statusTable[reply.status] + "."; - text += "<br />" + _("Blocking %s domains (with %s).").format(reply.entries, reply.dns); - if (reply.outputGzipExists) { - text += "<br />" + _("Compressed cache file created."); - } - if (reply.force_dns_active) { - text += "<br />" + _("Force DNS ports:"); - reply.force_dns_ports.forEach(element => { - text += " " + element; - }); - text += "."; - } - break; - case 'statusStopped': - if (reply.enabled) { - text += statusTable[reply.status] + "."; - } - else { - text += statusTable[reply.status] + _("disabled") + "." - } - if (reply.outputCacheExists) { - text += "<br />" + _("Cache file found."); - } - else if (reply.outputGzipExists) { - text += "<br />" + _("Compressed cache file found."); - } - break; - case 'statusRestarting': - case 'statusForceReloading': - case 'statusDownloading': - case 'statusProcessing': - text += statusTable[reply.status] + "..."; - break; - default: - text += statusTable[reply.status] + "."; - break; - } - } - else { - text = _("Not installed or not found"); - } - var statusText = E('div', {}, text); - var statusField = E('div', { class: 'cbi-value-field' }, statusText); - var statusDiv = E('div', { class: 'cbi-value' }, [statusTitle, statusField]); - - var warningsDiv = []; - if (reply.warnings && reply.warnings.length) { - var warningTable = { - warningExternalDnsmasqConfig: _("use of external dnsmasq config file detected, please set '%s' option to '%s'").format("dns", "dnsmasq.conf"), - warningMissingRecommendedPackages: _("some recommended packages are missing") - } - var warningsTitle = E('label', { class: 'cbi-value-title' }, _("Service Warnings")); - var text = ""; - (reply.warnings).forEach(element => { - text += (warningTable[element.id]).format(element.extra || ' ') + "<br />"; - }); - var warningsText = E('div', {}, text); - var warningsField = E('div', { class: 'cbi-value-field' }, warningsText); - warningsDiv = E('div', { class: 'cbi-value' }, [warningsTitle, warningsField]); - } - - var errorsDiv = []; - if (reply.errors && reply.errors.length) { - var errorTable = { - errorConfigValidationFail: _("config (%s) validation failure!").format('/etc/config/' + pkg.Name), - errorServiceDisabled: _("%s is currently disabled").format(pkg.Name), - errorNoDnsmasqIpset: _("dnsmasq ipset support is enabled, but dnsmasq is either not installed or installed dnsmasq does not support ipset"), - errorNoIpset: _("dnsmasq ipset support is enabled, but ipset is either not installed or installed ipset does not support '%s' type").format("hash:net"), - errorNoDnsmasqNftset: _("dnsmasq nft set support is enabled, but dnsmasq is either not installed or installed dnsmasq does not support nft set"), - errorNoNft: _("dnsmasq nft sets support is enabled, but nft is not installed"), - errorNoWanGateway: _("the %s failed to discover WAN gateway").format(pkg.Name), - errorOutputDirCreate: _("failed to create directory for %s file"), - errorOutputFileCreate: _("failed to create '%s' file").format(outputFile), - errorFailDNSReload: _("failed to restart/reload DNS resolver"), - errorSharedMemory: _("failed to access shared memory"), - errorSorting: _("failed to sort data file"), - errorOptimization: _("failed to optimize data file"), - errorAllowListProcessing: _("failed to process allow-list"), - errorDataFileFormatting: _("failed to format data file"), - errorMovingDataFile: _("failed to move temporary data file to '%s'").format(outputFile), - errorCreatingCompressedCache: _("failed to create compressed cache"), - errorRemovingTempFiles: _("failed to remove temporary files"), - errorRestoreCompressedCache: _("failed to unpack compressed cache"), - errorRestoreCache: _("failed to move '%s' to '%s'").format(outputCache, outputFile), - errorOhSnap: _("failed to create block-list or restart DNS resolver"), - errorStopping: _("failed to stop %s").format(pkg.Name), - errorDNSReload: _("failed to reload/restart DNS resolver"), - errorDownloadingConfigUpdate: _("failed to download Config Update file"), - errorDownloadingList: _("failed to download"), - errorParsingConfigUpdate: _("failed to parse Config Update file"), - errorParsingList: _("failed to parse"), - errorNoSSLSupport: _("no HTTPS/SSL support on device"), - errorCreatingDirectory: _("failed to create output/cache/gzip file directory") - } - var errorsTitle = E('label', { class: 'cbi-value-title' }, _("Service Errors")); - var text = ""; - (reply.errors).forEach(element => { - text += (errorTable[element.id]).format(element.extra || ' ') + "<br />"; - }); - var errorsText = E('div', {}, text); - var errorsField = E('div', { class: 'cbi-value-field' }, errorsText); - errorsDiv = E('div', { class: 'cbi-value' }, [errorsTitle, errorsField]); - } - - var btn_gap = E('span', {}, '  '); - var btn_gap_long = E('span', {}, '        '); - - var btn_start = E('button', { - 'class': 'btn cbi-button cbi-button-apply', - disabled: true, - click: function (ev) { - ui.showModal(null, [ - E('p', { 'class': 'spinning' }, _('Starting %s service').format(pkg.Name)) - ]); - return RPC.setInitAction(pkg.Name, 'start'); - } - }, _('Start')); - - var btn_action = E('button', { - 'class': 'btn cbi-button cbi-button-apply', - disabled: true, - click: function (ev) { - ui.showModal(null, [ - E('p', { 'class': 'spinning' }, _('Force re-downloading %s block lists').format(pkg.Name)) - ]); - return RPC.setInitAction(pkg.Name, 'dl'); - } - }, _('Force Re-Download')); - - var btn_stop = E('button', { - 'class': 'btn cbi-button cbi-button-reset', - disabled: true, - click: function (ev) { - ui.showModal(null, [ - E('p', { 'class': 'spinning' }, _('Stopping %s service').format(pkg.Name)) - ]); - return RPC.setInitAction(pkg.Name, 'stop'); - } - }, _('Stop')); - - var btn_enable = E('button', { - 'class': 'btn cbi-button cbi-button-apply', - disabled: true, - click: function (ev) { - ui.showModal(null, [ - E('p', { 'class': 'spinning' }, _('Enabling %s service').format(pkg.Name)) - ]); - return RPC.setInitAction(pkg.Name, 'enable'); - } - }, _('Enable')); - - var btn_disable = E('button', { - 'class': 'btn cbi-button cbi-button-reset', - disabled: true, - click: function (ev) { - ui.showModal(null, [ - E('p', { 'class': 'spinning' }, _('Disabling %s service').format(pkg.Name)) - ]); - return RPC.setInitAction(pkg.Name, 'disable'); - } - }, _('Disable')); - - if (reply.enabled) { - btn_enable.disabled = true; - btn_disable.disabled = false; - switch (reply.status) { - case 'statusSuccess': - btn_start.disabled = true; - btn_action.disabled = false; - btn_stop.disabled = false; - break; - case 'statusStopped': - btn_start.disabled = false; - btn_action.disabled = true; - btn_stop.disabled = true; - break; - default: - btn_start.disabled = false; - btn_action.disabled = true; - btn_stop.disabled = false; - btn_enable.disabled = true; - btn_disable.disabled = true; - break; - } - } - else { - btn_start.disabled = true; - btn_action.disabled = true; - btn_stop.disabled = true; - btn_enable.disabled = false; - btn_disable.disabled = true; - } - - var buttonsDiv = []; - var buttonsTitle = E('label', { class: 'cbi-value-title' }, _("Service Control")) - var buttonsText = E('div', {}, [btn_start, btn_gap, btn_action, btn_gap, btn_stop, btn_gap_long, btn_enable, btn_gap, btn_disable]); - var buttonsField = E('div', { class: 'cbi-value-field' }, buttonsText); - if (reply.version) { - buttonsDiv = E('div', { class: 'cbi-value' }, [buttonsTitle, buttonsField]); - } - - return E('div', {}, [header, statusDiv, warningsDiv, errorsDiv, buttonsDiv]); - }); - }, -}); - -RPC.on('setInitAction', function (reply) { - ui.hideModal(); - location.reload(); -}); - -return L.Class.extend({ - status: status, - getPlatformSupport: getPlatformSupport -}); diff --git a/applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js b/applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js deleted file mode 100644 index c0066dd100..0000000000 --- a/applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js +++ /dev/null @@ -1,187 +0,0 @@ -// Copyright 2022 Stan Grishin <stangri@melmac.ca> -// This code wouldn't have been possible without help from [@vsviridov](https://github.com/vsviridov) - -'use strict'; -'require form'; -'require uci'; -'require view'; -'require simple-adblock.status as adb'; - -var pkg = { - get Name() { return 'simple-adblock'; }, - get URL() { return 'https://docs.openwrt.melmac.net/' + pkg.Name + '/'; } -}; - -return view.extend({ - load: function () { - return Promise.all([ - uci.load(pkg.Name) - ]); - }, - - render: function () { - return Promise.all([ - L.resolveDefault(adb.getPlatformSupport(pkg.Name), {}), - ]).then(function (data) { - var replyPlatform = data[0]; - var status, m, s, o; - - status = new adb.status(); - m = new form.Map(pkg.Name, _("Simple AdBlock - Configuration")); - s = m.section(form.NamedSection, 'config', pkg.Name); - s.tab("tab_basic", _("Basic Configuration")); - s.tab("tab_advanced", _("Advanced Configuration")); - - o = s.taboption("tab_basic", form.ListValue, "config_update_enabled", _("Automatic Config Update"), - _("Perform config update before downloading the block/allow-lists.")); - o.value("0", _("Disable")); - o.value("1", _("Enable")); - o.default = ("0", _("Disable")); - - o = s.taboption("tab_basic", form.ListValue, "verbosity", _("Output Verbosity Setting"), - _("Controls system log and console output verbosity.")); - o.value("0", _("Suppress output")); - o.value("1", _("Some output")); - o.value("2", _("Verbose output")); - o.default = ("2", _("Verbose output")); - - o = s.taboption("tab_basic", form.ListValue, "force_dns", _("Force Router DNS"), - _("Forces Router DNS use on local devices, also known as DNS Hijacking.")); - o.value("0", _("Let local devices use their own DNS servers if set")); - o.value("1", _("Force Router DNS server to all local devices")); - o.default = ("1", _("Force Router DNS server to all local devices")); - - - if ((replyPlatform[pkg.Name].leds).length) { - o = s.taboption("tab_basic", form.ListValue, "led", _("LED to indicate status"), - _("Pick the LED not already used in %sSystem LED Configuration%s.").format("<a href=\"" + - L.url("admin", "system", "leds") + "\">", "</a>")); - o.value("", _("none")); - (replyPlatform[pkg.Name].leds).forEach(element => { - o.value(element); - }); - } - var text = _("DNS resolution option, see the %sREADME%s for details.") - .format("<a href=\"" + pkg.URL + "#dns-resolution-option\" target=\"_blank\">", "</a>"); - if (!(replyPlatform[pkg.Name].dnsmasq_installed)) { - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.addnhosts</i>"); - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.conf</i>"); - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.ipset</i>"); - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.servers</i>"); - } - else { - if (!(replyPlatform[pkg.Name].dnsmasq_ipset_support)) { - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.ipset</i>"); - } - if (!(replyPlatform[pkg.Name].dnsmasq_nftset_support)) { - text += "<br />" + _("Please note that %s is not supported on this system.").format("<i>dnsmasq.nftset</i>"); - } - } - if (!(replyPlatform[pkg.Name].unbound_installed)) { - text = text + "<br />" + _("Please note that %s is not supported on this system.") - .format("<i>unbound.adb_list</i>"); - } - - o = s.taboption("tab_advanced", form.ListValue, "dns", _("DNS Service"), text); - if (replyPlatform[pkg.Name].dnsmasq_installed) { - o.value("dnsmasq.addnhosts", _("dnsmasq additional hosts")); - o.value("dnsmasq.conf", _("dnsmasq config")); - if (replyPlatform[pkg.Name].dnsmasq_ipset_support) { - o.value("dnsmasq.ipset", _("dnsmasq ipset")); - } - if (replyPlatform[pkg.Name].dnsmasq_nftset_support) { - o.value("dnsmasq.nftset", _("dnsmasq nft set")); - } - o.value("dnsmasq.servers", _("dnsmasq servers file")); - } - if (replyPlatform[pkg.Name].unbound_installed) { - o.value("unbound.adb_list", _("unbound adblock list")); - } - o.default = ("dnsmasq.servers", _("dnsmasq servers file")); - - o = s.taboption("tab_advanced", form.ListValue, "ipv6_enabled", _("IPv6 Support"), - _("Add IPv6 entries to block-list.")); - o.value("", _("Do not add IPv6 entries")); - o.value("1", _("Add IPv6 entries")); - o.depends('dns', 'dnsmasq.addnhosts'); - o.depends('dns', 'dnsmasq.nftset'); - o.default = ("", _("Do not add IPv6 entries")); - o.rmempty = true; - - o = s.taboption("tab_advanced", form.Value, "download_timeout", _("Download time-out (in seconds)"), - _("Stop the download if it is stalled for set number of seconds.")); - o.default = "20"; - o.datatype = "range(1,60)"; - - o = s.taboption("tab_advanced", form.Value, "curl_max_file_size", _("Curl maximum file size (in bytes)"), - _("If curl is installed and detected, it would not download files bigger than this.")); - o.default = ""; - o.datatype = "uinteger"; - o.rmempty = true; - - o = s.taboption("tab_advanced", form.Value, "curl_retry", _("Curl download retry"), - _("If curl is installed and detected, it would retry download this many times on timeout/fail.")); - o.default = "3"; - o.datatype = "range(0,30)"; - - o = s.taboption("tab_advanced", form.ListValue, "parallel_downloads", _("Simultaneous processing"), - _("Launch all lists downloads and processing simultaneously, reducing service start time.")); - o.value("0", _("Do not use simultaneous processing")); - o.value("1", _("Use simultaneous processing")); - o.default = ("1", _("Use simultaneous processing")); - - o = s.taboption("tab_advanced", form.ListValue, "compressed_cache", _("Store compressed cache file on router"), - _("Attempt to create a compressed cache of block-list in the persistent memory.")); - o.value("0", _("Do not store compressed cache")); - o.value("1", _("Store compressed cache")); - o.default = ("0", _("Do not store compressed cache")); - - o = s.taboption("tab_advanced", form.Value, "compressed_cache_dir", _("Directory for compressed cache file"), - _("Directory for compressed cache file of block-list in the persistent memory.")); - o.datatype = 'string'; - o.rmempty = true; - o.default = ("/etc"); - o.depends('compressed_cache', '1'); - - o = s.taboption("tab_advanced", form.ListValue, "debug", _("Enable Debugging"), - _("Enables debug output to /tmp/simple-adblock.log.")); - o.value("0", _("Disable Debugging")); - o.value("1", _("Enable Debugging")); - o.default = ("0", _("Disable Debugging")); - - s = m.section(form.NamedSection, "config", "simple-adblock", - _("Allowed and Blocked Lists Management")); - o = s.option(form.Value, "dnsmasq_config_file_url", _("Dnsmasq Config File URL"), - _("URL to the external dnsmasq config file, see the %sREADME%s for details.") - .format("<a href=\"" + pkg.URL + "#dnsmasq_config_file_url\" target=\"_blank\">", "</a>")); - o.addremove = true; - o.rmempty = true; - o = s.option(form.DynamicList, "allowed_domain", _("Allowed Domains"), - _("Individual domains to be allowed.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - o = s.option(form.DynamicList, "allowed_domains_url", _("Allowed Domain URLs"), - _("URLs to lists of domains to be allowed.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - o = s.option(form.DynamicList, "blocked_adblockplus_url", _("Blocked AdBlockPlus-style URLs"), - _("URLs to lists of AdBlockPlus-style formatted domains to be blocked.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - o = s.option(form.DynamicList, "blocked_domain", _("Blocked Domains"), - _("Individual domains to be blocked.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - o = s.option(form.DynamicList, "blocked_domains_url", _("Blocked Domain URLs"), - _("URLs to lists of domains to be blocked.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - o = s.option(form.DynamicList, "blocked_hosts_url", _("Blocked Hosts URLs"), - _("URLs to lists of hosts to be blocked.")); - o.depends('dnsmasq_config_file_url', ''); - o.addremove = true; - - return Promise.all([status.render(), m.render()]); - }) - } -}); diff --git a/applications/luci-app-simple-adblock/po/templates/simple-adblock.pot b/applications/luci-app-simple-adblock/po/templates/simple-adblock.pot deleted file mode 100644 index 0c8d214ade..0000000000 --- a/applications/luci-app-simple-adblock/po/templates/simple-adblock.pot +++ /dev/null @@ -1,559 +0,0 @@ -msgid "" -msgstr "Content-Type: text/plain; charset=UTF-8" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:174 -msgid "%s is currently disabled" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:90 -msgid "%s is not installed or not found" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:100 -msgid "Active" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:105 -msgid "Add IPv6 entries" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:103 -msgid "Add IPv6 entries to block-list." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:33 -msgid "Advanced Configuration" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:163 -msgid "Allowed Domain URLs" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:159 -msgid "Allowed Domains" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:153 -msgid "Allowed and Blocked Lists Management" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:134 -msgid "" -"Attempt to create a compressed cache of block-list in the persistent memory." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:35 -msgid "Automatic Config Update" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:32 -msgid "Basic Configuration" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:167 -msgid "Blocked AdBlockPlus-style URLs" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:175 -msgid "Blocked Domain URLs" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:171 -msgid "Blocked Domains" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:179 -msgid "Blocked Hosts URLs" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:110 -msgid "Blocking %s domains (with %s)." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:130 -msgid "Cache file found." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:112 -msgid "Compressed cache file created." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:133 -msgid "Compressed cache file found." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:42 -msgid "Controls system log and console output verbosity." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:122 -msgid "Curl download retry" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:116 -msgid "Curl maximum file size (in bytes)" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:85 -msgid "DNS Service" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:64 -msgid "DNS resolution option, see the %sREADME%s for details." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:139 -msgid "Directory for compressed cache file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:140 -msgid "" -"Directory for compressed cache file of block-list in the persistent memory." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:269 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:37 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:39 -msgid "Disable" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:148 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:150 -msgid "Disable Debugging" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:265 -msgid "Disabling %s service" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:154 -msgid "Dnsmasq Config File URL" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:104 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:108 -msgid "Do not add IPv6 entries" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:135 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:137 -msgid "Do not store compressed cache" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:129 -msgid "Do not use simultaneous processing" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:111 -msgid "Download time-out (in seconds)" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:96 -msgid "Downloading lists" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:258 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:38 -msgid "Enable" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:146 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:149 -msgid "Enable Debugging" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:147 -msgid "Enables debug output to /tmp/simple-adblock.log." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:254 -msgid "Enabling %s service" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:97 -msgid "Error" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:99 -msgid "Fail" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:115 -msgid "Force DNS ports:" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:236 -msgid "Force Re-Download" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:95 -msgid "Force Reloading" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:48 -msgid "Force Router DNS" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:51 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:52 -msgid "Force Router DNS server to all local devices" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:232 -msgid "Force re-downloading %s block lists" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:49 -msgid "Forces Router DNS use on local devices, also known as DNS Hijacking." -msgstr "" - -#: applications/luci-app-simple-adblock/root/usr/share/rpcd/acl.d/luci-app-simple-adblock.json:3 -msgid "Grant UCI and file access for luci-app-simple-adblock" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:102 -msgid "IPv6 Support" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:117 -msgid "" -"If curl is installed and detected, it would not download files bigger than " -"this." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:123 -msgid "" -"If curl is installed and detected, it would retry download this many times " -"on timeout/fail." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:160 -msgid "Individual domains to be allowed." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:172 -msgid "Individual domains to be blocked." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:56 -msgid "LED to indicate status" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:128 -msgid "" -"Launch all lists downloads and processing simultaneously, reducing service " -"start time." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:50 -msgid "Let local devices use their own DNS servers if set" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:148 -msgid "Not installed or not found" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:41 -msgid "Output Verbosity Setting" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:36 -msgid "Perform config update before downloading the block/allow-lists." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:57 -msgid "Pick the LED not already used in %sSystem LED Configuration%s." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:67 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:68 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:69 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:70 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:74 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:77 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:81 -msgid "Please note that %s is not supported on this system." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:93 -msgid "Processing lists" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:94 -msgid "Restarting" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:303 -msgid "Service Control" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:203 -msgid "Service Errors" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:104 -msgid "Service Status" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:160 -msgid "Service Warnings" -msgstr "" - -#: applications/luci-app-simple-adblock/root/usr/share/luci/menu.d/luci-app-simple-adblock.json:3 -msgid "Simple AdBlock" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:30 -msgid "Simple AdBlock - Configuration" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:103 -msgid "Simple AdBlock - Status" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:127 -msgid "Simultaneous processing" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:44 -msgid "Some output" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:225 -msgid "Start" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:92 -msgid "Starting" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:221 -msgid "Starting %s service" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:247 -msgid "Stop" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:112 -msgid "Stop the download if it is stalled for set number of seconds." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:91 -msgid "Stopped" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:243 -msgid "Stopping %s service" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:136 -msgid "Store compressed cache" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:133 -msgid "Store compressed cache file on router" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:43 -msgid "Suppress output" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:155 -msgid "" -"URL to the external dnsmasq config file, see the %sREADME%s for details." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:168 -msgid "URLs to lists of AdBlockPlus-style formatted domains to be blocked." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:164 -msgid "URLs to lists of domains to be allowed." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:176 -msgid "URLs to lists of domains to be blocked." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:180 -msgid "URLs to lists of hosts to be blocked." -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:130 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:131 -msgid "Use simultaneous processing" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:45 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:46 -msgid "Verbose output" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:106 -msgid "Version %s" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:98 -msgid "Warning" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:173 -msgid "config (%s) validation failure!" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:127 -msgid "disabled" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:87 -msgid "dnsmasq additional hosts" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:88 -msgid "dnsmasq config" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:90 -msgid "dnsmasq ipset" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:175 -msgid "" -"dnsmasq ipset support is enabled, but dnsmasq is either not installed or " -"installed dnsmasq does not support ipset" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:176 -msgid "" -"dnsmasq ipset support is enabled, but ipset is either not installed or " -"installed ipset does not support '%s' type" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:93 -msgid "dnsmasq nft set" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:177 -msgid "" -"dnsmasq nft set support is enabled, but dnsmasq is either not installed or " -"installed dnsmasq does not support nft set" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:178 -msgid "dnsmasq nft sets support is enabled, but nft is not installed" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:95 -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:100 -msgid "dnsmasq servers file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:183 -msgid "failed to access shared memory" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:181 -msgid "failed to create '%s' file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:193 -msgid "failed to create block-list or restart DNS resolver" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:189 -msgid "failed to create compressed cache" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:180 -msgid "failed to create directory for %s file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:201 -msgid "failed to create output/cache/gzip file directory" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:197 -msgid "failed to download" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:196 -msgid "failed to download Config Update file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:187 -msgid "failed to format data file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:192 -msgid "failed to move '%s' to '%s'" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:188 -msgid "failed to move temporary data file to '%s'" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:185 -msgid "failed to optimize data file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:199 -msgid "failed to parse" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:198 -msgid "failed to parse Config Update file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:186 -msgid "failed to process allow-list" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:195 -msgid "failed to reload/restart DNS resolver" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:190 -msgid "failed to remove temporary files" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:182 -msgid "failed to restart/reload DNS resolver" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:184 -msgid "failed to sort data file" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:194 -msgid "failed to stop %s" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:191 -msgid "failed to unpack compressed cache" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:200 -msgid "no HTTPS/SSL support on device" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:59 -msgid "none" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:158 -msgid "some recommended packages are missing" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:179 -msgid "the %s failed to discover WAN gateway" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/view/simple-adblock/overview.js:98 -msgid "unbound adblock list" -msgstr "" - -#: applications/luci-app-simple-adblock/htdocs/luci-static/resources/simple-adblock/status.js:157 -msgid "" -"use of external dnsmasq config file detected, please set '%s' option to '%s'" -msgstr "" diff --git a/applications/luci-app-simple-adblock/root/usr/share/luci/menu.d/luci-app-simple-adblock.json b/applications/luci-app-simple-adblock/root/usr/share/luci/menu.d/luci-app-simple-adblock.json deleted file mode 100644 index b2cdca18eb..0000000000 --- a/applications/luci-app-simple-adblock/root/usr/share/luci/menu.d/luci-app-simple-adblock.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "admin/services/simple-adblock": { - "title": "Simple AdBlock", - "action": { - "type": "view", - "path": "simple-adblock/overview" - }, - "depends": { - "acl": [ - "luci-app-simple-adblock" - ], - "uci": { - "simple-adblock": true - } - } - } -} diff --git a/applications/luci-app-simple-adblock/root/usr/share/rpcd/acl.d/luci-app-simple-adblock.json b/applications/luci-app-simple-adblock/root/usr/share/rpcd/acl.d/luci-app-simple-adblock.json deleted file mode 100644 index 6aeadc9c63..0000000000 --- a/applications/luci-app-simple-adblock/root/usr/share/rpcd/acl.d/luci-app-simple-adblock.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "luci-app-simple-adblock": { - "description": "Grant UCI and file access for luci-app-simple-adblock", - "read": { - "ubus": { - "luci.simple-adblock": [ - "getInitList", - "getInitStatus", - "getPlatformSupport" - ] - }, - "uci": [ - "simple-adblock" - ] - }, - "write": { - "uci": [ - "simple-adblock" - ], - "ubus": { - "luci.simple-adblock": [ - "setInitAction" - ] - } - } - } -} |