Commit 890f2f4
committed
luci-app-upnp: update ACL options, migrate section
- Ignorable and cloneable ACL entries, always translated `Action`
- Improve UI with direct editability, clearer help wording, and rename
to `Access Control List`
- Note that the ACL is now rejected by default, with no preset and
accept extra ports. Add (ignored) ACL template entries on migration
- Migrate ACL entries to the new section name `acl_entry`
- The following ACL UCI options been added or changed, and the previous
options are migrated on updating:
acl_entry UCI options | Change | Previous name
----------------------------|----------------------------|--------------
action | New/updated values (1) |
int_port | Remove colon separator (2) | int_ports
ext_port | Remove colon separator (2) | ext_ports
descr_filter | New option (3) |
1. Allow ignore, and update action option to use the nftables terms
(allow/deny -> accept/reject). To avoid adding inverted actions when
changing via LuCI, ensure any missing are set, as LuCI and UCI had
not matching action defaults. Missing actions are now ignored/logged
2. Ensure that the hyphen (-) is only used as a port range separator by
migration, as the colon (:) is not valid in LuCI
3. Add missing UCI option to set a regular expression to check for a
UPnP IGD IPv4 port map description, and fix the current collision
with the comment field which was not noticed due to a daemon bug
https://redirect.github.com/openwrt/packages/pull/24495
https://redirect.github.com/miniupnp/miniupnp/pull/853
- Refactoring by adding a more universal usable `is_port_or_range`
function instead of `upnpd_get_port_range` and check if it has a valid
range, and removes a shellcheck warning
- Rename `conf_rule_add` function to `upnpd_add_acl_entry`
(to merge with prior)
Signed-off-by: Self-Hosting-Group <selfhostinggroup-git+openwrt@shost.ing>1 parent b0447ca commit 890f2f4
File tree
1 file changed
+28
-10
lines changed- applications/luci-app-upnp/htdocs/luci-static/resources/view/upnp
1 file changed
+28
-10
lines changedLines changed: 28 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
336 | 336 | | |
337 | 337 | | |
338 | 338 | | |
339 | | - | |
340 | | - | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
341 | 342 | | |
342 | 343 | | |
| 344 | + | |
343 | 345 | | |
| 346 | + | |
344 | 347 | | |
345 | 348 | | |
346 | 349 | | |
| |||
351 | 354 | | |
352 | 355 | | |
353 | 356 | | |
354 | | - | |
| 357 | + | |
| 358 | + | |
355 | 359 | | |
356 | 360 | | |
357 | 361 | | |
358 | | - | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
359 | 365 | | |
360 | | - | |
| 366 | + | |
361 | 367 | | |
362 | | - | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
363 | 371 | | |
364 | | - | |
| 372 | + | |
365 | 373 | | |
366 | | - | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
367 | 382 | | |
368 | 383 | | |
369 | | - | |
370 | | - | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
371 | 389 | | |
372 | 390 | | |
373 | 391 | | |
| |||
0 commit comments