summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-mod-admin-full
AgeCommit message (Collapse)Author
2018-07-02luci-mod-admin-full: cleanup markup on flashops pageJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-07-02luci-mod-admin-full: rework wireless network status indicatorJo-Philipp Wich
Rework markup and logic of the wireless network status indicator to match that of the interface status widget. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-28luci-mod-admin-full: unify DHCP lease status codeJo-Philipp Wich
Merge the DHCP lease status code of the status overview and DHCP/DNS pages into a single shared partial template. Also remove some redundant markup on the index page and wireless assoc list templates. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-26luci-mod-admin-full: properly remap ports in switch status displayJo-Philipp Wich
Fixes: 60c5d15e9 ("luci-mod-admin-full: fix possible switch status layout bug") Fixes: bbf096c79 ("luci-mod-admin-full: cleanup markup") Reported-at: https://forum.lede-project.org/t/x/15897/19 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-26luci-mod-admin-full: fix possible switch status layout bugJo-Philipp Wich
In some cases we might get status information for more ports than which are actually usable, prevent overflowing the port status row in this case. Reported-at: https://forum.lede-project.org/t/x/15897/14 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-26Merge pull request #1912 from Ansuel/fixassociJo-Philipp Wich
luci-mod-admin-full: fix missing wifi_assoclist
2018-06-26luci-mod-admin-full: fix missing wifi_assoclistAnsuel Smith
With #e5ba594d77eed77d31d4b9b8c0e86026eb5a5fac the list of the connected device broke up. This fix this problem by creating a proper request link. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2018-06-25Merge pull request #1881 from ↵Jo-Philipp Wich
TDT-AG/pr/20180614-luci-mod-admin-full-fix-ssh-key-textarea luci-mod-admin-full: fix empty SSH-Keys textarea issue
2018-06-25luci-mod-admin-full: report SNR unit as dB, not dBmzjw
Fixes: #1880 Reported-by: "zjw" Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-25luci-mod-admin-full: fix average traffic calculation in realtime bandwidthJo-Philipp Wich
Fixes #1908. Suggested-by: "mgalyean" Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-25luci-mod-admin-full: fix initializing realtime graphsJo-Philipp Wich
Commit 69782ccbc ("luci-base: xhr.js: defer starting poll queue") changed the way XHR poll queues are started which broke the timing on the realtime graph pages. Fix the problem by manually starting the poller after registering the request handlers. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-25luci-base, luci-mod-admin-full: unify wifi assoclist codeJo-Philipp Wich
Merge the assoclist code of the status overview and wireless overview pages into a single shared partial template. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-25luci-mod-admin-full: replace status page legend tags with h3 (#1907)Jo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-23luci-mod-admin-full: packages: display available packages by defaultJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-23luci-mod-admin-full: cleanup markupJo-Philipp Wich
Globally cleanup template markup to support responsive design changes in OpenWrt theme. Rework handling of dynamic status tables, consolidate hand-written markup, fix small render bugs in various places and annotate tables where needed. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-14luci-mod-admin-full: fix empty SSH-Keys issueFlorian Eckert
If you delete all ssh keys in the textarea then LuCI will rais an error. So if you added one ssh-key to the textarea and then you want to delete them again that is not possbile in LuCI. To fix this remove "rmempty" attribute and add a remove function which will called if the textarea is empty. Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2018-06-08luci-mod-admin-full: add suggested italian translationsJo-Philipp Wich
Merge two italian translations suggested in #1870 and add back two missing dots accidentially removed from the translations in a previous commit. Fixes: 588c8618b ("luci-mod-admin-full: fix translation interpolation in JS confirm() calls") Suggested-by: Ansuel Smith <ansuelsmth@gmail.com> Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-08luci-mod-admin-full: fix translation interpolation in JS confirm() callsJo-Philipp Wich
Use luci.http.write_json() in conjunction with translate() to write out unescaped translation strings in a manner suitable for interpolation inside JavaScript. Fixes #1870 Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-08luci-mod-admin-full: git rid of embedded newlines in translation stringsJo-Philipp Wich
Also switch one usage of raw '<%_ ... %>' interpolation to '<%: ... %>' in order to avoid issues with translations using apostrophes. Globally resnyc translations after the fix. Fixes #1866. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-06-08treewide: switch firewall zone, network and iface lists to dropdown codeJo-Philipp Wich
Also switch the weekday and monthday lists in the firewall rule details to cbi dropdowns, vastly uncluttering the form. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-31luci-mod-admin-full: use common alert message markupJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-31luci-mod-admin-full: fix status page render glitch on ChromeJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-30luci-mod-admin-full: rework network and wifi status displaysJo-Philipp Wich
Use a more compact flex layout instead of the tabular display. Also rename "WAN status" to "Upstream" to avoid future confusion about wan interfaces vs. defaultroute interfaces. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-30luci-mod-admin-full: fix revert pageAnsuel Smith
This fix the strange redirect link, a bug with uwsgi where the controller is empty and a bug with the revert page showing the apply content empty. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com> [drop unrelated revert.html template change] Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-28luci-admin-full: add architecture infoAnsuel Smith
Referring to this, #1698 , we add architecture info and we show Unknown instead of ?. This is usefull if someone needs to install opkg packages manually. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2018-05-28treewide: convert HTML tables to divJo-Philipp Wich
Mostly convert HTML tables to div based markup to allow for easier styling in the future. Also change JS accessor code accordingly. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-19luci-mod-admin-full: fix crash on wireless when no networks are declaredJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-19luci-mod-admin-full: do not override iface section in wireless cbi mapJo-Philipp Wich
Do override the iface section id upon commit to avoid clobbering the resulting configuration. The manual config sync is not needed anymore after switching to uncached ubus uci operations. Fixes #1770. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-18Merge pull request #1769 from jow-/masterJo-Philipp Wich
UCI apply/rollback workflow
2018-05-07luci-mod-admin-full: use fs.glob instead nixio.fs.globYousong Zhou
It's how the module was named when "require"d and used by other code in the same function Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2018-05-07luci-mod-admin-full: no menu entry for leds if "/sys/class/leds" is emptyFlorian Eckert
Signed-off-by: Florian Eckert <fe@dev.tdt.de> Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2018-05-07luci-mod-admin-full: change supports_reset() test for factory resetFlorian Eckert
The check "supports_reset" only covers /proc/mtd partitions. If we have this the commands checks for names like ubi or rootfs_data. If this is found the system is possible for a factory reset. But on x86 the situation is different. We have no /proc/mtd partitions because this system do not use a bare metall flash. To solve this issue check if we have an overlay and if so we could do a factory reset. This could be applied for system which uses bare metal flash and system which uses FTL or harddisks. Jffs2reset is the current command used for factory reset. It will try to find volume "rootfs_data" and if it's mounted will delete all files under directory /overlay luci-mod-admin-mini also has check for reset available, but we leave it alone for now as it uses "mtd -r erase rootfs_data" Signed-off-by: Florian Eckert <fe@dev.tdt.de> Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2018-05-05luci-mod-admin-full: rework wifi configurationJo-Philipp Wich
- localize variables - get rid of redirects breaking apply workflow - auto-adjust unusable channels when switching country - use apply/rollback workflow when enabling/disabling networks Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-05treewide: rework uci apply workflowJo-Philipp Wich
Switch to rpcd based uci apply/rollback workflow which helps to avoid soft- bricking devices by requiring an explicit confirmation call after config apply. When a user now clicks "Save & Apply", LuCI first issues a call to uci apply which commits and reloads configuration, then goes into a polling countdown mode where it repeatedly attempts to call uci confirm. If the committed configuration is sane, the confirm call will go through and cancel rpcd's pending rollback timer. If the configuration change leads to a loss of connectivity (e.g. due to bad firewall rules or similar), the rollback mechanism will kick in after the timeout and revert configuration files and pending changes to the pre-apply state. In order to cover such rare cases where a lost of connectivity is expected and desired, the user is offered an "unchecked" apply option after timing out, which allows committing and applying the changes anyway, without the extra safety checks. As a consequence of this change, the luci-reload mechanism is now completely unsused since rpcd uses ubus config reload signals to reload affected services, which means that only procd-enabled services will receive proper reload treatment with the new workflow. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-02Fixing small typoRicardo Lamego
indentifies > identifies
2018-05-02luci-mod-admin-full: canonicalize configured static lease MACJo-Philipp Wich
When reading the configured mac address of the static lease, filter it through luci.ip.checkmac() to canonicalize and uppercase the value for mapping it against the combo box host hints. Fixes #1772. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-05-02Merge pull request #1705 from Mushoz/add-igmp-snoopingJo-Philipp Wich
luci-mod-admin-full: add igmp snooping option
2018-04-09luci-mod-admin-full: limit dns cachesize to 10000Marc Benoit
The value of cachesize is hardcoded to 10000 in dnsmasq-2.79/src/option.c to 10000 max case 'c': /* --cache-size */ { int size; if (!atoi_check(arg, &size)) ret_err(gen_err); else { /* zero is OK, and means no caching. */ if (size < 0) size = 0; else if (size > 10000) size = 10000; daemon->cachesize = size; } break; } Tested on Netgear R7800 Signed-off-by: Marc Benoit <marcb62185@gmail.com>
2018-04-09luci-mod-admin-full: allow setting dns cachesizeMarc Benoit
In the case of more powerful routers the default cachesize value == 150 is too small and can easily be extended to 1,000's and 10,000's of entries. It makes sense to make it easy configurable. Tested on Netgear R7800 Signed-off-by: Marc Benoit <marcb62185@gmail.com> Fix whitespace, edit the proposed help text. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2018-04-06luci-mod-admin-full: dispatch SimpleForm models using the form() actionJo-Philipp Wich
This fixes issues dicovered by check-controllers.sh Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-06luci-mod-admin-full: fix request path access in uci controllerJo-Philipp Wich
Fixes #1725 Fixes 731ed77c0 ("treewide: improve handling of page redirections in uci change views") Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-05luci-mod-admin-full: escape display parameterJo-Philipp Wich
Prevent reflected XSS through the reset button by url encoding the display parameter. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-05treewide: improve handling of page redirections in uci change viewsJo-Philipp Wich
Instead of passing the full LuCI request url, pass the relative resolved request path instead and filter the received value through the lookup() dispatcher function to only allow paths to actual internal pages. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-05treewide: filter shell arguments through shellquote() where applicableJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-05luci-mod-admin-full: fix possible shell injection in bandwith statusJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-04-04luci-mod-admin-full: use strict hostname validation for dhcp hostsJo-Philipp Wich
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-03-28luc-mod-admin-full: add igmp snooping optionJaap Buurman
Signed-off-by: Jaap Buurman <jaapbuurman@gmail.com>
2018-03-15Merge pull request #1654 from TDT-AG/pr/20180301-luci-several-fixesJo-Philipp Wich
luci-app-firewall/luci-base/luci-mod-admin-full: some fixes and improvements
2018-03-12treewide: unify mac address handlingJo-Philipp Wich
Use the new luci.ip MAC address facilities to parse and verify MAC addresses in a common way, instead of relying on various ad-hoc solutions. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2018-03-02luci-base, luci-mod-admin-full: store backup vars in luci configurationJo-Philipp Wich
Keep the ifname and bridge state backup variables in /etc/config/luci to not pollute /etc/config/network. Fixes #1655. Signed-off-by: Jo-Philipp Wich <jo@mein.io>