mirror of
https://github.com/eworm-de/routeros-scripts
synced 2024-05-14 08:04:19 +00:00
netwatch-notify: restore the check 🥴
This reverts commit 28da1da49e
.
Chances are that we have to resolve a CNAME, that does not match when
querying the cache.
How to handle CNAME do multiple A records? 🤨
This commit is contained in:
parent
45875ad68e
commit
c2f5272f18
1 changed files with 2 additions and 1 deletions
|
@ -79,7 +79,8 @@ $ScriptLock $0;
|
|||
:if ([ $IsDNSResolving ] = true) do={
|
||||
:do {
|
||||
:local Resolve [ :resolve ($HostInfo->"resolve") ];
|
||||
:if ([ :len [ /ip/dns/cache/find where name=($HostInfo->"resolve") data=[ :tostr ($HostVal->"host") ] ] ] = 0) do={
|
||||
:if ($Resolve != $HostVal->"host" && \
|
||||
[ :len [ /ip/dns/cache/find where name=($HostInfo->"resolve") data=[ :tostr ($HostVal->"host") ] ] ] = 0) do={
|
||||
$LogPrintExit2 info $0 ("Name '" . $HostInfo->"resolve" . [ $IfThenElse \
|
||||
($HostInfo->"resolve" != $HostInfo->"name") ("' for " . $Type . " '" . \
|
||||
$HostInfo->"name") "" ] . "' resolves to different address " . $Resolve . \
|
||||
|
|
Loading…
Reference in a new issue