Since all netifd device types inherit generic device settings, we can
simplify various aspects of the device configuration ui and drop unused
code while we're at it.
- Remove setIfActive() helper, superseded by commit
f3f74bd0fe ("luci-base: form.js: consider aliased options in AbstractValue.remove()")
- Remove most dependency constraints to make all generic device settings
available for all device types
- Add MTU value validation to disallow exceeding parent device MTU for
VLAN interfaces
- Dynamically update placeholder values when changing base or parent
device options
- Undo VLAN network config hack since all options are available now.
Reverts commit
3c6b59504a ("luci-mod-interfaces: simplify configuring MAC address of 802.1q devices")
- Do not suggest inactive wireless networks as existing device or base
device choices
- Disallow specifying names of already existing network devices when
creating new device settings
- Fix a number of multicast dependency specifications
- Drop now unused functions
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
In case multiple bridges with bridge vlans are declared, LuCI did not
correctly filter the VLANs to show only the ones belonging to the
bridge being configured currently.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
- Do not incorrectly put the IP addresses from the rrdns reply into the
first hint, instead distribute hostnames to the appropriate hints.
- Avoid returning stale lease information from previously parsed records
by clearing the static struct before each parse attempt.
- Improve existing checks for empty MAC addresses and unspecified IPv6
addresses.
Fixes: #5126
Fixes: 87bcf9e923 ("rpcd-mod-luci: Return array of addresses in getHostHints")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
707feae parse_css: do not omit white space in url() property values
Ref: 6960819997 (commitcomment-52088358)
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Chain the exec calls to enable and start the SQM service and only reload
the view once these operations are complete and return the entire promise
chain from the handler function to ensure that the busy indicator remains
active throughout the entire duration of the operation.
Also replace exec_direct() with exec() as there is no need to bypass ubus
for the init script calls.
Fixes: e76d9cc767 ("luci-app-sqm: fix JS error if service is disabled")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* support the new 'ban_fetchinsecure' option
* improve the chain help text to make clear that you can assign
multiple FW chains
Signed-off-by: Dirk Brenken <dev@brenken.org>
Ensure that the overflow styles are reapplied after a redraw. This also
simplifies the code as a side-effect.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Currently translated at 100.0% (49 of 49 strings)
Translated using Weblate (Japanese)
Currently translated at 68.0% (34 of 50 strings)
Translation: OpenWrt/LuCI/applications/acme
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacme/ja/
Translated using Weblate (Japanese)
Currently translated at 89.6% (26 of 29 strings)
Translation: OpenWrt/LuCI/applications/acl
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacl/ja/
Translated using Weblate (Japanese)
Currently translated at 94.5% (155 of 164 strings)
Translation: OpenWrt/LuCI/applications/mwan3
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsmwan3/ja/
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1739 of 1739 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pt_BR/
Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1739 of 1739 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/zh_Hans/
Translated using Weblate (Korean)
Currently translated at 62.0% (31 of 50 strings)
Translation: OpenWrt/LuCI/applications/acme
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacme/ko/
Translated using Weblate (Korean)
Currently translated at 34.1% (593 of 1739 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/ko/
Translated using Weblate (Spanish)
Currently translated at 98.9% (1720 of 1739 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/es/
Co-authored-by: Franco Castillo <castillofrancodamian@gmail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Meano Lee <meanocat@gmail.com>
Co-authored-by: Satoru Yoshida <ramat@ram.ne.jp>
Co-authored-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Co-authored-by: asdf1234 <cydyellowgreen@gmail.com>
Signed-off-by: Franco Castillo <castillofrancodamian@gmail.com>
Signed-off-by: Meano Lee <meanocat@gmail.com>
Signed-off-by: Satoru Yoshida <ramat@ram.ne.jp>
Signed-off-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Signed-off-by: asdf1234 <cydyellowgreen@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/openwrt/lucimodulesluci-mod-dashboard/ja/
Translation: OpenWrt/LuCI/modules/luci-mod-dashboard
Fixes compilation under 32bit systems by using the proper printf format
specifier for size_t values.
Also fixes compilation with Ninja by appending instead of
overwriting CMAKE_OPTIONS.
Fixes: #5116
Suggested-by: Rosen Penev <rosenp@gmail.com>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* fix a 'resource not found error' if the sqm service has been disabled
and the dir '/var/run/sqm/available_qdiscs' not exist
* inform the user about this issue and provide a button
to enable & start the service
Signed-off-by: Dirk Brenken <dev@brenken.org>
The migration code attempted to add new device sections instead of moving
the ifname option to a ports list within the existing ones.
Fixes: #5108
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Restore the display of bridge port device icons in the interface overviews.
This feature has been lost after migrating the network config from legacy
bridge declarations to device bridge declarations.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
OpenWrt switched from "option hwmode" to "option band" in order to select
the frequency band to use for the radio phy.
Extend the channel selector to recognize and use an existing "option band"
to select the appropriate channel list. When operating upon a wireless
configuration still using "option hwmode", then translate it to a band
value internally and translate it back to "option hwmode" on save.
This should provide forward- and backwards compatibility with both current
OpenWrt master and older versions still using hwmode.
Fixes: #5106
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This calls striptags() on the hostname to prevent any XSS over the
hostname. This should fix CVE-2021-33425 as far as I understood it.
If someone adds some Javascript into system.@system[0].hostname it would
have been directly added to the page, this prevents the problem.
This can only be exploited by someone being able to modify the uci
configuration, normally a user with such privileges could also just
modify the webpage.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
- Turn IPv4-Address into IPv4 address
- Turn IPv4-Gateway into IPv4 gateway
- Turn IPv6-Address into IPv6 address
- Turn IPv6-Gateway into IPv6 gateway
- Turn MAC-Address into MAC address
Also remove related duplicate translation entries.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Use a common nomenclature for logical network interfaces, physical
network devices, wireless networks and radio phys.
Also add missing translations for recently added strings.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Currently translated at 100.0% (29 of 29 strings)
Translation: OpenWrt/LuCI/applications/acl
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacl/ko/
Translated using Weblate (Greek)
Currently translated at 8.1% (3 of 37 strings)
Translation: OpenWrt/LuCI/applications/sqm
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssqm/el/
Translated using Weblate (Greek)
Currently translated at 3.0% (2 of 66 strings)
Translation: OpenWrt/LuCI/applications/yggdrasil
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsyggdrasil/el/
Translated using Weblate (Greek)
Currently translated at 100.0% (12 of 12 strings)
Translation: OpenWrt/LuCI/applications/bcp38
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsbcp38/el/
Translated using Weblate (Chinese (Simplified))
Currently translated at 100.0% (1744 of 1744 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/zh_Hans/
Translated using Weblate (Portuguese (Brazil))
Currently translated at 97.4% (1700 of 1744 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pt_BR/
Translated using Weblate (Polish)
Currently translated at 100.0% (1744 of 1744 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/pl/
Translated using Weblate (Greek)
Currently translated at 28.9% (505 of 1744 strings)
Translation: OpenWrt/LuCI/modules/luci-base
Translate-URL: https://hosted.weblate.org/projects/openwrt/luci/el/
Translated using Weblate (Korean)
Currently translated at 55.1% (16 of 29 strings)
Translation: OpenWrt/LuCI/applications/acl
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacl/ko/
Translated using Weblate (Korean)
Currently translated at 55.1% (16 of 29 strings)
Translation: OpenWrt/LuCI/applications/acl
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsacl/ko/
Translated using Weblate (Russian)
Currently translated at 100.0% (17 of 17 strings)
Translation: OpenWrt/LuCI/applications/eoip
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationseoip/ru/
Translated using Weblate (Russian)
Currently translated at 38.8% (82 of 211 strings)
Translation: OpenWrt/LuCI/applications/dockerman
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsdockerman/ru/
Translated using Weblate (Russian)
Currently translated at 98.1% (161 of 164 strings)
Translation: OpenWrt/LuCI/applications/mwan3
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsmwan3/ru/
Translated using Weblate (Russian)
Currently translated at 100.0% (196 of 196 strings)
Translation: OpenWrt/LuCI/applications/ddns
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationsddns/ru/
Translated using Weblate (Russian)
Currently translated at 95.3% (103 of 108 strings)
Translation: OpenWrt/LuCI/applications/simple-adblock
Translate-URL: https://hosted.weblate.org/projects/openwrt/luciapplicationssimple-adblock/ru/
Co-authored-by: Eric <spice2wolf@gmail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Matthaiks <kitynska@gmail.com>
Co-authored-by: Nikolay Parukhin <parukhin@gmail.com>
Co-authored-by: Stefanos Batsios <bouzouste@hotmail.com>
Co-authored-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Co-authored-by: asdf1234 <cydyellowgreen@gmail.com>
Co-authored-by: thenist <p717394@gmail.com>
Signed-off-by: Eric <spice2wolf@gmail.com>
Signed-off-by: Matthaiks <kitynska@gmail.com>
Signed-off-by: Nikolay Parukhin <parukhin@gmail.com>
Signed-off-by: Stefanos Batsios <bouzouste@hotmail.com>
Signed-off-by: Wellington Terumi Uemura <wellingtonuemura@gmail.com>
Signed-off-by: asdf1234 <cydyellowgreen@gmail.com>
Signed-off-by: thenist <p717394@gmail.com>