From f60c72dc78da3ff14ccc23988b342d94a662f406 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Fri, 27 Oct 2023 22:55:15 +0200 Subject: netwatch-dns: match on word boundary --- netwatch-dns.rsc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'netwatch-dns.rsc') diff --git a/netwatch-dns.rsc b/netwatch-dns.rsc index 119a367..3e3e27c 100644 --- a/netwatch-dns.rsc +++ b/netwatch-dns.rsc @@ -26,7 +26,7 @@ $ScriptLock $0; :local DnsFallback ({}); :local DnsCurrent [ /ip/dns/get servers ]; -:foreach Host in=[ /tool/netwatch/find where comment~"dns" status="up" ] do={ +:foreach Host in=[ /tool/netwatch/find where comment~"\\bdns\\b" status="up" ] do={ :local HostVal [ /tool/netwatch/get $Host ]; :local HostInfo [ $ParseKeyValueStore ($HostVal->"comment") ]; @@ -61,7 +61,7 @@ $ScriptLock $0; :local DohCert ""; :local DohCurrent [ /ip/dns/get use-doh-server ]; -:foreach Host in=[ /tool/netwatch/find where comment~"doh" status="up" ] do={ +:foreach Host in=[ /tool/netwatch/find where comment~"\\bdoh\\b" status="up" ] do={ :local HostVal [ /tool/netwatch/get $Host ]; :local HostInfo [ $ParseKeyValueStore ($HostVal->"comment") ]; -- cgit v1.2.3-54-g00ecf