Commit graph

3166 commits

Author SHA1 Message Date
Christian Hesse
59dc7e6d0c Merge branch 'check-health' into next 2025-08-26 09:25:01 +02:00
Christian Hesse
22e6383e86 check-health.d/voltage: use script name for origin in notification 2025-08-25 11:11:07 +02:00
Christian Hesse
62ca30b5d3 check-health.d/temperature: use script name for origin in notification 2025-08-25 11:11:07 +02:00
Christian Hesse
907358cb85 check-health.d/state: use script name for origin in notification 2025-08-25 11:11:07 +02:00
Christian Hesse
2fed8f967b check-health: pass script name to plugin 2025-08-25 11:11:07 +02:00
Christian Hesse
386ea2419f check-health: fix variable name 2025-08-25 11:04:07 +02:00
Christian Hesse
fe080c0d3d global-functions: $CertificateAvailable: properly handle duplicate CN
There are CA certificates with identical CommonName out there... 🤪
Let's handle these.

    [admin@MikroTik] > /certificate/print proplist=common-name,skid where common-name="GlobalSign";
    Flags: T - TRUSTED
    Columns: COMMON-NAME, SKID
    #   COMMON-NAME  SKID
    0 T GlobalSign   8FF04B7FA82E4524AE4D50FA639A8BDEE2DD1BBC
    1 T GlobalSign   3DE629489BEA07CA21444A26DE6EDED283D09F59
    2 T GlobalSign   AE6C05A39313E2A2E7E2D71CD6C7F07FC86753A0
    3 T GlobalSign   54B07BAD45B8E2407FFB0A6EFBBE33C93CA384D5
2025-08-16 23:14:31 +02:00
Christian Hesse
a856d309df global-functions: $SymbolByUnicodeName: allow to add more symbols...
... for example from a module. Add a script `mod/symbols-extra` with
something like:

    :global SymbolsExtra;

    :set ($SymbolsExtra->"rocket") "\F0\9F\9A\80";
2025-07-28 16:47:27 +02:00
Christian Hesse
721e786f68 netwatch-notify: increase the address-list timeout even further 2025-07-21 10:52:22 +02:00
Christian Hesse
4c2c7e817a netwatch-notify: give the number of failures...
... to indicated this happened several times.
2025-07-21 10:47:19 +02:00
Christian Hesse
89175e511f accesslist-duplicates: print without paging 2025-07-07 18:38:21 +02:00
Christian Hesse
b068f86995 netwatch-dns: fix indention 2025-06-25 10:47:12 +02:00
Christian Hesse
d46574b4fe netwatch-dns: retry doh server...
... for more resilience on bad connectivity or saturated link.
2025-06-25 10:30:26 +02:00
Christian Hesse
c3010af4ed Merge branch 'file' into next 2025-06-23 08:52:58 +02:00
Christian Hesse
1307b8587e global-functions: $FileGet: mitigate race with file properties
RouterOS is suffering a race condition, where a file exists, but its
properties are not (yet) available. This is handled in $WaitForFile.

This passes an interval of zero to $WaitForFile, as does not wait for
the file to exist, but wants to avoid the race only.
2025-06-23 08:52:58 +02:00
Christian Hesse
6415849850 global-functions: $WaitForFile: (mostly) revert changes
This (mostly) reverts commits 0e00a228d6
and e08bb2192d.

This is required for RouterOS 7.20beta4. That fixed recursive find for
files, and (again, or still?) suffers timing (and thus racing) issues
getting file properties.

This breaks RouterOS 7.20beta2 again, so that specific version is not
supported. Just update...
2025-06-23 08:52:51 +02:00
Christian Hesse
95f8af6234 packages-update: convert to time before comparing...
... to avoid:

    packages-update: Script 'packages-update' exited with error: Script Error: cannot compare if truth value is more than or equal to ip address
2025-06-20 23:52:07 +02:00
Christian Hesse
de2a90d841 doc/fw-addr-lists: add a warning on possible subsystem crash 2025-06-11 17:47:40 +02:00
Christian Hesse
e2d3f0f073 fw-addr-lists: delay on possible scripting subsystem crash
This happens in :convert when a list is way too large.

Let's use $LogPrintOnce here. If the scripting subsystem really crashes
the message will be purged from $LogPrintOnceMessages anyway (as all
global variables are lost).
2025-06-11 17:46:09 +02:00
Christian Hesse
595b4aea9d capsman-download-packages: revert changes for "new functionality"
(Though we keep the quoting for type.)

Well, turned out this functionality is for `/file/print` only,
but does not work with `/file/find`. 🫣🥴

This reverts commit 15fd522d3d.
2025-06-11 17:46:09 +02:00
Christian Hesse
0de6d006ae update list of contributors 2025-06-04 22:30:51 +02:00
Christian Hesse
1f4bf9ee63 check-routeros-update: remove a stale scheduler 2025-06-04 22:30:51 +02:00
Christian Hesse
c3d3d61f92 packages-update: support deferred reboot with longer interval 2025-06-04 22:30:51 +02:00
Christian Hesse
6130c94cc1 Merge branch 'file' into next 2025-06-04 22:30:51 +02:00
Christian Hesse
15fd522d3d capsman-download-packages: adopt new functionality from file menu 2025-06-04 22:30:51 +02:00
Christian Hesse
5b15c82bb1 capsman-download-packages: use $FileGet ...
... to work around restrictions in new file handling.
2025-06-04 22:30:48 +02:00
Christian Hesse
30b80e903d telegram-chat: use $FileExists ...
... to work around restrictions in new file handling.
2025-06-04 22:30:45 +02:00
Christian Hesse
80aed200fd mod/ssh-keys-import: use $FileExists ...
... to work around restrictions in new file handling.
2025-06-04 22:30:42 +02:00
Christian Hesse
2d81984aed mod/notification-email: use $RmFile 2025-06-04 22:30:42 +02:00
Christian Hesse
e3284ca770 mod/notification-email: use $FileExists ...
... to work around restrictions in new file handling.
2025-06-04 22:30:39 +02:00
Christian Hesse
daee05dbd7 backup-email: add a comment why files are not removed 2025-06-04 22:30:39 +02:00
Christian Hesse
43bac7c33c backup-email: check for .conf file 2025-06-04 22:30:39 +02:00
Christian Hesse
a2f837be59 backup-email: use :retry and $FileExists ...
... to work around restrictions in new file handling.
2025-06-04 22:30:36 +02:00
Christian Hesse
8353a8547f global-functions: $DownloadPackage: use $FileExists ...
... to work around restrictions in new file handling.
2025-06-04 22:30:33 +02:00
Christian Hesse
cb984a5e52 global-functions: introduce $FileExists 2025-06-04 22:28:25 +02:00
Christian Hesse
0e00a228d6 global-functions: $WaitForFile: use :retry for simplification, ...
... and to work around restrictions in new file handling.
2025-06-04 22:28:20 +02:00
Christian Hesse
e08bb2192d global-functions: $WaitForFile: drop the workaround
This was fixed in RouterOS 7.18rc1, so should be ok to remove now.
2025-06-04 22:28:20 +02:00
Christian Hesse
fb8e616846 global-functions: $RmFile: use $FileGet ...
... to work around restrictions in new file handling.
2025-06-04 22:28:17 +02:00
Christian Hesse
d993495e44 global-functions: $RmDir: use $FileGet ...
... to work around restrictions in new file handling.
2025-06-04 22:28:14 +02:00
Christian Hesse
1e4f168735 global-functions: $MkDir: use $FileGet ...
... to work around restrictions in new file handling.
2025-06-04 22:28:11 +02:00
Christian Hesse
b70e6e7984 global-functions: introduce $FileGet 2025-06-03 12:29:42 +02:00
Christian Hesse
4bc3bf40e6 Merge branch 'builtin-certs' into next 2025-06-03 11:06:59 +02:00
Christian Hesse
d69b399572 INITIAL-COMMANDS: use builtin certificates if possible 2025-06-03 11:06:59 +02:00
Christian Hesse
bf684a7197 global-functions: $CertificateAvailable: try to use builtin certificates
The builtin certificates were introduced with RouterOS 7.19, so requires
this hacky :parse workaround.
2025-05-28 15:08:26 +02:00
Christian Hesse
d59c4aee26 README: add a paragraph and link to jump 2025-05-28 14:16:57 +02:00
Christian Hesse
3d3b270748 README: give a hint on builtin certificate store
I guess this should become the default any time in future...
2025-05-28 14:07:57 +02:00
Christian Hesse
6a49c483b6 telegram-chat: rename variable...
... to better describe the use.
2025-05-23 17:38:22 +02:00
Christian Hesse
c50acd697a telegram-chat: fix detection of replies 2025-05-23 17:36:56 +02:00
Christian Hesse
4bd7d44cd2 global-functions: $ScriptInstallUpdate: fix syntax error 2025-05-23 11:16:40 +02:00
Christian Hesse
86ad41f6b6 fix the trust state for certificates
RouterOS 7.19 is suffering an issue with certificate store, where the
trust state is not available correctly. This effects certificates
imported a long time ago, with RouterOS 7.4 or older.

Fixing trust state for all certificates by re-setting the trust state...

(Reported as SUP-188791...)
2025-05-23 10:51:04 +02:00