aboutsummaryrefslogtreecommitdiffstats
path: root/collect-wireless-mac.local
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2018-07-10 14:01:41 +0200
committerGravatar Christian Hesse <mail@eworm.de>2018-07-10 14:01:41 +0200
commitc66bb89be2b6e76a0926b19f9726c91067e5bbf3 (patch)
tree3f5d48114541e98ea4ab8e4795b76df2242e9de6 /collect-wireless-mac.local
parenta964e8ad0cb285e5b3c13da37ffe567175263acc (diff)
update template system
Diffstat (limited to 'collect-wireless-mac.local')
-rw-r--r--collect-wireless-mac.local10
1 files changed, 2 insertions, 8 deletions
diff --git a/collect-wireless-mac.local b/collect-wireless-mac.local
index 4418c94..5bd544c 100644
--- a/collect-wireless-mac.local
+++ b/collect-wireless-mac.local
@@ -1,4 +1,4 @@
-# RouterOS script: collect-wireless-mac
+# RouterOS script: collect-wireless-mac.local
# Copyright (c) 2013-2018 Christian Hesse <mail@eworm.de>
#
# collect wireless mac adresses in access list
@@ -33,13 +33,7 @@
}
:local regentry [ / interface wireless registration-table find where mac-address=$mac ];
:local interface [ / interface wireless registration-table get $regentry interface ];
- :local ssid;
- :if ("interface wireless" = ("caps" . "-man")) do={
- :set ssid [ / interface wireless registration-table get $regentry ssid ];
- } else={
- # keep two spaces here to protect against replace!
- :set ssid [ / interface wireless get [ find where name=$interface ] ssid ];
- }
+ :local ssid [ / interface wireless get [ find where name=$interface ] ssid ];
:local datetime ([ / system clock get date ] . " " . [ / system clock get time ]);
:local message ("unknown MAC address " . $mac . " (" . $hostname . ") first seen on " . \
$datetime . " connected to SSID " . $ssid . ", interface " . $interface);