Commit graph

308 commits

Author SHA1 Message Date
Christian Hesse
0aa7645158 global-functions: $NetMask6: use shift operator...
... and drop the workaround. This requires RouterOS 7.22beta3.
2026-02-24 15:18:22 +01:00
Christian Hesse
c527536981 global-functions: $ScriptInstallUpdate: fix indention 2026-02-24 15:18:22 +01:00
Christian Hesse
05cbdc562c global-functions: $ScriptInstallUpdate: use :continue in loop 2026-02-24 15:18:22 +01:00
Christian Hesse
90ef132a9d global-functions: deprecate $ExitError 2026-02-24 15:18:22 +01:00
Christian Hesse
048760d0eb global-functions: deprecate $HexToNum 2026-02-24 15:18:22 +01:00
Christian Hesse
505a488297 global-functions: $CertificateAvailable: drop the old builtin-trust-anchors 2026-02-24 15:18:22 +01:00
Christian Hesse
8b88682d3d check-certificates: decrease the defaults for renewal and warning
https://letsencrypt.org/2025/12/02/from-90-to-45.html
2026-02-24 15:18:20 +01:00
Christian Hesse
349ebd5ad6 global-functions: $Grep: use length from variable 2026-02-23 08:57:02 +01:00
Christian Hesse
eecc8c6126 global-functions: $Grep: add comment on :deserialize 2026-02-23 08:57:02 +01:00
Christian Hesse
e359b3a176 global-functions: $CertificateAvailable: drop the compatibility workaround...
... and make it depend in RouterOS 7.19 and its builtin certificates.
2026-01-27 15:47:19 +01:00
Christian Hesse
2a5ece122f global-functions: $ScriptInstallUpdate: drop output on commit...
... now that we have it on loading global functions.
2026-01-21 16:03:33 +01:00
Christian Hesse
bde26dc1a5 global-functions: give commit info when laoding 2026-01-21 16:03:33 +01:00
Christian Hesse
44990958ea global-functions: $ScriptInstallUpdate: use $CommitBrief 2026-01-21 16:03:33 +01:00
Christian Hesse
582b0f411e global-functions: $FetchUserAgentStr: user $CommitBrief 2026-01-21 16:03:33 +01:00
Christian Hesse
06fd89c55c global-functions: $DeviceInfo: use $CommitBrief 2026-01-21 16:03:33 +01:00
Christian Hesse
8492e3d7a1 global-functions: introduce $CommitBrief 2026-01-21 16:03:33 +01:00
Christian Hesse
ce2ae4fdf7 global-functions: $SendNotification: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
14b8768b41 global-functions: $ScriptInstallUpdate: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
f642b2f40d global-functions: make $ExitError a wrapper for $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
0f9476df28 global-functions: introduce $ExitOnError
This is just like $ExitError, but first parameter is dropped. Soon
we will not need that, now that we can exit a script with :exit.
2026-01-21 16:03:07 +01:00
Christian Hesse
e27aca0664 global-functions: enable scheduler if disabled 2026-01-21 16:00:46 +01:00
Christian Hesse
426da3e99c global-functions: simplify the scheduler fix 2026-01-21 16:00:46 +01:00
Christian Hesse
160a885e02 global-functions: make the scheduler fix a block 2026-01-21 16:00:46 +01:00
Christian Hesse
2d53e81292 global-functions: $NetMask6: drop unused variable 2026-01-21 16:00:46 +01:00
Christian Hesse
28b1297a43 global-functions: $ScriptInstallUpdate: trigger reload on changed snippet 2026-01-20 09:51:05 +01:00
Christian Hesse
9919b9fe76 global-functions: $ScriptInstallUpdate: get new Let's Encrypt CA 'Root YE' 2026-01-17 16:58:16 +01:00
Christian Hesse
d673f0956c global-functions: $CertificateAvailable: get missing certificate...
... not the issued and available one.
2026-01-16 00:32:49 +01:00
Christian Hesse
45bcb80125 global-functions: bump required version to 7.17...
... as we use `:convert from=num ...` which was introduced back then.

Actually the requirment did exist since commit
6ad6f9aa08.
2026-01-12 10:00:30 +01:00
Christian Hesse
0ceedab5db global-functions: $CharacterMultiply: return early on length zero...
... as :for loop counts backwards and would return two
character otherwise.
2026-01-06 14:10:08 +01:00
Christian Hesse
6990084d98 global-functions: $CharacterMultiply: use local variables for parameters 2026-01-06 14:10:08 +01:00
Christian Hesse
8878449b0b global-functions: support modules (or snippets) in global-functions.d/ 2026-01-05 11:37:58 +01:00
Christian Hesse
623f96d94a update copyright for 2026 2026-01-01 13:50:07 +01:00
Christian Hesse
0745f09a8a global-functions: $FetchHuge: handle missing file
This should not happen, as download was supposed to be
successful - it does. 🤪
2025-12-25 23:56:00 +01:00
Christian Hesse
830693df79 global-functions: $SymbolByUnicodeName: extend special 2025-12-03 17:53:31 +01:00
Christian Hesse
7caaa62321 check-perpetual-license: add scroll symbol in notification
doc/check-perpetual-license.d/notification-01-warn.avif
----- >8 -----
[rsc] 📜⚠️ License about to expire!

Your license failed to renew and is about to expire on 2025-09-13 12:12:23 on rsc...
----- >8 -----

doc/check-perpetual-license.d/notification-02-renew.avif
----- >8 -----
[rsc] 📜️ License renewed

Your license was successfully renewed on rsc. It is now valid until 2025-10-25 08:42:46.
----- >8 -----
2025-11-27 11:26:04 +01:00
Christian Hesse
1f11f72d18 global-functions: $SymbolByUnicodeName: add special with magic 2025-11-27 08:49:56 +01:00
Christian Hesse
b285f2c5d2 global-functions: add and fix global scheduler automatically...
... and also adjust README and INITIAL-COMMANDS.
2025-11-20 11:26:59 +01:00
Christian Hesse
93eb218589 global-functions: $FetchUserAgentStr: add commit info in user agent string 2025-11-20 11:26:59 +01:00
Christian Hesse
b5a0269667 global-functions: $ScriptInstallUpdate: define certificate use 2025-11-19 16:19:59 +01:00
Christian Hesse
f3e6e152bc global-functions: $GetMacVendor: define certificate use 2025-11-19 16:19:59 +01:00
Christian Hesse
8eb397f79f global-functions: $DownloadPackage: define certificate use 2025-11-19 16:19:59 +01:00
Christian Hesse
db0a5bf33c global-functions: $CertificateAvailable: support new builtin-trust-store...
... which was introduced with RouterOS 7.21beta7.
2025-11-19 16:19:59 +01:00
Christian Hesse
d002d1c0c0 global-functions: $ScriptInstallUpdate: extra actions on 'not found' only 2025-11-19 16:19:59 +01:00
Christian Hesse
298a43a871 global-functions: $ScriptInstallUpdate: either or...
... but not both.
2025-11-19 16:19:59 +01:00
Christian Hesse
20885c4620 global-functions: $ScriptInstallUpdate: give hint on ignore
Fixes: https://github.com/eworm-de/routeros-scripts/issues/112
2025-11-19 16:19:59 +01:00
Christian Hesse
83b164d511 global-functions: $CertificateDownload: drop unused function 2025-11-19 16:19:59 +01:00
Christian Hesse
d7a6eb1d00 global-functions: $NetMask6: implement simple caching
The calculation is quite complex for something that needs to be done
frequently, for example by `fw-addr-lists`. The number of possible
netmasks is limited, so let's cache the results that were calculated
already.
2025-10-19 19:52:42 +02:00
Christian Hesse
6ad6f9aa08 global-functions: introduce $NetMask6
RouterOS does not support bit shifting on IPv6 data types, so we have to
split the problem:

 * each 16 bit block is calculated separately, as number
 * the complete netmask is assembled in a loop, as string
 * the final string is casted to correct data type
2025-10-19 19:48:14 +02:00
Christian Hesse
def540c965 global-functions: introduce $NetMask4 2025-10-16 10:47:19 +02:00
Christian Hesse
025b492783 global-functions: remove trailing space 2025-10-16 10:34:09 +02:00