Commit graph

337 commits

Author SHA1 Message Date
Jo-Philipp Wich
6069f4f228 luci-mod-network: wireless.js: rename multicast_to_unicast option
The `multicast_to_unicast` option has been renamed to
`multicast_to_unicast_all` in OpenWrt commit
https://github.com/openwrt/openwrt/commit/09ea1db93

Fixes: #6472
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-07-26 15:05:53 +02:00
John Kohl
9070cfd1a4 luci-mod-network: interfaces.js: add dhcpv6_pd_min_len support
Add support for setting dhcpv6_pd_min_len, which enforces a floor on the
IPv6 prefix delegation length, so the administrator can conserve IPv6 address
space on an interface.

Signed-off-by: John Kohl <jtk.git@bostonpog.org>
2023-07-05 20:56:35 +02:00
Jan Hoffmann
a65825aeed luci-mod-network: improve descriptions for DSL annex option values
Spell out the names of the DSL standards to make the options easier to
understand. For modems supporting VDSL, also mention clearly which of
the options actually set the bits for VDSL2.

As the items now start with the name of an ADSL standard, use that for
ordering. The generic variants including VDSL2 support stay at the top,
as they should be a good choice in almost all cases.

Signed-off-by: Jan Hoffmann <jan@3e8.eu>
2023-07-02 13:51:39 +02:00
Manas Sambhus
fd5440a7be
luci-mod-network: wireless.js: add wifi-iface macaddr random support
Add ability to choose random or custom mac address for wifi-iface.
By default the driver mac address is used and this special feature needs
to be supported by the wireless driver.

Signed-off-by: Manas Sambhus <manas.sambhus+github@gmail.com>
[ drop redundant tags and improve commit description ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2023-06-25 00:20:54 +02:00
Ondřej Caletka
7e50256f70
luci-mod-network: add PREF64 support
Add support for ra_pref64 option for IPv6 Router Advertisements
options.
This option of IPv6 Router Advertisements allows devices connected to
a IPv6-only network to discover IPv6 prefix of the NAT64 gateway.
Devices can use this information for instance to setup client translator
(CLAT) from IPv4 to IPv6 in 464XLAT (RFC 6877) scenario or to handle
IPv4 address literal on application level.

Signed-off-by: Ondřej Caletka <ondrej@caletka.cz>
[ remove extra new line and fix commit description ]
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2023-06-24 23:53:24 +02:00
Jo-Philipp Wich
b2546c26b5 luci-mod-network: fix incorrectly reverting vlan device name
Fixes: #6435
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-06-20 00:31:21 +02:00
Jo-Philipp Wich
9b12a48c3f luci-mod-network: fix dropdown clipping on diagnostics page
The default overflow hidden style for table cell elements breaks action
dropdowns on the diagnostics page.

Fixes: #6379
Fixes: 5f2d305476 ("luci-mod-network: convert diagnostic page to LuCI look and feel")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-05-30 09:19:20 +02:00
Jo-Philipp Wich
b2476ba71d luci-mod-network: expose peerdns option for dhcpv6
Ref: 2be01cbfcb (commitcomment-111035308)
Fixes: 2be01cbfcb ("luci-mod-network: restrict peerdns option to protocols that implemenent it")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-04-28 22:42:24 +02:00
Glenn Washburn
6ad6a241c3 luci-mod-network: add stricter wireless interface name validation
Linux wireless interface names have the following restrictions:

 * It must not be an empty string
 * It must not be '.' or '..'
 * It must not contain any /, : or space character ( , \t, \n, ...)
 * It must be less than 16 chars
 * It likely must not contain any % either

Fixes: 8673aef8db ("luci-mod-network: remove uciname validation from wireless interface")
Signed-off-by: Glenn Washburn <development@efficientek.com>
[reword validation error messages, remove extended description text as it would be
 shown as part of the validation errors]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-03-15 23:56:59 +01:00
Hannu Nyman
92cce9a44a luci-mod-network: adjust DNS cache size placeholder
Adjust DNS cache size placeholder value to 1000 to
match the OpenWrt default after
a57796b137

Fixes #6254

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2023-02-27 05:47:55 +02:00
Jo-Philipp Wich
2234d0c5dd
Merge pull request #6104 from dhewg/6g
luci-mod-network: enable configuring wifi ax networks on the 6G band
2023-02-07 14:05:17 +01:00
Jo-Philipp Wich
276046c8e9 luci-mod-network: handle dynamic device configuration defaults
Most uci network device configuration settings have no specific default
value which means that netifd will only alter the related sysfs parameters
if an explicit value is specified in uci. When omitted from the
configuration, the related sysfs setting is left untouched.

This behaviour collides with LuCI's approach of purging boolean options
from the configuration if they match their default value, leading to the
inability to disable or enable certain settings as described in #6219.

Solve this issue by replacing flag widgets with tri-state selects offering
an "automatic" (default) as well as an explicit "enabled" and "disabled"
choice. Also query sysfs on load and preset the automatic choice with an
indication whether the underlying sysfs settings is currently active or not.

Fixes: #6219
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-02-07 10:09:42 +01:00
Jo-Philipp Wich
c13ef9406c luci-mod-network: interfaces.js: avoid stray empty device uci sections
Ensure that just created uci device sections are removed if the edit
option modal is cancelled without saving. This prevents empty, but
harmless `config device` sections from being created on a subsequent
Save & Apply operation.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-02-05 19:37:28 +01:00
Jo-Philipp Wich
7c91e62575 luci-mod-network: fix output style of diagnostics commands
Ensure that the output textarea uses a monospace font and preformatted text.

Fixes: 5f2d305476 ("luci-mod-network: convert diagnostic page to LuCI look and feel")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2023-01-27 14:00:33 +01:00
Andre Heider
01c5a63934 luci-mod-network: use "band" from iwinfo freqlist
Instead of mapping it by frequency.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-01-23 14:51:28 +01:00
Andre Heider
abad257fbb luci-mod-network: enable configuring wifi ax networks on the 6G band
Tested on a MT7921 device.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-01-23 14:51:28 +01:00
Andre Heider
eead21c5ab luci-mod-network: don't offer unsupported wireless hwmodes
This prevents offering e.g. 'Legacy' on ac/n only radios or
ax if hostapd wasn't compiled with ax support.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-01-23 14:51:28 +01:00
Hannu Nyman
8673aef8db luci-mod-network: remove uciname validation from wireless interface
Remove the 'uciname' validation rule, as it prevents using '-' that
is a valid character.

Fixes: 0c1be9ae5 luci-mod-network: Add length restriction to wireless

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2023-01-15 10:09:30 +02:00
Hannu Nyman
0c1be9ae53 luci-mod-network: Add length restriction to wireless interface name
Based on issue #6101, add a maxlength of 15 chars to the wireless
interface's optional name field. Also validate it as uciname.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2023-01-14 10:40:43 +02:00
Paul Dee
8414f916ba luci-mod-network: disambiguate DHCP IP set help text
Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2023-01-05 20:35:28 +00:00
Hannu Nyman
25a502b592
Merge pull request #5569 from systemcrash/radius_vlan
luci-mod-network: Expose WPA Enterprise RADIUS VLAN settings.
2022-12-29 12:18:49 +02:00
Hannu Nyman
45a91156d5 luci-mod-network: place wlan roaming related options to a tab
Collectd all WLAN roaming related options to a new dedicated tab.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2022-12-21 21:33:36 +02:00
Paul Dee
107791e9d8 luci-mod-network: (wireless) Expose WPA Enterprise RADIUS VLAN settings.
Tested on: 21.02.1

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2022-12-10 15:33:04 +01:00
Jo-Philipp Wich
858252c7df
Merge pull request #5572 from systemcrash/80211v
luci-mod-network: Expose 802.11v settings.
2022-12-10 13:46:44 +01:00
Paul Dee
b88156961f luci-mod-network: (wireless) Expose 802.11k settings.
Tested on: 21.02.1

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2022-12-10 02:58:40 +01:00
Jo-Philipp Wich
885e3a5f0b
Merge pull request #6063 from Zeranoe/fix-address-validator
luci-mod-network: fix address validation
2022-11-23 13:43:15 +01:00
Lukas Tribus
8607aa7a67 luci-mod-network: improve description for filterwin2k option again
Stop using the word useless both in the name and the description and call
the feature what it actually is (Filter SRV/SOA service discovery).

Signed-off-by: Lukas Tribus <lukas@ltri.eu>
[slightly reword commit message]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-11-23 13:38:42 +01:00
Jo-Philipp Wich
7c3705bb0f luci-mod-network: fix invalid markup in the relay tab
Fixes: #6107
Fixes: a627744bb5 ("luci-mod-network: 'relay' tab added")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-11-21 12:38:30 +01:00
Kyle Schwarz
de9341648a luci-mod-network: fix address validation
Fixes --server validation for:
- /domain[/domain]
- //
- /#/

Fixes hostname validation for:
- *.domain
- *domain

Changes ..domain to be an invalid hostname

Signed-off-by: Kyle Schwarz <zeranoe@gmail.com>
2022-11-19 16:34:04 -05:00
Jo-Philipp Wich
2be01cbfcb luci-mod-network: restrict peerdns option to protocols that implemenent it
Only some supported protocol extensions honour the `peerdns` options.

Fixes: #6093
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-11-15 01:44:28 +01:00
Hannu Nyman
20b765c77b luci-mod-network: DNS - support filtering A or AAAA records
Support Dnsmasq 2.87-5 feature to filter DNS results:
* remove IPv6 AAAA records and return only IPv4 addresses
* remove IPv4 A records and return only IPv6 addresses

Especially the removal of IPv6 AAAA records can be useful with
ISPs that provide IPv6 address resolving but do not actually
offer IPv6 routing/connectivity.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2022-11-12 20:54:59 +02:00
Florian Eckert
5f2d305476 luci-mod-network: convert diagnostic page to LuCI look and feel
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2022-11-07 13:40:24 +01:00
Florian Eckert
1d157d3a50
Merge pull request #6047 from systemcrash/luci-mod-network-relay
luci-mod-network: 'relay' tab added
2022-10-28 11:02:47 +02:00
Paul Dee
a627744bb5 luci-mod-network: 'relay' tab added
Adds LuCI GUI for dnsmasq DHCP 'relays'.

The helper functions in dnsmasq/files/dnsmasq.init limit behaviour
whereby it is not possible to omit server_addr, where to omit
it (dnsmasq supported) would result in a broad- or multicast further on.

Tested on 22.03.2

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2022-10-28 01:38:07 +02:00
Jo-Philipp Wich
9af8486517 luci-mod-network: gracefully handle empty channel lists
Avoid undefined value access when the channel list is empty.

Fixes: #5937, #5951
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-27 16:10:47 +02:00
Florian Eckert
6f470e0d76 luci-mod-network: remove uppercase for interface name in modal view
Unify the network name display as shown in the overview by removing the
uppercase conversion.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2022-10-27 10:46:54 +02:00
Florian Eckert
5ffaf47842 luci-mod-network: remove uppercase for interface name on overview page
In the overview page, the name of the interface is converted to
uppercase. However, this is not the name in the configuration. From my
point of view, this makes no sense. The name displayed should correspond
exactly to the name in the configuration.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2022-10-26 12:10:31 +02:00
Jo-Philipp Wich
b1ab4e5ba9 luci-mod-network: remove uneeded libiwinfo-lua dependency
Since the LuCI network admin module was rewritten into client side views,
there is no server side Lua processing anymore. The iwinfo routines are
utilized through the corresponding rpcd plugin.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-25 01:03:37 +02:00
Paul Dee
45f02d94b2 luci-app-dhcp: 'addresses' helptext improvement with info from manpage.
Placeholder hint also reflects syntax.

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
[replace asdf.com with example.com, use … instead of ..., remove uneeded
 &nbsp; entities]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-20 23:54:40 +02:00
Paul Dee
3240714ed3 luci-mod-network: 'mxhosts' tab added
DHCP Help does not document mxhost, but they are available in dnsmasq.

This effectively implements MX records within DNS.

Tested on 22.03.2

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
[fix _() calls, fix commit subject, rebase onto current master]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-20 23:47:12 +02:00
Paul Dee
08a089740a luci-mod-network: 'srvhosts' tab added
DHCP Help does not document srv-host, but they are available in dnsmasq.

This effectively implements SRV records within DNS.

Tested on 22.03.2

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
[fix _() calls, join translation strings on the same line, replace &hellip;
 with …, fix commit subject]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-10-20 23:36:56 +02:00
Jan Hoffmann
ec4f219b2b luci-mod-network: improve description for filterwin2k option
Make it clear that this option also filters some not-so-useless queries.

Signed-off-by: Jan Hoffmann <jan@3e8.eu>
2022-09-30 19:49:43 +02:00
Hannu Nyman
2c3c7f5c50 luci-mod-network: Offer ft-over-air by default for 802.11r
OpenWrt commit 2984a0420 changed the default 802.11r Fast Transition
method to be ft-over-air instead of ft-over-ds.

Offer ft-over-air as the first item in the drop-down list, so that
it gets selected by default when 802.11r option is enabled.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
2022-09-01 18:08:56 +03:00
Jo-Philipp Wich
46181e5ace
Merge pull request #5570 from systemcrash/rsn_preauth
luci-mod-network: Expose RSN Preauth WPA2-EAP setting.
2022-08-30 20:53:42 +02:00
Jo-Philipp Wich
2adba1b8d0
Merge pull request #5589 from systemcrash/multi_to_unicast
luci-mod-network: Expose multicast_to_unicast setting
2022-08-30 20:53:26 +02:00
Jo-Philipp Wich
801d4513b2 luci-mod-network: ensure consistent bridge port and network interface order
Ref: #5899
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-07-27 17:33:59 +02:00
Jo-Philipp Wich
ef7fe79ffc luci-mod-network: demote WPA-PSK to "low" security in the choice list
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-07-12 16:12:30 +02:00
Jo-Philipp Wich
3a6f37f9df luci-mod-network: fix sort operations
Ensure to return [-1, 0, 1] from the sort callback instead of [0, 1]
which fails in non-FF browsers.

Fixes: #5859
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-07-08 16:03:14 +02:00
Jo-Philipp Wich
53a998895b luci-mod-network: wireless.js: fix typo in description string
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-06-21 23:54:12 +02:00
Jo-Philipp Wich
f039069ac5 luci-mod-network: wireless.js: expose wifi-iface macaddr option
Fixes: #5845
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-06-21 08:52:50 +02:00