Update timezone data to 2022f.
* http://mm.icann.org/pipermail/tz-announce/2022-October/000075.html
- Mexico will no longer observe DST after 2022, except for areas
near the US border that continue to observe US DST rules.
On 2022-10-30 at 02:00 the Mexican state of Chihuahua moves
from -07 (-06 with DST) to year-round -06.
- Fiji will not observe DST in 2022/3.
For now, assume DST is suspended indefinitely.
- Simplify four Ontario zones.
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
[adapt the commit in master, lua instead of ucode]
Avoid undefined value access when the channel list is empty.
Fixes: #5937, #5951
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 9af8486517)
this let browser automatically fill according to HTML spec for input elements.
luci-theme-bootstrap and luci-base are affected.
Signed-off-by: Viktor Tsvetkov <zwetvik@gmail.com>
[indentation fix]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 3e9d9a9dbb)
Ensure to not display public key comments verbatim in order to prevent
injection of markup.
Reported-by: Eric McDonald <ericmcdonald@protonmail.com>
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 944b55738e)
OpenWrt commit 2984a0420 (0588b124e in 22.03) 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>
(cherry picked from commit 2c3c7f5c50)
Since HTTP cookies may not overwrite HTTPS ("secure") ones, users are
frequently unable to log into LuCI when a stale, "secure" `sysauth` cookie
is still present in the browser as it commonly happens after e.g. a
sysupgrade operation or when frequently jumping between HTTP and HTTPS
access.
Rework the dispatcher to set either a `sysauth_http` or `sysauth_https`
cookie, depending on the HTTPS state of the server connection and accept
both cookie names when verifying the session ID.
This allows users to log into a HTTP-only LuCI instance while a stale,
"secure" HTTPS cookie is still present.
Requires commit 2b0539ef9d ("lucihttp: update to latest Git HEAD") to
function properly.
Fixes: #5843
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit e1932592c3)
Before opening (rendering) a nested modal map, make sure to save the parent
modal map in order to persist any structural uci changes, such as newly added
anonymous sections to prevent the nested map from operating on stale values
or ephemeral config section IDs.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 3be479446b)
The existing logic for cloning section options into the modal form section
container did not properly handle SectionValue objects. Introduce a new
`cloneOptions()` helper to recursively traverse and properly clowning
such nested sections.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit f24606b1ff)
The nested section modal might have changed values also covered/displayed by
the parent map, so ensure to reload all parent maps in the current modal
view stack to ensure that no stale values are shown on return.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 0c81e25faa)
Only stack a new modal CBI map on top of the currently displayed modal one
if the related map or section differs. This prevents misbehavior when
switching the protocol of interfaces.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit f2fa59e89a)
The existing implementation was hardcoding the empty TableSection placeholder
instead of invoking `renderSectionPlaceholder()` which might be overridden by
various forms.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 818776451d)
If a whitespace-only description is set on an element, the CSS :empty
selector will not match, causing description icons to be shown when
there's no actual content.
To avoid that, trim the description string when building the element.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit b6ae1d4f4a)
- Annotate gridsection textvalue cells as CBI.DummyValue widgets
- Replace `<br>` elements with newlines in `stripTags()`
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 9c136c9bea)
Since the `handleModalSave()` handler of the GridSection class invokes
`handleModalCancel()` after saving the data but before removing the
`addedSection` property, the `handleModalCancel` handler incorrectly
removed the uci section that has just been created.
This bug didn't affect anonymous GridSections because after saving the
id of the created section changes, causing the remove command to fail,
but for named ones with stable section IDs, the bug manifested.
Solve the issue by passing a flag to `handleModalCancel()` indicating
whether the method was called from a safe operation and use it do
decide whether to delete the new staged uci section or not.
Fixes: #5760
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 2771360108)
Under certain circumstances, a staged uci option value might get unset
again before saving the config, leaving an empty section change set
behind, causing the save call to send an empty uci set request via rpc,
triggering an ubus code 4 (Resource not found) error.
In particular this prevented bridge VLANs from getting saved properly.
Fixes: #5876
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 25dcd0b77c)
For network devices declared in uci but not yet created by netifd, the
runtime status information will be unavailable, causing methods such as
`getType()` to assume plain ethernet interfaces and `getParent()` to fail
resolving parent devices.
Fall back to infer the information from uci configuration settings in such
cases to give accurate type hints to callers.
In particular, this prevents LuCI from turning wireless target networks
containing a to-be-created bridge device into bridges themselves.
Fixes: https://github.com/openwrt/packages/issues/18768
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 8effea58d7)
If specific settings such as the protocol, IP address or netmask of an
interface the user is connected to are changed, the apply/rollback
mechanism might interfere. Display an additional warning dialog in this
case, instructing the user to manually reconnect and offering to continue
with a less safe unchecked apply mechanism.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 733ee9a7b6)
Previously, "Apply unchecked" was only possible from the save action of CBI
maps, allow to invoke it from the configuration change dialog as well.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 8583efb5a9)
Do not abort the poll loop if some confirm request attempts fail, which
might happen when the device starts rolling back its configuration.
Before that fix, the rollback information dialog offering an unchecked
apply was not reliably presented in such situations.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit b6797821b8)
On boards with ADSL instead of VDSL support we need to expect an
`/sbin/dsl_cpe_control` instead of an `/sbin/vdsl_cpe_control` executable.
Ref: https://forum.openwrt.org/t/dsl-line-stats/126580
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 111c551cdb)
Always offer english, regardless of whether a dummy language pack for it
is installed or not.
Fixes: #5783
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit c2eb30bba7)
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>
(cherry picked from commit 1ae142d7d1)
Do not expose the iptables status page as menu item when nftables is present
on the system. Instead add a warning banner to the nftables status page
directing the user to the hidden iptables status page when we encounter
legacy rules on the system.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 2f80fe3767)
The "absent" dependency type requires the given path to not exist on the
local system for the condition to be satisified. This is useful to disable
menu nodes depending on the presence of specific files.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 2e4b5fb8ff)
UCI option `interface` for sysntpd server was introduced in
OpenWrt commit 4da60500ebd2. NTP server binds to the specified interface,
or if unspecified, to all.
This patch adds selection widget to LuCI.
Signed-off-by: Alexey Dobrovolsky <dobrovolskiy.alexey@gmail.com>
(cherry picked from commit 24ac5a2bf6)