I can predict the unauthorized distribution of dynamic IP address via DHCP?
Resumindo- If a malicious user put a virtual machine with a DHCP server, he can send addresses valid for the entire network, it is possible to guard against that?
This is the script i am using in my routers. This is from another user posted in the past…
:local CurrentTime [/system clock get time]
:local hostname [/system identity get name]
:global date [/system clock get date]
:local int “$interface”
:local addr “$address”
:local mac $“mac-address”
:local dh
/tool e-mail send to=“mymail@gmail.com” subject=“ROGUE DHCP Server have been detected on $hostname at $date - time $CurrentTime - Interface= $int - IP Address=$addr - MAC-Address= $mac”
/ tool e-mail send to = “my-e-mail” subject = (“DHCP server on the network from unauthorized.” [/ system identity get name]) $ $ address $ interface server “mac-address” "
If I want to use your tip, just copy this script and put the correct email, only this?
Perfect my friend, I’ve done this procedure
Unfortunately there is no way the own mikrotik to prevent false DHCP servers (unauthorized). I think these functions are all layer two (switch). So far only found detective tips and not preventive (proactive)
They will stop DHCP traffic if it passes through the MikroTik router. However, DHCP packets are distributed in the whole LAN, independent from the router.
As already mentioned, a manageable/smart switch is really the only way to filter out such packets, by making all devices forward packets only in the direction of your router and back (which would also effectively forbid your clients from communicating with each other at all, without the router’s permission).
The alternative is simply not using DHCP, but using either IPs or PPPoE. Leave DHCP to provide settings that only lead to a single web page, which explains how to setup the connection “manually”.
Well, taking advantage of the topic, you know a way (with script usage) to detect the same mac-address (clone) in HOTSPOT network? I’ve been looking for this for a long time!
will do what you want but a) documentation for it is thin on the ground and b) it requires an external server to run it on [although I guess you could run it on an OpenWRT metarouter]
arpwatch alerts you when a MAC address changes IP address, or when an IP address changes MAC address. If a “bad guy” assumes somebody else’s MAC and IP addresses, you aren’t going to be able to know who the “real” one is. Perhaps you could set hotspot interface ARP mode to reply-only, populate ARP from DHCP and disable client-to-client forwarding. That will make it harder for a “bad guy” to get enough information about innocent users in order to spoof them.