Commit graph

16 commits

Author SHA1 Message Date
Christian Hesse
8fcb8efbea netwatch-dns: drop main function, use :do with on-error 2024-03-12 15:27:15 +01:00
Christian Hesse
1e8918fdaa global-functions: $ScriptLock: do not exit from global function 2024-03-12 15:27:15 +01:00
Christian Hesse
5af8b95444 netwatch-dns: do not exit with error 2024-03-12 15:27:15 +01:00
Christian Hesse
458fd1fdcd netwatch-dns: move code into function 2024-03-04 21:40:34 +01:00
Christian Hesse
80f587ddb5 netwatch-dns: use :jobname to get script name 2024-01-30 00:52:21 +01:00
Christian Hesse
0ad1a79d67 netwatch-dns: be move verbose on time to settle 2024-01-18 21:07:52 +01:00
Christian Hesse
5fd8c8a760 netwatch-dns: check DoH server with fetch
This way we do not have to configure possibly non-functional servers to
check. The query is for doh-check.eworm.de of type TXT, the expected
answer is 'doh-check-OK'.

% dig TXT doh-check.eworm.de +https @1.1.1.1

; <<>> DiG 9.18.21 <<>> TXT doh-check.eworm.de +https @1.1.1.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 42226
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;doh-check.eworm.de.		IN	TXT

;; ANSWER SECTION:
doh-check.eworm.de.	63791	IN	TXT	"doh-check-OK"

;; Query time: 16 msec
;; SERVER: 1.1.1.1#443(1.1.1.1) (HTTPS)
;; WHEN: Mon Jan 15 13:55:36 CET 2024
;; MSG SIZE  rcvd: 72
2024-01-15 14:07:38 +01:00
Christian Hesse
85aeeadcee netwatch-dns: check DoH server functionality...
... and try all servers one after another.
2024-01-11 15:33:03 +01:00
Christian Hesse
80db12a3e9 netwatch-dns: enable DoH certificate verification...
... if a certificate is named in configuration.
2024-01-11 09:22:32 +01:00
Christian Hesse
9a73fc526f update copyright for 2024 2024-01-01 15:25:25 +01:00
Christian Hesse
81a86ee043 netwatch-dns: get doh host name from static dns 2023-11-27 18:21:47 +01:00
Christian Hesse
f60c72dc78 netwatch-dns: match on word boundary 2023-10-27 22:55:15 +02:00
Christian Hesse
313e026229 netwatch-dns: increase startup delay
In RouterOS 7.9 netwatch itself comes with a (default) startup-delay of five
minutes. Increase our delay to make sure netwatch is active.
2023-06-28 11:29:02 +02:00
Christian Hesse
42c658e1d4 netwatch-dns: reorder variables 2023-06-01 09:53:33 +02:00
Christian Hesse
007d1ff7b8 netwatch-dns: handle status 'up' only 2023-06-01 09:53:33 +02:00
Christian Hesse
a832fd04ef rename scripts and add file extension ".rsc"
No functional change for the user... The migration is done
automatically.
2023-03-07 22:26:01 +01:00