project/luci.git
4 years agoMerge pull request #4318 from stangri/19.07-luci-app-https-dns-proxy
Stan [Fri, 31 Jul 2020 09:53:01 +0000 (02:53 -0700)]
Merge pull request #4318 from stangri/19.07-luci-app-https-dns-proxy

[19.07] luci-app-https-dns-proxy: fix bootstrap_dns for cloudflare security

4 years agoluci-app-https-dns-proxy: fix bootstrap_dns for cloudflare security 4318/head
Stan Grishin [Fri, 31 Jul 2020 09:36:54 +0000 (09:36 +0000)]
luci-app-https-dns-proxy: fix bootstrap_dns for cloudflare security

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agoMerge pull request #4311 from stangri/19.07-luci-app-https-dns-proxy
Stan [Wed, 29 Jul 2020 09:45:21 +0000 (02:45 -0700)]
Merge pull request #4311 from stangri/19.07-luci-app-https-dns-proxy

[19.07] luci-app-https-dns-proxy: add OpenDNS servers

4 years agoluci-app-https-dns-proxy: add OpenDNS servers 4311/head
Stan Grishin [Wed, 29 Jul 2020 09:41:27 +0000 (09:41 +0000)]
luci-app-https-dns-proxy: add OpenDNS servers

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agoluci-mod-system: ignore empty /proc/mtd on flash page
Jo-Philipp Wich [Wed, 22 Jul 2020 08:20:42 +0000 (10:20 +0200)]
luci-mod-system: ignore empty /proc/mtd on flash page

A present, but empty /proc/mtd causes validation on the flash page to fail,
preventing any other operation.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit d2d3738d9046339d6374a5957cb790d0d9d62456)

4 years agotreewide: i18n - backport translations
Hannu Nyman [Sat, 18 Jul 2020 11:22:34 +0000 (14:22 +0300)]
treewide: i18n - backport translations

Backport translations from master and sync translations.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agoMerge pull request #4262 from TDT-AG/pr/20200713-luci-app-mwan3
Florian Eckert [Wed, 15 Jul 2020 13:47:35 +0000 (15:47 +0200)]
Merge pull request #4262 from TDT-AG/pr/20200713-luci-app-mwan3

luci-app-mwan3: sync changes with mwan3

4 years agoluci-app-mwan3: fix diagnostics status page style issues
Florian Eckert [Wed, 8 Jul 2020 09:32:34 +0000 (11:32 +0200)]
luci-app-mwan3: fix diagnostics status page style issues

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 9daf129cbaf6d15716abf77517e4b7ea5d5f8249)

4 years agoluci-app-mwan3: use ucitrack is now done with mwan3 procd
Florian Eckert [Mon, 9 Dec 2019 09:36:49 +0000 (10:36 +0100)]
luci-app-mwan3: use ucitrack is now done with mwan3 procd

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 40957b1c7851cd12833003496cd396ef9a687fcc)

4 years agoluci-app-mwan3: fix diagnostics status page style issues 4262/head
Florian Eckert [Wed, 8 Jul 2020 09:32:34 +0000 (11:32 +0200)]
luci-app-mwan3: fix diagnostics status page style issues

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 9daf129cbaf6d15716abf77517e4b7ea5d5f8249)

4 years agoluci-app-mwan3: use ucitrack is now done with mwan3 procd
Florian Eckert [Mon, 9 Dec 2019 09:36:49 +0000 (10:36 +0100)]
luci-app-mwan3: use ucitrack is now done with mwan3 procd

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 40957b1c7851cd12833003496cd396ef9a687fcc)

4 years agoluci-app-firewall: migrate syn_flood option to synflood_protect on save
Jo-Philipp Wich [Sat, 4 Jul 2020 22:51:59 +0000 (00:51 +0200)]
luci-app-firewall: migrate syn_flood option to synflood_protect on save

Fixes: #4220
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 0abcb39b623f0eff0fbcdfb99fca8f3224701e86)

4 years agoluci-base: ui.js: order menu entries with the same weight by name
Jo-Philipp Wich [Fri, 3 Jul 2020 12:30:30 +0000 (14:30 +0200)]
luci-base: ui.js: order menu entries with the same weight by name

The previous server side menu rendering ordered items first by their order
weight value, then by their internal name.

Do the same for client side menu rendering.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 0c479891ae31bbe308c4d6e181c118ec3d65c05f)

4 years agoluci-base: allow themes to provide sysauth.htm
Karl Palsson [Tue, 30 Jun 2020 15:40:52 +0000 (15:40 +0000)]
luci-base: allow themes to provide sysauth.htm

Support for sysauth_template was (inadvertently) dropped in refactorings
to support the json menu construction.  This does not restore that
functionality, which allowed different templates for every node in the
dispatcher tree, but provides an alternative mechanism that allows a
theme to provide a sysauth.htm template file instead.

Tested-by: Karl Palsson <karlp@etactica.com>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 8f9433127e5d2a576a1207da46d02389b82041a5)

4 years agoluci-app-travelmate: qrcode fix
Dirk Brenken [Fri, 26 Jun 2020 17:35:58 +0000 (19:35 +0200)]
luci-app-travelmate: qrcode fix

* escape more special chars which disturb qrcode generation

Signed-off-by: Dirk Brenken <dev@brenken.org>
(cherry picked from commit 06ce62b65d05806d39099b46102579eeff66aad2)

4 years agoluci-app-https-dns-proxy: bugfix: remove eDNS support
Stan Grishin [Thu, 25 Jun 2020 20:07:08 +0000 (20:07 +0000)]
luci-app-https-dns-proxy: bugfix: remove eDNS support

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agotreewide: i18n - backport translations
Hannu Nyman [Wed, 24 Jun 2020 20:26:31 +0000 (23:26 +0300)]
treewide: i18n - backport translations

Backport translations from master.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agotreewide: i18n - backport translations
Hannu Nyman [Mon, 15 Jun 2020 17:12:48 +0000 (20:12 +0300)]
treewide: i18n - backport translations

Backport translations from master.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agoluci-base: form.js: fix handling of array sections in JSONMap forms
Jo-Philipp Wich [Sun, 14 Jun 2020 14:41:02 +0000 (16:41 +0200)]
luci-base: form.js: fix handling of array sections in JSONMap forms

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 682f628ea611d8d12a2a4b5925851f99c5a4bd20)

4 years agoluci-app-simple-adblock: racially-neutral names
Stan Grishin [Sat, 13 Jun 2020 20:45:54 +0000 (20:45 +0000)]
luci-app-simple-adblock: racially-neutral names

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agoMerge pull request #4168 from dibdot/adb-19.07
Dirk Brenken [Sat, 13 Jun 2020 06:37:59 +0000 (08:37 +0200)]
Merge pull request #4168 from dibdot/adb-19.07

luci-app-adblock [19.07]: sync with adblock 4.0.6

4 years agoluci-app-adblock [19.07]: sync with adblock 4.0.6 4168/head
Dirk Brenken [Sat, 13 Jun 2020 06:30:37 +0000 (08:30 +0200)]
luci-app-adblock [19.07]: sync with adblock 4.0.6

* made SafeSearch provider configurable, you can limit
  SafeSearch to certain providers
* add an explanation paragraph to report settings
  tab (regarding restart requirement)
* sync translations

Signed-off-by: Dirk Brenken <dev@brenken.org>
4 years agoMerge pull request #4153 from stangri/19.07-luci-app-advanced-reboot
Stan [Thu, 11 Jun 2020 19:56:14 +0000 (12:56 -0700)]
Merge pull request #4153 from stangri/19.07-luci-app-advanced-reboot

[19.07] luci-app-advanced-reboot: bugfix: new board names for Linksys WRT-devices

4 years agoluci-app-advanced-reboot: bugfix: support new board names for Linksys WRT-devices 4153/head
Stan Grishin [Wed, 10 Jun 2020 16:49:11 +0000 (16:49 +0000)]
luci-app-advanced-reboot: bugfix: support new board names for Linksys WRT-devices

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agoluci(-ssl)-nginx: depend on luci-app-opkg
Hannu Nyman [Tue, 9 Jun 2020 20:23:38 +0000 (23:23 +0300)]
luci(-ssl)-nginx: depend on luci-app-opkg

Commit 391e82d6a3 in 2018 added luci-app-opkg dependency to
the 'luci' collection and its derivatives, but as nginx collections
do not depend on main 'luci', they did not get the intended change.

Fixes #4148

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
(cherry picked from commit 219f0ce891a2e59d28a2dd8a1d14a29e35a81185)

4 years agoMerge pull request #4102 from stangri/19.07-luci-app-simple-adblock
Stan [Wed, 3 Jun 2020 15:27:44 +0000 (08:27 -0700)]
Merge pull request #4102 from stangri/19.07-luci-app-simple-adblock

[19.07] luci-app-simple-adblock: bugfix: proper processing of failed downloads; decrease reliance on shell commands; proper acl.d file

4 years agotreewide: i18n - backport translations
Hannu Nyman [Wed, 3 Jun 2020 14:21:23 +0000 (17:21 +0300)]
treewide: i18n - backport translations

Backport translations from master.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agoMerge pull request #4118 from stangri/19.07-luci-app-https-dns-proxy
Stan [Tue, 2 Jun 2020 13:18:34 +0000 (06:18 -0700)]
Merge pull request #4118 from stangri/19.07-luci-app-https-dns-proxy

[19.07] luci-app-https-dns-proxy: decrease reliance on shell commands; proper acl.d file; add cloudflare family/protect

4 years agoluci-app-https-dns-proxy: decrease reliance on shell commands; proper acl.d file... 4118/head
Stan Grishin [Sat, 30 May 2020 11:41:12 +0000 (11:41 +0000)]
luci-app-https-dns-proxy: decrease reliance on shell commands; proper acl.d file; add cloudflare family/protect

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agoluci-app-openvpn: fix recipe selection
Dirk Brenken [Fri, 29 May 2020 17:09:49 +0000 (19:09 +0200)]
luci-app-openvpn: fix recipe selection

* add read acl for 'openvpn_recipes', fixed #4112

Signed-off-by: Dirk Brenken <dev@brenken.org>
(cherry picked from commit b6465766966c9e1d06778eb6d3d0a4be3920606d)

4 years agoluci-base: luci.js: properly skip comments when finding require tokens
Jo-Philipp Wich [Fri, 29 May 2020 07:56:06 +0000 (09:56 +0200)]
luci-base: luci.js: properly skip comments when finding require tokens

Fixes: #4020, #4022, #4111
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 6be8f8dbaee90a8a7e8bc87350f21793b9aed35c)

4 years agoluci-app-simple-adblock: bugfix: proper processing of failed dowloads; decrease relia... 4102/head
Stan Grishin [Wed, 27 May 2020 00:38:29 +0000 (00:38 +0000)]
luci-app-simple-adblock: bugfix: proper processing of failed dowloads; decrease reliance on shell commands; proper acl.d file

Signed-off-by: Stan Grishin <stangri@melmac.net>
4 years agotreewide: i18n - backport translations from master
Hannu Nyman [Mon, 25 May 2020 15:04:15 +0000 (18:04 +0300)]
treewide: i18n - backport translations from master

Backport translations from master.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agoluci-base: ui.js: fix function declaration in nested statement
Anton Kikin [Sat, 23 May 2020 23:12:20 +0000 (02:12 +0300)]
luci-base: ui.js: fix function declaration in nested statement

Fix "SyntaxError: Strict mode does not allow function declarations
in a lexically nested statement" error that may occur in some old
browsers (detected on QtWebKit 5.212).

Signed-off-by: Anton Kikin <a.kikin@tano-systems.com>
(cherry picked from commit c00d0d9473803eec3248f0f6d7f3404923c80514)

4 years agoluci-app-mwan3: Remove unnecessary dependency
Brian J. Murrell [Fri, 13 Mar 2020 09:42:11 +0000 (05:42 -0400)]
luci-app-mwan3: Remove unnecessary dependency

There is no need to depend on luci-app-firewall, so remove the dependency.

I have examined the code and cannot see any reason for the dependency
and I have built a router with luci-app-mwan3, and without firewall,
luci-app-firewall and it all functions just fine.

Signed-off-by: Brian J. Murrell <brian@interlinx.bc.ca>
(cherry picked from commit 70089cc212f92ee5660db69e32b10e552df3c1c5)

4 years agoluci-base: firewall.js: remove further zone network/name fallback logic
Jo-Philipp Wich [Sun, 24 May 2020 15:32:14 +0000 (17:32 +0200)]
luci-base: firewall.js: remove further zone network/name fallback logic

Fixes: #4093
Fixes: 4052436d8 ("luci-base: firewall.js: don't treat zone name as network fallback")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit f6f4005d0baf70f04752747822cda9f1248c47ca)

4 years agoluci-app-statistics: modify default amount of data items in RRD
Hannu Nyman [Thu, 21 May 2020 14:19:55 +0000 (17:19 +0300)]
luci-app-statistics: modify default amount of data items in RRD

Increase the default number of data items in the RRD database
from 100 to 144. That leads to better matching summarising/averaging
moments between day & week and week & month at the averaging intervals:
30sec, 10min, 70 min, 5h10min, 2d13h

Previous 100 led too easily to situations, where the longer period's
more scarce data gets selected for displaying in the graph. That could
happen if the longer period's last data point was stored more recently
than the last data item in the originally required period.
(E.g. if the last "week data item" was more recent than the last
"day data item", the week data was used for the day chart.)

(Note: this change only applies in a live router if the RRD database is
empty. E.g after reboot or after emptying the RRD database dir.)

Reference to discussion at #4065

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
(cherry picked from commit 591b918ea4e67d863c74d3d99bd5878c38d06761)

4 years agoluci-app-vpnbypass: don't clobber permissions of VPN menu
Jo-Philipp Wich [Tue, 19 May 2020 10:28:19 +0000 (12:28 +0200)]
luci-app-vpnbypass: don't clobber permissions of VPN menu

Ref: https://github.com/openwrt/luci/issues/4066
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 7f4de85b0b9c4f6bd9a19bf5a44af3825b31e8c1)

4 years agoluci-app-vpn-policy-routing: don't clobber permissions of VPN menu
Jo-Philipp Wich [Tue, 19 May 2020 10:27:44 +0000 (12:27 +0200)]
luci-app-vpn-policy-routing: don't clobber permissions of VPN menu

Ref: https://github.com/openwrt/luci/issues/4066
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 4dcab51ca522407cf63a51883bc6505cf24fbd64)

4 years agobuild: reload rpcd in package postinstall
Jo-Philipp Wich [Tue, 3 Mar 2020 08:28:44 +0000 (09:28 +0100)]
build: reload rpcd in package postinstall

Send a SIGHUP to rpcd after installing LuCI packages to reload ACL rules.

Also remove redundant code while we're at it.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit ca558f4f93451de7afb2a85c017051cb807b3329)

4 years agotreewide: stage ACL rules for legacy applications
Jo-Philipp Wich [Fri, 10 Apr 2020 21:21:35 +0000 (23:21 +0200)]
treewide: stage ACL rules for legacy applications

Fixes: #3866
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 43e872871a85dce70509c3c97c10e9c61788c378)

4 years agoluci-mod-system: make dropbear pages depend on dropbear executable
Jo-Philipp Wich [Sun, 17 May 2020 17:32:26 +0000 (19:32 +0200)]
luci-mod-system: make dropbear pages depend on dropbear executable

Fixes: #4052
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit c7686d4b3c660dfe44eb2decbedce89c0873649e)

4 years agoMerge pull request #4048 from hnyman/i18n-merge
Hannu Nyman [Fri, 15 May 2020 13:45:37 +0000 (16:45 +0300)]
Merge pull request #4048 from hnyman/i18n-merge

build/i18n-merge-master: ignore apps deleted in master

4 years agoluci-mod-network: fix reading static route table value
Jo-Philipp Wich [Wed, 13 May 2020 15:20:05 +0000 (17:20 +0200)]
luci-mod-network: fix reading static route table value

Ref: https://forum.openwrt.org/t/static-route-shows-incorrect-table/63514
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 87475139516d37d86c038e7432837f6ba409d7a9)

4 years agobuild/i18n-merge-master: ignore apps deleted in master 4048/head
Hannu Nyman [Wed, 13 May 2020 14:49:39 +0000 (17:49 +0300)]
build/i18n-merge-master: ignore apps deleted in master

Refine the code to ignore apps that have been deleted from master
but still exist in release branches. E.g. luci-app-samba

Previously the unhandled git error from non-existing master
mangled the .po files in the release branch: the 18n header was
removed and all non-ASCII chars were deleted from translation.

Fix this by processing only those files where 'git show' succeeds.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agotreewide: i18n - backport translations from master
Hannu Nyman [Sun, 10 May 2020 13:16:09 +0000 (16:16 +0300)]
treewide: i18n - backport translations from master

Backport translations from master

1) i18n-sync to sync 19.07 itself
2) i18n-merge-master to backport from master
3) i18n-sync to clean-up, as merge-master makes also errors
4) revert luci-app-samba that gets mishandled  (removal from master causes ???)

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agotimezone data: update to 2020a
Hannu Nyman [Sat, 9 May 2020 06:45:05 +0000 (09:45 +0300)]
timezone data: update to 2020a

Update timezone data to 2020a

http://mm.icann.org/pipermail/tz-announce/2020-April/000058.html

2020a:
    Morocco springs forward on 2020-05-31, not 2020-05-24.
    Canada's Yukon advanced to -07 year-round on 2020-03-08.
    America/Nuuk renamed from America/Godthab.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
(cherry picked from commit e5fe16c9ea405ac8c58607f5083eecd3551ef4ae)

4 years agotreewide: i18n - backport translations from master
Hannu Nyman [Thu, 7 May 2020 19:57:19 +0000 (22:57 +0300)]
treewide: i18n - backport translations from master

Backport translations from master.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agotreewide: sync translations
Hannu Nyman [Thu, 7 May 2020 19:52:56 +0000 (22:52 +0300)]
treewide: sync translations

Sync translations.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
4 years agoluci-base: optimize some PNG files
Jo-Philipp Wich [Thu, 7 May 2020 18:04:55 +0000 (20:04 +0200)]
luci-base: optimize some PNG files

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit f8cf115d9b7525d3d9b259c20a4d2e662bcb7e22)

4 years agoluci-base: move old cbi icons to luci-compat
Jo-Philipp Wich [Thu, 7 May 2020 17:15:02 +0000 (19:15 +0200)]
luci-base: move old cbi icons to luci-compat

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 102124115d4c2e204bf4cf1ffafe1d8b304fd0df)

4 years agoluci-base: replace filebrowser icons with SVG variants
Jo-Philipp Wich [Thu, 7 May 2020 17:38:50 +0000 (19:38 +0200)]
luci-base: replace filebrowser icons with SVG variants

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit b34b7fc504ba4ba27dfe7c2c446c3085a923f952)

4 years agoluci-app-nlbwmon: use legacy `L.dom` attribute
Jo-Philipp Wich [Sat, 4 Apr 2020 10:00:20 +0000 (12:00 +0200)]
luci-app-nlbwmon: use legacy `L.dom` attribute

Until it is converted to a proper view, we need to use the legacy alias.

Fixes: #3835
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit af6fd6dfab2ac576033c714cc69520e17f1fa48c)

4 years agoluci-app-nlbw: simplify table CSS
Jo-Philipp Wich [Wed, 25 Mar 2020 11:48:11 +0000 (12:48 +0100)]
luci-app-nlbw: simplify table CSS

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 6efaea2ffb46f9909038b85cf12e7acf4467ae2e)

4 years agoluci-app-nlbwmon: fix typos
Balázs Úr [Fri, 27 Dec 2019 14:31:13 +0000 (15:31 +0100)]
luci-app-nlbwmon: fix typos

Signed-off-by: Balázs Úr <balazs@urbalazs.hu>
(cherry picked from commit 44cef2ab4493d8fb2d0bbdc0831a2e23cd2acf2c)

4 years agoluci-mod-status: convert menu nodes to JSON
Jo-Philipp Wich [Tue, 10 Dec 2019 07:49:24 +0000 (08:49 +0100)]
luci-mod-status: convert menu nodes to JSON

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit c698cd5ab9ad9021ac7b92a45d7ba401cb3617d0)

4 years agoluci-theme-material: fix Makefile file mod
Florian Eckert [Mon, 4 May 2020 10:43:17 +0000 (12:43 +0200)]
luci-theme-material: fix Makefile file mod

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 0024609a0057ffc6adad4fa33bfeb7202b8dd454)

4 years agoluci-theme-material: remove useless logging output
Florian Eckert [Thu, 16 Apr 2020 18:55:30 +0000 (20:55 +0200)]
luci-theme-material: remove useless logging output

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 1b875a610f0cb835f9472b55d726dc339f9af633)

4 years agoluci-theme-bootstrap: rework menu rendering
Jo-Philipp Wich [Wed, 15 Apr 2020 20:46:25 +0000 (22:46 +0200)]
luci-theme-bootstrap: rework menu rendering

Utilize the LuCI.ui.menu class to load, traverse and cache the menu tree
in the local session store.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
[only render menu when logged in for 19.07]
(backported from commit 1ac8df2614336b34109375e62f201cf6bac46734)

4 years agoluci-theme-openwrt: rework menu rendering
Jo-Philipp Wich [Wed, 15 Apr 2020 20:43:05 +0000 (22:43 +0200)]
luci-theme-openwrt: rework menu rendering

Utilize the LuCI.ui.menu class to load, traverse and cache the menu tree
in the local session store.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
[only render menu when logged in for 19.07]
(backported from commit 48269ade6163c34f348632bf225e2c6649b0a9c1)

4 years agoluci-base: implement JSON endpoint to fetch menu information
Jo-Philipp Wich [Wed, 15 Apr 2020 20:25:48 +0000 (22:25 +0200)]
luci-base: implement JSON endpoint to fetch menu information

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
[require authentication for 19.07]
(backported from commit e56e442d6af125522214a9bc9ab957ac39c5c0c8)

4 years agoluci-base: expose currently dispatched node info to client side JS
Jo-Philipp Wich [Wed, 15 Apr 2020 20:13:33 +0000 (22:13 +0200)]
luci-base: expose currently dispatched node info to client side JS

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 94a0c571810da25043ca3599561bd9b369c0c65e)

4 years agoluci-base: convert menu nodes to JSON
Jo-Philipp Wich [Fri, 6 Dec 2019 20:51:32 +0000 (21:51 +0100)]
luci-base: convert menu nodes to JSON

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 16853bcd2e4224c281731adbfa490d704784ec20)

4 years agoluci-base: ui.js: hide unsatisfied firstchild menu nodes
Jo-Philipp Wich [Sat, 18 Apr 2020 21:05:01 +0000 (23:05 +0200)]
luci-base: ui.js: hide unsatisfied firstchild menu nodes

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 7882f3ebdde0364314a45aa6dd8fbc4e766e8ea8)

4 years agoluci-base: ui.js: add LuCI.ui.menu.flushCache() function
Jo-Philipp Wich [Thu, 16 Apr 2020 13:13:26 +0000 (15:13 +0200)]
luci-base: ui.js: add LuCI.ui.menu.flushCache() function

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 90a51ab3b9afca0144a93eb967fcd72a230732f0)

4 years agoluci-base: ui.js: add LuCI.ui.menu helper class
Jo-Philipp Wich [Wed, 15 Apr 2020 20:30:00 +0000 (22:30 +0200)]
luci-base: ui.js: add LuCI.ui.menu helper class

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 930f28b606d8a7b3cb511e57bd8028b1979ce5da)

4 years agoluci-base: ui.js: use standard indicator framework to display uci changes
Jo-Philipp Wich [Mon, 13 Apr 2020 10:31:54 +0000 (12:31 +0200)]
luci-base: ui.js: use standard indicator framework to display uci changes

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit b6e93d54a0f9c6be310e07a66ac08532ba6400b0)

4 years agoluci-base: luci.js: use standard indicator framework for poll status
Jo-Philipp Wich [Mon, 13 Apr 2020 10:41:26 +0000 (12:41 +0200)]
luci-base: luci.js: use standard indicator framework for poll status

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 68b2ce84ece62e3aec98b9be31e61ec5f6cdba2d)

4 years agoluci-theme-*: set mediaurlbase if it is the first time to be installed
Chen Minqiang [Fri, 3 Apr 2020 10:10:04 +0000 (18:10 +0800)]
luci-theme-*: set mediaurlbase if it is the first time to be installed

If we build multi-themes into firmware, each of them set itself
to be the default theme, what theme should it be?

To make it clear, we only set mediaurlbase if the theme is the
first time to be installed/built-in.

This resolve the issue that theme always change to somewhat default
after upgrading the firmware even with a config-keep-upgrade

Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
(backported from commit fc150636b9393e31aa7d5a8d8320b111476ba2f1)

4 years agoluci-theme-bootstrap: fix dynlist overflows
Jo-Philipp Wich [Fri, 3 Apr 2020 11:47:00 +0000 (13:47 +0200)]
luci-theme-bootstrap: fix dynlist overflows

Fixes: #3795
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit 015712bba0fe4b036b4d12235a7b664d5b4cf3fe)

4 years agoluci-theme-openwrt: work around cssmin bug breaking the minified CSS.
Jo-Philipp Wich [Tue, 31 Mar 2020 13:25:27 +0000 (15:25 +0200)]
luci-theme-openwrt: work around cssmin bug breaking the minified CSS.

The cssmin utility incorrectly breaks up calc() expressions when
minifying rules. Avoid the problem by trimming uneeded spaces.

Fixes: #3801
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 63057a08dcc2ee80f68ccd411239a51646eba295)

4 years agothemes: generalize indicator markup and styling
Jo-Philipp Wich [Mon, 30 Mar 2020 15:05:05 +0000 (17:05 +0200)]
themes: generalize indicator markup and styling

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit ccb7e4a4a7aac34734dbda7e9ca7f5b53cbc51ff)

4 years agoluci-theme-bootstrap: dynamically adjust body margin
Jo-Philipp Wich [Fri, 27 Mar 2020 16:57:48 +0000 (17:57 +0100)]
luci-theme-bootstrap: dynamically adjust body margin

Fixes: #3722
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit c99684dff73b4d0ca6f73cd3cde667f685aa5b4b)

4 years agoluci-theme-bootstrap: fixup assoclist styling
Jo-Philipp Wich [Tue, 24 Mar 2020 21:13:41 +0000 (22:13 +0100)]
luci-theme-bootstrap: fixup assoclist styling

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 3b40c582baefcb302fb23ed633ed85ab1ac72a9e)
(cherry picked from commit ca17ec9b4f0571144ebdf124abe5edd9ecf7481b)

4 years agoluci-theme-material: render menu on client side
Jo-Philipp Wich [Sun, 1 Dec 2019 20:13:14 +0000 (21:13 +0100)]
luci-theme-material: render menu on client side

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 92eecedc8a52b0ba814daddb5167449a2ebb7f26)

4 years agoluci-theme-openwrt: render menu on client side
Jo-Philipp Wich [Sun, 1 Dec 2019 19:18:21 +0000 (20:18 +0100)]
luci-theme-openwrt: render menu on client side

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit ebc99a6ab30d1b563b1e073df93006504cdc80ae)

4 years agoluci-theme-bootstrap: render menu on client side
Jo-Philipp Wich [Sun, 1 Dec 2019 19:11:37 +0000 (20:11 +0100)]
luci-theme-bootstrap: render menu on client side

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 5db4463acec5a672c4e4fcb7c91fb93af8e43387)

4 years agoluci-theme-bootstrap: minor page action alignment fix
Jo-Philipp Wich [Tue, 12 Nov 2019 07:48:36 +0000 (08:48 +0100)]
luci-theme-bootstrap: minor page action alignment fix

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit df38e4505ceae1634dc48c2793040f31856c758a)

4 years agoluci-mod-network: dhcp.js: allow lease hostname to be empty
Jo-Philipp Wich [Sat, 11 Apr 2020 16:34:54 +0000 (18:34 +0200)]
luci-mod-network: dhcp.js: allow lease hostname to be empty

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 57f27cf7f803cf1f788f6b3edb103c138aaa92f9)

4 years agoluci-mod-network: dhcp.js: fix validation logic
Jo-Philipp Wich [Sat, 11 Apr 2020 16:19:59 +0000 (18:19 +0200)]
luci-mod-network: dhcp.js: fix validation logic

The `server` option allows plain IPs besides the `/domain/addr` format.

Fixes: #3870
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 137db1c4d1bac4000f9c17150ac286b73787ce20)

4 years agoluci-base, luci-mod-network: adjust ZoneSelect / NetworkSelect descriptions
Jo-Philipp Wich [Tue, 7 Apr 2020 16:19:19 +0000 (18:19 +0200)]
luci-base, luci-mod-network: adjust ZoneSelect / NetworkSelect descriptions

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 45a30c925ba39f101861a09d56f6364bedf55250)

4 years agoluci-mod-network: dhcp.js: properly validate hostname values
Jo-Philipp Wich [Mon, 23 Mar 2020 21:20:50 +0000 (22:20 +0100)]
luci-mod-network: dhcp.js: properly validate hostname values

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 98a9d07d8998fae912ff43ee4d45ed8ad09aa04c)

4 years agoluci-mod-network: diagnostics.css: use .btn CSS class for buttons
Jo-Philipp Wich [Mon, 23 Mar 2020 20:48:13 +0000 (21:48 +0100)]
luci-mod-network: diagnostics.css: use .btn CSS class for buttons

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 41b2fe9f6bfa793329e722b2420d75339cbb0cda)

4 years agoluci-mod-network: dnsmasq: correct sense & usage of dnsseccheckunsigned
Kevin Darbyshire-Bryant [Fri, 22 Nov 2019 15:25:59 +0000 (15:25 +0000)]
luci-mod-network: dnsmasq: correct sense & usage of dnsseccheckunsigned

dnsmasq v2.80 made 'dnssec-check-unsigned' the default, reflect this in
the gui.

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
(cherry picked from commit c58ae7d3f41a3454a116560fd555aac0ead18ff2)

4 years agoluci-mod-system: don't make SSH tabs depend on dropbear uci
Jo-Philipp Wich [Sun, 26 Apr 2020 16:38:16 +0000 (18:38 +0200)]
luci-mod-system: don't make SSH tabs depend on dropbear uci

This prevents a situation where the tabs will be disabled by the dispatcher
once the last config section has been removed. This would allow a user to
disable SSH via the UI but not to reenable it.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit baa3bd4aac64984dfbecf8e524cfb31ed485a916)

4 years agoluci-mod-system: password.js: make event handler attachment more robust
Jo-Philipp Wich [Tue, 28 Apr 2020 21:33:24 +0000 (23:33 +0200)]
luci-mod-system: password.js: make event handler attachment more robust

Do not expect a specific markup structure but use querySelector() to locate
the input element.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 34c06b4704383428c87e0a3c3c96ff7facfa5c46)

4 years agoluci-mod-system: convert menu controller to declarative JSON
Jo-Philipp Wich [Mon, 13 Apr 2020 16:42:32 +0000 (18:42 +0200)]
luci-mod-system: convert menu controller to declarative JSON

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit ca295b04e72bb869925ba4183800166130f1b228)

4 years agoluci-mod-system: system.js: rework local time widget markup
Jo-Philipp Wich [Mon, 23 Mar 2020 20:58:25 +0000 (21:58 +0100)]
luci-mod-system: system.js: rework local time widget markup

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 3afe606743c44414f11f713b1557d4c0fb9faf80)

4 years agoluci-mod-system: use proper CSS class for map description
Jo-Philipp Wich [Mon, 23 Mar 2020 20:56:55 +0000 (21:56 +0100)]
luci-mod-system: use proper CSS class for map description

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 90990df3b6865e276c065733e724012938174853)

4 years agoluci-mod-system: use generic .cbi-section-actions style for row actions
Jo-Philipp Wich [Mon, 23 Mar 2020 20:53:53 +0000 (21:53 +0100)]
luci-mod-system: use generic .cbi-section-actions style for row actions

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 9706388c42b7490cfdbdad8cc32012870211524d)

4 years agoluci-mod-status: index.js: skip includes which failed loading
Jo-Philipp Wich [Sat, 18 Apr 2020 17:57:00 +0000 (19:57 +0200)]
luci-mod-status: index.js: skip includes which failed loading

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit a0db2abea3ceae24f376af31ffb7ca5e76d19da6)

4 years agoluci-mod-status: tag DHCP lease tables with dedicated CSS classes
Jo-Philipp Wich [Mon, 23 Mar 2020 21:02:30 +0000 (22:02 +0100)]
luci-mod-status: tag DHCP lease tables with dedicated CSS classes

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit be62595c5b44e2f4bc366bb3a2d2ee07d69a77dd)

4 years agoluci-mod-status: adjust assoclist markup for easier styling
Jo-Philipp Wich [Mon, 23 Mar 2020 21:01:06 +0000 (22:01 +0100)]
luci-mod-status: adjust assoclist markup for easier styling

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit e26b6c8c1408586ccbf59aac7368420c7a055097)

4 years agoluci-mod-status: use generic .cbi-section-actions style for row actions
Jo-Philipp Wich [Mon, 23 Mar 2020 20:55:50 +0000 (21:55 +0100)]
luci-mod-status: use generic .cbi-section-actions style for row actions

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 4fa409c7c47830010d4b96b2201b2cf530d360da)

4 years agoluci-base: Show used memory instead of Free
Howard Su [Fri, 28 Feb 2020 14:06:52 +0000 (22:06 +0800)]
luci-base: Show used memory instead of Free

This makes sure solid/blue bar shows the used memory.

Signed-off-by: Howard Su <howard0su@gmail.com>
(cherry picked from commit d09f3b64b2871e0ba642f9112b0c334ec9832f23)

4 years agoluci-base: form.js: allow secondary configs to fail loading
Jo-Philipp Wich [Tue, 28 Apr 2020 07:46:22 +0000 (09:46 +0200)]
luci-base: form.js: allow secondary configs to fail loading

Ref: https://forum.openwrt.org/t/luci-rpc-error/61760
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(backported from commit 17ffc84a2903c2354543cd0fb575a82e36e076fd)

4 years agoluci-base: uhttpd.lua: expose all CGI variables
Jo-Philipp Wich [Fri, 10 Apr 2020 19:03:19 +0000 (21:03 +0200)]
luci-base: uhttpd.lua: expose all CGI variables

Fixes: #3873
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 465891ff0239b8fdafb737d01e3f05205a14319b)

4 years agoluci-base: add missing .btn CSS classes to sysauth template
Jo-Philipp Wich [Thu, 26 Mar 2020 21:15:56 +0000 (22:15 +0100)]
luci-base: add missing .btn CSS classes to sysauth template

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 9edb9336d3f1c8c2ac208eff798db23150badec4)

4 years agoluci-base: accept alternative logread location
Dirk Brenken [Fri, 20 Mar 2020 15:11:31 +0000 (16:11 +0100)]
luci-base: accept alternative logread location

* minimal change to accept the usual logread location
  plus the alternative location (/usr/sbin/logread)
  used by syslog-ng (see openwrt/packages/issues/11535 for reference)

Signed-off-by: Dirk Brenken <dev@brenken.org>
(cherry picked from commit 085f3f7809daae9a239214d6324557eb6295dc1e)

4 years agoluci-base: fix error 404 on missing relay protocol
Ansuel Smith [Thu, 12 Mar 2020 15:46:53 +0000 (16:46 +0100)]
luci-base: fix error 404 on missing relay protocol

Currently relay.js is included in any case even if
the router doesn't have the needed package to use it.
Fix this by checking if the system has this feature.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
(cherry picked from commit 3d70d3e5d786383b8754200cf065713b191bdead)