luci-app-strongswan-swanctl: remove 15 char section name limit

The 'swanctl.conf' does not impose any length restriction on connection
and children (section) names. They are plain strings parsed by strongswan
config parser without a fixed-size buffer.

Likewise, uci does not enforce a maximum length for named sections.
libuci's uci_validate_str() only restricts the allowed character set
(alphanumeric and underscore, for shell compatibility) and allocates
section names dynamically via strdup(), so there is no built-in
buffer size that would truncate or reject longer names.

The previous 15-character cap therefore had no basis in either
'swanctl.conf' or uci itself and can be dropped without risking
truncation, parsing errors, or incompatibility.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
Florian Eckert authored and Florian Eckert committed 2026-09-30 11:58:57 +02:00
1 parent f026182f14
commit 242ba6ae6e
1 file changed
+1 -2
@@ -44,9 +44,8 @@ function sectionNameCheck(extra_class) {
return s['.name'] == v;
})) {
return _('Remotes, Encryption Proposals and Tunnels may not share the same names.') + ' ' +
_('Use combinations like tunnel1_phase1 that do not exceed 15 characters.');
_('Use combinations like tunnel1_phase1.');
}
if (v.length > 15) return _('Name length shall not exceed 15 characters');
return true;
}, 'blur', 'keyup');
return el;