Commit graph

110 commits

Author SHA1 Message Date
Hannu Nyman
ccdca27a72 luci-base: remove deprecated radvd from ucitrack
Cleanup /etc/config/ucitrack by removing 'radvd' affect item
from network, as the radvd package has deprecated by odhcpd
and odhcp6c in 2014.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2021-02-13 12:20:57 +02:00
Dobroslaw Kijowski
ab01040663 luci-mod-network: skip check for 802.11w feature
OpenWrt commit 1a9b896d ("treewide: nuke DRIVER_11W_SUPPORT") enables
802.11w feature for all wpad/hostapd configurations. The feature flag
was removed at all but for the compatibility reasons 11w is still
advertised (but there's a plan to nuke it also) [1].

Remove conditional 802.11w LuCI support to match current behavior.

[1]: https://github.com/openwrt/openwrt/pull/3347

Signed-off-by: Dobroslaw Kijowski <dobo90@gmail.com>
2021-01-02 14:59:25 +02:00
Martin Böh
6e4e1321a2 luci-base: fix syntax error in hostapd features
Signed-off-by: Martin Böh <mart.b@outlook.de>
2020-10-31 21:07:16 +01:00
Ansuel Smith
681d38db31
luci-base: check support for hostapd wps
Check if hostapd supports wps pushbutton features.
(wps is now supported by ubus instead of using hostapd_cli)

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2020-10-11 01:32:21 +02:00
Nicolas Thumann
c4b617a7a6
luci-base: Fixed delayed portstatus loading on R7800
Signed-off-by: Nicolas Thumann <me@n-thumann.de>
2020-08-02 20:08:20 +02:00
Jo-Philipp Wich
84a0b6845f
Merge pull request #4127 from blocktrron/luci-wep-features
luci-mod-network: query WEP support
2020-06-16 17:01:27 +02:00
Florian Eckert
c6742ebdb8 luci-base: move vpn section
Move the VPN configuration section behind the network configuration. The normal
workflow is add/edit the network and then add/edit a vpn configuration.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2020-06-16 11:34:04 +02:00
Jo-Philipp Wich
05f07e55b7 luci-base: grant uci rename permissions
When doing an initial wireless configuration migration, LuCI needs to
perform a series of rename calls which weren't allowed so far.

Ref: https://forum.openwrt.org/t/config-migration-endless-loop/64340
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-06-02 17:09:50 +02:00
David Bauer
57ad80a02d luci-base: add queryable WEP WiFi feature
This commit adds WEP as a queryable WiFi feature.

Support for the deprecated WEP encryption is not
compiled-in to hostapd or wpa_supplicant by default
anymore.

Allow LuCi to query the availability of WEP to remove
it from the list of avialable encryption methods in case
hostapd / wpa_supplicant are compiled without it.

Signed-off-by: David Bauer <mail@david-bauer.net>
2020-06-01 08:20:44 +02:00
Jo-Philipp Wich
f44ba4811d luci-base: make logout link depend on luci-base ACL
Fixes: #3966
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-04-25 13:52:15 +02:00
Jo-Philipp Wich
71e22c1c34 luci-base: fix trainling comma in ACL specification
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-04-17 16:26:46 +02:00
Jo-Philipp Wich
e56e442d6a luci-base: implement JSON endpoint to fetch menu information
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-04-16 13:30:35 +02:00
Jo-Philipp Wich
c099344013 treewide: reorganize base ACLs
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-04-09 23:23:33 +02:00
Jo-Philipp Wich
5fe88f8caf
Merge pull request #3769 from dibdot/logread-fix
luci-base: accept alternative logread location
2020-04-08 09:19:09 +02:00
Jo-Philipp Wich
e331e32b2c
Merge pull request #3749 from Ansuel/fix_relayd
luci-base: fix error 404 on missing relay protocol
2020-04-08 09:15:38 +02:00
jjm2473
97780a9ce1 ucitrack: fix bug for exec with params
In file `/etc/config/ucitrack`
```
config fstab
        option exec '/sbin/block mount'
```
`/sbin/block mount` never be called after fstab changed.

Signed-off-by: jjm2473 <1129525450@qq.com>
2020-03-23 01:05:31 +08:00
Dirk Brenken
085f3f7809
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>
2020-03-20 16:11:31 +01:00
Jo-Philipp Wich
38289bc975 luci-base: ensure that ubus path uses trailing slash
Without the trailing slash, probing endpoint availability will fail.

Fixes: 529bde440 ("luci-base: make rpc webserver path configurable")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-03-13 23:57:19 +01:00
Ansuel Smith
d8e1aef150
luci-base: add relayd to getFeature list
Add /sbin/block to the generic Feature list to make
it easily accessible by getProtocolHandlers

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2020-03-12 16:40:25 +01:00
Jo-Philipp Wich
81cf99a507 luci-base: extend rollback timeout to 90 seconds
Ref: #3628
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-02-13 19:26:33 +01:00
Jo-Philipp Wich
6d59a6400e luci-base: make swconfig port state parsing more robust
Since swconfig output varies wildly among different switch drivers, rely
on a simpler more robust parsing approach to find the required information.

Ref: https://forum.openwrt.org/t/cannot-read-property-link/50766
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-01-28 18:16:44 +01:00
Jo-Philipp Wich
8978aaf6b6 luci-base: allow loading translations when not authenticated
Fixes: #3563
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2020-01-25 23:28:56 +01:00
Jo-Philipp Wich
679e59f4f3
Merge pull request #3522 from swg0101/systemcert
luci-base/mod-network: corrections to previous commit
2020-01-17 08:26:46 +01:00
David Lam
cbb1c3cf93
luci-base: correct rpcd bad access mode
Corrects the bad access mode from a previous commit that did not allow rpcd luci to execute.

Signed-off-by: David Lam <david@thedavid.net>
2020-01-16 14:49:42 -08:00
Jo-Philipp Wich
b65588ebc6
Merge pull request #3511 from Ansuel/no-hard
luci-base: remove hardcoded cgi-bin path
2020-01-16 15:36:05 +01:00
Jo-Philipp Wich
f545b29aaf
Merge pull request #3517 from Ansuel/ubus_short
luci-base: make rpc webserver path configurable
2020-01-16 15:33:25 +01:00
Ansuel Smith
529bde4408
luci-base: make rpc webserver path configurable
Currently the ubus path that provide the webserver is hardcoded to be /ubus.
Change this to make it configurable from the luci config file.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2020-01-16 15:16:09 +01:00
Ansuel Smith
5e6ec8562f
luci-base: remove hardcoded cgi-bin path
Currently LuCI can be loaded only when placed in the root of the server as the cgi-bin path are hardcoded. Change the index.html to load the cgi-bin path from the current level.
Also add a new entry in the env Object to make the cgi_base path easily accessible.
This variable will be based on the position of /cgi-bin/luci.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2020-01-16 15:02:14 +01:00
David Lam
27b21c2a62
luci-base: add system cert bundle detection
Add detection mechanism for system cert CA bundle installed by the
ca-bundle package. Used by LuCI to detect whether the "Use system
certificates" certificate validation option should be enabled.

Signed-off-by: David Lam <david@thedavid.net>
2020-01-16 01:15:40 -08:00
Jo-Philipp Wich
16d049f7cd luci-mod-status: reimplement route status page as client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-29 23:03:58 +01:00
Jo-Philipp Wich
939b371bc7 luci-mod-status: reimplement log pages as client side views
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-22 23:20:23 +01:00
Jo-Philipp Wich
b9bb34612e luci-mod-status: reimplement iptables status page as client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-22 23:20:23 +01:00
Jo-Philipp Wich
43a4481e10 luci-mod-status: replace iptables controller actions with cgi-io calls
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-22 23:20:23 +01:00
Jo-Philipp Wich
3a657b8ab5 luci-mod-network: replace controller address check action with cgi-io script
This change removes the last bit of Lua code from luci-mod-network.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-18 21:33:29 +01:00
Jo-Philipp Wich
ab07b8c4d9 luci-mod-network: reimplement diagnostics page as client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-16 18:07:18 +01:00
Jo-Philipp Wich
16853bcd2e luci-base: convert menu nodes to JSON
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-12-16 18:07:17 +01:00
Jo-Philipp Wich
392ba53eff luci-base, luci-mod-network: migrate getDUIDHints method to C plugin
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-08 10:25:30 +01:00
Jo-Philipp Wich
9e57fbb2c3 luci-base, luci-app-firewall: port custom rules to client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 20:34:57 +01:00
Jo-Philipp Wich
a43b1c6468 luci-base, luci-mod-status: convert process status to client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 20:07:58 +01:00
Jo-Philipp Wich
8d512f13ec luci-base: add luci/getProcessList RPC method
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 20:03:25 +01:00
Jo-Philipp Wich
f16a47042c luci-base, luci-mod-network: invoke ifdown directly in interface overview
Replace the `iface_down` endpoint with a direct invocation of `/sbin/ifdown`
and replace the interface connectivity check with a call to the new
`remote_addr` endpoint.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 17:56:58 +01:00
Jo-Philipp Wich
cfb5af89e1 luci-base, luci-mod-status: convert realtime stats to client side views
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 17:56:58 +01:00
Jo-Philipp Wich
a2f43983b6 luci-base: add luci/getRealtimeStats and luci/getConntrackList rpc methods
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-03 17:56:58 +01:00
Richard Yu
c360cdd1f0 luci-app-opkg: add ipk upload feature
Signed-off-by: Richard Yu <yurichard3839@gmail.com>
[fix duplicate upload errors, remove temporary file, tweak style]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
c72c78bed9 luci-mod-network: interfaces.js: issue iface restart via file/exec rpc call
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
6aa4b83f24 luci-mod-network: wireless.js: issue wifi restart via file/exec rpc call
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
c85af3d761 luci-mod-status: reimplement index status page as client side view
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
5ce16764ad luci-base, luci-mod-system: replace luci/setUmount with fs.exec calls
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
c67d2ddc2c luci-base, luci-mod-system: replace luci/setReboot with fs.exec
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00
Jo-Philipp Wich
6e633b3ed2 luci-base: consolidate network.js data acquisition
The new luci-rpc/getNetworkDevices procedure offers netdev enumeration
with included IPv4 and IPv6 address information as well as 64bit traffic
counters, so we can remove the calls to network.device/status and
luci/getIfaddrs now as we're able to obtain all info from a single source.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2019-11-01 12:03:33 +01:00