blob: 3eca0462962b088334979c2ecf9ad60bfb41cb9f (
about) (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#
# RouterOS script: accesslist-duplicates.local
# Copyright (c) 2018 Christian Hesse <mail@eworm.de>
#
# print duplicate antries in wireless access list
#
# !! Do not edit this file, it is generated from template!
:local seen [ :toarray "" ];
:local shown [ :toarray "" ];
:foreach acclist in=[ / interface wireless access-list find where mac-address!="00:00:00:00:00:00" ] do={
:local mac [ / interface wireless access-list get $acclist mac-address ];
:foreach "seen-mac" in=$seen do={
:if ($"seen-mac" = $mac) do={
:local skip 0;
:foreach "shown-mac" in=$shown do={
:if ($"shown-mac" = $mac) do={ :set skip 1; }
}
:if ($skip = 0) do={
/ interface wireless access-list print where mac-address=$mac;
:set $shown ( $shown , $mac );
}
}
}
:set $seen ( $seen , $mac );
}
|