From 637c0751936252ca6910b17d8c8e23e2bb67ccab Mon Sep 17 00:00:00 2001 From: "Daniel F. Dickinson" Date: Mon, 19 Jan 2026 02:44:52 -0500 Subject: [PATCH] luci-app-radicale3: use ip6 bracket notation Update iphostport validation to use bracket notation for ipv6 IP addresses. Radicale understands it, and it is the preferred notation when using an IP address and port, together. Signed-off-by: Daniel F. Dickinson --- .../htdocs/luci-static/resources/view/radicale3.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/applications/luci-app-radicale3/htdocs/luci-static/resources/view/radicale3.js b/applications/luci-app-radicale3/htdocs/luci-static/resources/view/radicale3.js index 8246b8ade3..038d425609 100644 --- a/applications/luci-app-radicale3/htdocs/luci-static/resources/view/radicale3.js +++ b/applications/luci-app-radicale3/htdocs/luci-static/resources/view/radicale3.js @@ -53,11 +53,11 @@ return view.extend({ button = ''; - if ((radicale_address == '127.0.0.1') || (radicale_address == '::1')) { + if ((radicale_address == '127.0.0.1') || (radicale_address == '[::1]') || radicale_host == 'localhost') { ui.addNotification(_('Need a listen address'), _('Radicale needs a non-loopback IP address for your browser to access the web interface')); } else { - if (radicale_address == '0.0.0.0' || radicale_address == '::') { + if (radicale_address == '0.0.0.0' || radicale_address == '[::]') { radicale_address = window.location.hostname; } radicale_port = radicale_host.substring(radicale_host.lastIndexOf(':') + 1) || '5232'; @@ -84,8 +84,8 @@ return view.extend({ o = s.taboption('main', form.DynamicList, 'host', _('Host:port')); o.optional = true; - o.datatype = 'or(hostport(0),ipaddrport(0))'; - o.default = ['127.0.0.1:5232', '::1:5232']; + o.datatype = 'or(hostport(0),ipaddrport(1))'; + o.default = ['127.0.0.1:5232', '[::1]:5232']; s.tab('advanced', _('Advanced'));