Commit graph

268 commits

Author SHA1 Message Date
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
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
Jo-Philipp Wich
34813ff2b6 luci-mod-network: interfaces.js: remove references to original MAC/MTU
Do not show the original values for MAC and MTU in device list tooltips
anymore as the values we read from the netdev might already stem from
overridden config settings.

Since there's no generic way to acquire that information, remove the
potentially confusing information.

Fixes: #5820
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-05-20 19:41:14 +02:00
Jo-Philipp Wich
904c174caf luci-mod-network: routes: allow prefixes as route source
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-04-28 12:08:37 +02:00
Jo-Philipp Wich
1ae142d7d1 luci-mod-network: diagnostics: peg max traceroute hops to rpc timeout
In the worst case, traceroute might take up to 30s to complete when tracing
a completely unreachable path, due to the default limit of 30 hops multiplied
by the per-hop deadline of 1 second (-w 1).

Limit the maximum amount of hops to the configured rpc execution timeout,
20 second by default, in order to avoid running into timed out rpc requests.

Fixes: #5782
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-04-27 20:43:05 +02:00
Jo-Philipp Wich
bd739c7abc
Merge pull request #5718 from ptpt52/fix-switch
luci-mod-network: switch: Fix multi instances handling
2022-04-27 12:47:26 +02:00
Chen Minqiang
d65c5e6496 luci-mod-network: switch: Fix multi instances handling
Signed-off-by: Chen Minqiang <ptpt52@gmail.com>
2022-04-27 18:36:33 +08:00
Jo-Philipp Wich
f04011f068 luci-mod-network: avoid needlessly writing none RA flags
Fixes: #5725
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-04-27 12:19:13 +02:00
Max S Kash
8a46648e5b luci-mod-status,mod-network: Added fqdn-name to DHCPv4 lease table
Added code to display fcdn-name in DHCPv4 lease table.
(based on code in DHCPv6 lease table)

Signed-off-by: Max S Kash <asukms@ya.ru>
Indentation adjused and wrapped commit message
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
2022-03-28 09:52:05 +02:00
Paul Dee
b2101a23a9 luci-mod-network: (wireless) Expose multicast_to_unicast setting.
From https://w1.fi/cgit/hostap/commit/?id=34f7c699a6bcb5c45f82ceb6743354ad79296078
add support for multicast_to_unicast conversion in the wireless settings

Tested on: 21.02.1

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2022-02-22 16:12:00 +01:00
Jo-Philipp Wich
8890111784
Merge pull request #4515 from TDT-AG/pr/20201014-diag-ping6
luci-mod-network: diagnostics.js: don't pass IP version flag to ping6
2022-02-18 21:20:49 +01:00
Matthew Hagan
89056536e1 luci-mod-network: add descriptions to routing/rules sections
Provide descriptions for options in the IP routing and rules sections.
Test is based upon that within the OpenWrt documentation[1].

[1] https://openwrt.org/docs/guide-user/network/routing/routes_configuration

Signed-off-by: Matthew Hagan <mnhagan88@gmail.com>
2022-02-10 15:31:24 +00:00
Matthew Hagan
72e76d5c5a luci-mod-network: add support for UID iprules
Allow user-specific routing policies to be defined in luci. A single UID
or range of UIDs may be defined.

Signed-off-by: Matthew Hagan <mnhagan88@gmail.com>
2022-02-09 17:46:26 +00:00
Paul Dee
14f98df1c8 luci-mod-network: Clean up RADIUS strings in EAP options.
Plus placeholders for default ports.

Signed-off-by: Paul Dee <systemcrash@users.noreply.github.com>
[resolved trivial conflicts]
2022-01-23 12:07:37 +02:00
Jo-Philipp Wich
433db83c65 luci-mod-network: fix creating joining wireless networks
Fixes: #5651
Fixes: 1c798d1a08 ("luci-base: form.js: allow nesting Grid and Table sections")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-01-21 20:32:17 +01:00
Jo-Philipp Wich
35df2adaf8 luci-mod-network: fix creating new interfaces
Fixes: #5646
Fixes: 1c798d1a08 ("luci-base: form.js: allow nesting Grid and Table sections")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-01-19 14:36:46 +01:00
Jo-Philipp Wich
0ef82b3c58 luci-mod-network: fix reading back rpfilter configuration value
Fixes: #5635
Fixes: faad7464a8 ("luci-mod-network: add support for network.device sections")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2022-01-07 19:20:27 +01:00
Jo-Philipp Wich
c534f0671d luci-mod-network: wireless.js: retain maclist contents
Fixes: #5579
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-12-09 15:11:07 +01:00
Paul Dee
4e3ff840eb luci-mod-network: (wireless) Expose RSN Preauth WPA2-EAP setting.
Tested on: 21.02.1

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2021-12-08 02:00:44 +01:00
Jo-Philipp Wich
5f98f8cac4 luci-mod-network: allow IPv6 dns, dns_service and domain for RA only mode
Fixes: #5564
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-12-01 23:20:06 +01:00
Jo-Philipp Wich
d19d717de2 luci-mod-network: fix loading ra_mtu and ra_hoplimit options
Fixes: #5565
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-12-01 23:20:06 +01:00
Jo-Philipp Wich
b8d3ca6f82 luci-mod-network: fix unbalanced and confusing markup in DHCP translation
The string `<%s>...<%s>` is invalid HTML and will confuse translation software
like poedit as well as human translators. It is not clear that `<%s>...<%s>`
is supposed to interpolate into both a start and end tag and `<%s>` might be
mistaken as a quoted form of `%s` like `«%s»` or `〈%s〉`.

Replace the string with `<a href="%s">...</a>` to make it immediately clear
that the acronym is surrounded by an HTML anchor, only pass the destination
URL via string formatting to avoid mistranslations there.

Fixes: 3bfcf99a68 ("luci-mod-network: fix unbalanced and confusing markup in DHCP translation")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-12-01 16:44:20 +01:00
Paul Dee
d5b00569af luci-mod-network: Disambiguate DNS config message
Responses themselves are not RFC1918, but the address types that they
contain may be.

Signed-off-by: Paul Dee <itsascambutmailmeanyway@gmail.com>
2021-12-01 02:12:17 +01:00
Jo-Philipp Wich
849772df96 luci-mod-network: use firewall.getZoneColorStyle() in interface view
Use the new `firewall.getZoneColorStyle()` helper to apply background
zone color styles to the interface boxes.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-11-11 13:00:50 +01:00
Jo-Philipp Wich
c795a206eb luci-mod-network: fix invalid markup in TFTP/PXE settings tab
Also resync translations accordingly.

Fixes: #5475
Fixes: 3165d5ea3f ("luci-mod-network: Add PXE Boot options tab under DHCP and DNS")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-31 22:42:04 +01:00
Paul Dee
3165d5ea3f luci-mod-network: Add PXE Boot options tab under DHCP and DNS
This commit adds support for managing `boot` sections in /etc/config/dhcp.

Signed-off-by: Paul Dee <systemcrash@users.noreply.github.com>
[Hide alias interfaces in network select, reword commit message]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-25 21:09:32 +02:00
Jo-Philipp Wich
216767f420 luci-mod-network: remove related bridge-vlan sections on deleting device
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-22 19:18:27 +02:00
Jo-Philipp Wich
f4f64b91ca luci-mod-network: allow sorting static leases
Fixes: #5453
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-19 23:13:43 +02:00
Jo-Philipp Wich
9aaebdf8de
Merge pull request #5436 from vgaetera/dhcp-ipset 2021-10-12 11:21:56 +02:00
Jo-Philipp Wich
4b5da809e0 luci-mod-network: diagnostics: remove leftover attribute
There is no `type` attribute for `select` elements.

Fixes: 5ac9fd7b3b ("luci-mod-network: diagnostics: remove arp-scan install placeholder")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-11 23:52:40 +02:00
Jo-Philipp Wich
5ac9fd7b3b luci-mod-network: diagnostics: remove arp-scan install placeholder
We do not want to advertise functionality that is not installed as it may
have been left out intentionally. Referring to "Missing" functionality
is confusing in this case. It is also not comparable to missing protocol
extension hints as those are backed by actual user configuration.

Also replace the freetext input with a dropdown of known network devices
as the hardcoded `br-lan` is not universally applicable to all setups.

In general we want to avoid hardcoding defaults which might deviate from
the system state.

Finaly drop the superfluous width annotations and add a missing space
to the RPC command declaration.

Fixes: 22b7442011 ("luci-mod-admin-full: add arp-scan to network diagnostic")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2021-10-11 23:47:30 +02:00
Vladislav Grigoryev
6ee3482af2 luci-mod-network: support dhcp.ipset as section
Allow configuring ipset sections in the dhcp config:
https://openwrt.org/docs/guide-user/base-system/dhcp#ip_sets
This can also be combined with instance-specific IP sets:
https://github.com/openwrt/luci/pull/5402
However, it makes easier to assign domains to IP sets.

Signed-off-by: Vladislav Grigoryev <vg.aetera@gmail.com>
2021-10-12 00:25:01 +03:00
Paul Spooren
22b7442011 luci-mod-admin-full: add arp-scan to network diagnostic
This is a JavaScript rewrite of the PR#5152

It adds the ability to perform ARP scans if the tool `arp-scan` is
installed.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-10-11 11:15:17 -10:00
Paul Dee
c0299e2c3d luci-mod-network: spelling / grammar
"Setup" is a noun, the thing. "Set up" is a verbal idiom, the action.

One cannot setup a DHCP server, just as one cannot fuckup a test, or
ripup some paper. One can, however, set a DHCP server up, and one can
fuck a test up, and rip some paper up.

Signed-off-by: Paul Dee <systemcrash@users.noreply.github.com>
2021-10-08 14:12:11 -10:00