I have Mikrotik Router OS with Hotspot. I have email setup and working to send backup.
I have some firewall filter rules that add IP address to an address list.
For example, I have port scanning. Any user do illegal port scanning will be added to "port scanning list in firewall address list.
I want a script that can specify the username (or the comment which has the real name) in hotspot that correspond to this IP and send his username, IP, Mac address from the active users or Hosts and the comment from the Hotspot user data.
if the user int Hotspot hosts but not loging, then get the info from Hosts ( Mac address , IP)
if no in host either, then look for information from DHCP (info as IP , Mac address and active host name