Compare commits

..

94 commits

Author SHA1 Message Date
Christian Hesse
29ecc69245 global-functions: $NetMask6: use shift operator...
... and drop the workaround. This requires RouterOS 7.22beta3.
2026-01-21 16:27:58 +01:00
Christian Hesse
9ef923d76c Merge branch 'continue-in-loop' into next 2026-01-21 16:27:58 +01:00
Christian Hesse
78a6d96169 Merge branch 'early-exit-with-exit' into next 2026-01-21 16:27:58 +01:00
Christian Hesse
cd0f6541d6 check-certificates: use :continue in loop 2026-01-21 16:27:58 +01:00
Christian Hesse
dfabc8ff89 global-functions: deprecate $ExitError 2026-01-21 16:27:58 +01:00
Christian Hesse
c64304f449 global-functions: $ScriptInstallUpdate: fix indention 2026-01-21 16:27:58 +01:00
Christian Hesse
443068e930 update-tunnelbroker: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
5e8054b805 global-functions: $ScriptInstallUpdate: use :continue in loop 2026-01-21 16:27:58 +01:00
Christian Hesse
e0488ef054 update-gre-address: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
67a3799e21 fw-addr-lists: fix indention 2026-01-21 16:27:58 +01:00
Christian Hesse
87bf6fcdbe telegram-chat: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
3be28b96c9 fw-addr-lists: use :continue in loop 2026-01-21 16:27:58 +01:00
Christian Hesse
abaf7766c8 sms-forward: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
b40ca5c1e3 telegram-chat: use :continue in loop 2026-01-21 16:27:58 +01:00
Christian Hesse
fc677ae250 sms-action: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
10b9b9f671 ppp-on-up: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
4e5ec3ee6f packages-update: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
7b75884207 ospf-to-leds: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
31f1b511a3 netwatch-notify: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
0d5ef339a1 netwatch-dns: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
301317250d log-forward: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
748fd0da00 lease-script: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
14b6426e1a ipv6-update: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
6d76f12439 ipsec-to-dns: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
33cc5690db hotspot-to-wpa-cleanup: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
3cb4d75df5 hotspot-to-wpa: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
a33081ea5e gps-track: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
67700b0739 fw-addr-lists: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
a4094ceb98 firmware-upgrade-reboot: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
855113e059 dhcp-to-dns: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
d11bf24b4b dhcp-lease-comment: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
25a75ef247 daily-psk: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
3d9d20e649 collect-wireless-mac: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
d951867a47 check-routeros-update: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
17e5e6ab57 check-perpetual-license: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
ea10cbe9c5 check-lte-firmware-upgrade: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
0b5225d5af check-health: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
71740bee13 check-certificates: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
8a6dbde4fe certificate-renew-issued: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
1a78e554d4 capsman-rolling-upgrade: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
786f9c42a3 capsman-download-packages: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
51e7bb04ab backup-upload: early exit with :exit 2026-01-21 16:27:58 +01:00
Christian Hesse
4a426b9ba3 Merge branch 'compare-ids' into next 2026-01-21 16:27:57 +01:00
Christian Hesse
36b9dd976b backup-partition: early exit with :exit 2026-01-21 16:27:57 +01:00
Christian Hesse
46723073e8 Merge branch 'drop-builtin-trust-anchors' into next 2026-01-21 16:27:57 +01:00
Christian Hesse
d2dc261832 global-functions: deprecate $HexToNum 2026-01-21 16:27:57 +01:00
Christian Hesse
a9ce9b723e backup-email: early exit with :exit 2026-01-21 16:27:57 +01:00
Christian Hesse
c73d3f8497 INITIAL-COMMANDS: drop the old builtin-trust-anchors 2026-01-21 16:27:57 +01:00
Christian Hesse
53e87dbda2 log-forward: fix indention 2026-01-21 16:27:57 +01:00
Christian Hesse
484a0da2eb backup-cloud: early exit with :exit 2026-01-21 16:27:57 +01:00
Christian Hesse
c370eb475e global-functions: $CertificateAvailable: drop the old builtin-trust-anchors 2026-01-21 16:27:57 +01:00
Christian Hesse
5f71b2b6e5 log-forward: use comparison for ids
This was introduced with RouterOS 7.22beta1.

Initializing $LogForwardLast with boolean value looks odd, but this is
reuqired to match the very first message.
2026-01-21 16:27:57 +01:00
Christian Hesse
c5946d879c README: drop the old builtin-trust-anchors 2026-01-21 16:27:57 +01:00
Christian Hesse
8bec747150 mod/notification-email: use errors from command...
... instead of reading status from properties. This was introduced in
RouterOS 7.21beta2 (and we bump to 7.21 instead).
2026-01-21 16:03:33 +01:00
Christian Hesse
369e887a22 mod/ssh-keys-import: drop old property
The property name changed in RouterOS 7.21beta2, so bump required
version to 7.21.
2026-01-21 16:03:33 +01:00
Christian Hesse
ee2aba684d Merge branch 'certificate-builtin' into next 2026-01-21 16:03:33 +01:00
Christian Hesse
228ac39486 Merge branch 'CommitBrief' into next 2026-01-21 16:03:33 +01:00
Christian Hesse
390e272bbb bump required RouterOS version for all scripts 2026-01-21 16:03:33 +01:00
Christian Hesse
772f745480 Merge branch 'ExitOnError' into next 2026-01-21 16:03:33 +01:00
Christian Hesse
334ff7162a README: update screenshots 2026-01-21 16:03:33 +01:00
Christian Hesse
bb778e1e3b README: add a screenshot for builtin trust store 2026-01-21 16:03:33 +01:00
Christian Hesse
20c904eea2 mode-button: use $ExitOnError 2026-01-21 16:03:33 +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
859fb77f6d README: make the trust store a separate section 2026-01-21 16:03:33 +01:00
Christian Hesse
7e4463473d mod/ssh-keys-import: use $ExitOnError 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
c9ea23bc67 README: reword the hint on builtin trust store 2026-01-21 16:03:33 +01:00
Christian Hesse
496bca336c mod/scriptrunonce: use $ExitOnError 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
66dc4dba6c global-functions: $CertificateAvailable: drop the compatibility workaround...
... and make it depend in RouterOS 7.19 and its builtin certificates.
2026-01-21 16:03:33 +01:00
Christian Hesse
dd4421099f mod/notification-telegram: use $ExitOnError 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
ca90e24ac1 INITIAL-COMMANDS: drop the compatibility workaround...
... and make it depend in RouterOS 7.19 and its builtin certificates.
2026-01-21 16:03:33 +01:00
Christian Hesse
fe987304ea mod/notification-ntfy: use $ExitOnError 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
5f3ced3c5e check-certificates: drop the compatibility workaround...
... and make it depend in RouterOS 7.19 and its builtin certificates.
2026-01-21 16:03:33 +01:00
Christian Hesse
e21495054b mod/notification-matrix: use $ExitOnError 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
a7217fa0cd mod/notification-gotify: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
b48523cc3d mod/notification-email: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
0393a783c9 mod/ipcalc: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
57d820f454 mod/inspectvar: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
f570b901a8 mod/bridge-port-vlan: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
fe09981801 mod/bridge-port-to: use $ExitOnError 2026-01-21 16:03:33 +01:00
Christian Hesse
2030769216 accesslist-duplicates: use $ExitOnError 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
f0b1ca8030 README: reword the section on device-mode
Now that we require RouterOS 7.17 *all* devices come with the
updated device-mode.
2026-01-21 16:00:46 +01:00
4 changed files with 24 additions and 13 deletions

View file

@ -4,7 +4,7 @@ Initial commands
[![GitHub stars](https://img.shields.io/github/stars/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=red)](https://github.com/eworm-de/routeros-scripts/stargazers)
[![GitHub forks](https://img.shields.io/github/forks/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=green)](https://github.com/eworm-de/routeros-scripts/network)
[![GitHub watchers](https://img.shields.io/github/watchers/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=blue)](https://github.com/eworm-de/routeros-scripts/watchers)
[![required RouterOS version](https://img.shields.io/badge/RouterOS-7.19-yellow?style=flat)](https://mikrotik.com/download/changelogs/)
[![required RouterOS version](https://img.shields.io/badge/RouterOS-7.21-yellow?style=flat)](https://mikrotik.com/download/changelogs/)
[![Telegram group @routeros_scripts](https://img.shields.io/badge/Telegram-%40routeros__scripts-%2326A5E4?logo=telegram&style=flat)](https://t.me/routeros_scripts)
[![donate with PayPal](https://img.shields.io/badge/Like_it%3F-Donate!-orange?logo=githubsponsors&logoColor=orange&style=flat)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=A4ZXBD6YS2W8J)

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

View file

@ -4,7 +4,7 @@ RouterOS Scripts
[![GitHub stars](https://img.shields.io/github/stars/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=red)](https://github.com/eworm-de/routeros-scripts/stargazers)
[![GitHub forks](https://img.shields.io/github/forks/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=green)](https://github.com/eworm-de/routeros-scripts/network)
[![GitHub watchers](https://img.shields.io/github/watchers/eworm-de/routeros-scripts?logo=GitHub&style=flat&color=blue)](https://github.com/eworm-de/routeros-scripts/watchers)
[![required RouterOS version](https://img.shields.io/badge/RouterOS-7.19-yellow?style=flat)](https://mikrotik.com/download/changelogs/)
[![required RouterOS version](https://img.shields.io/badge/RouterOS-7.21-yellow?style=flat)](https://mikrotik.com/download/changelogs/)
[![Telegram group @routeros_scripts](https://img.shields.io/badge/Telegram-%40routeros__scripts-%2326A5E4?logo=telegram&style=flat)](https://t.me/routeros_scripts)
[![donate with PayPal](https://img.shields.io/badge/Like_it%3F-Donate!-orange?logo=githubsponsors&logoColor=orange&style=flat)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=A4ZXBD6YS2W8J)
@ -50,7 +50,7 @@ temporarily.
> 💡️ **Hint**: If in doubt have a look at the badge at the top of each
> page showing the minimum version required:
> ![required RouterOS version](https://img.shields.io/badge/RouterOS-7.19-yellow?style=flat)
> ![required RouterOS version](https://img.shields.io/badge/RouterOS-7.21-yellow?style=flat)
> **Info**: The `main` branch is now RouterOS v7 only. If you are still
> running RouterOS v6 switch to `routeros-v6` branch!
@ -59,7 +59,7 @@ temporarily.
The
[device-mode ↗️](https://help.mikrotik.com/docs/spaces/ROS/pages/93749258/Device-mode)
is a mechanism to to lock down a device for security reasons, it gives
is a mechanism to lock down a device for security reasons, it gives
fine-grained control over what features are available. You need to enable
`scheduler` and `fetch` at least, specific scripts may require additional
features.
@ -97,15 +97,26 @@ including demonstration recorded live at [MUM Europe
### The long way in detail
The update script does server certificate verification, so first step is to
download the certificates.
The update script does server certificate verification, so first step is
to establish trust.
> 💡️ **Hint**: RouterOS comes with a builtin certificate store. You
> can skip the steps regarding certificate download and import and jump
> to [installation of scripts](#installation-of-scripts) if you set the
> certificates to be trusted my the `fetch` command at least. But make
> sure not to drop other targets:
> `/certificate/settings/set builtin-trust-store=fetch;`
#### Builtin trust store
RouterOS comes with a builtin trust store with several CA certificates.
If you intend **not** to trust this store jump to
[download and import certificate](#download-and-import-certificate) now.
Select the `fetch` command to trust these builtin certificates at
least, but make sure not to drop other targets:
/certificate/settings/set builtin-trust-store=fetch;
![screenshot: builtin trust store](README.d/00-builtin-trust-store.avif)
You can skip the steps regarding certificate download and import and jump
to [installation of scripts](#installation-of-scripts) now.
#### Download and import certificate
If you intend to download the scripts from a
different location (for example from github.com) install the corresponding

View file

@ -4,7 +4,7 @@
# Michael Gisbers <michael@gisbers.de>
# https://rsc.eworm.de/COPYING.md
#
# requires RouterOS, version=7.19
# requires RouterOS, version=7.21
# requires device-mode, fetch, scheduler
#
# global functions