im new in firewalls etc. readed nftables quick reference
how to allow only my mac address (my device - laptop, phone etc.). allow my mac to access ssh port (port:22)
tried that:
ether saddr 00:00:00:00:00 tcp dport 22 accept;tcp 11:11:11:11:11 dport 22 drop
//numbers 00:00:00.... and 11:11:11.... are examples, where 00:00:00.... is my mac address
this combination dropped all connections to ssh port...
MAC address restrictions are a joke because it is beyond simple to clone a MAC address. Anyone on your LAN will probably have the ability to see a good MAC address and clone it.
If the machines you are concerned about are on a different LAN, then MAC address filtering will do no good, anyway, because MAC addresses are only valid or seen on the LAN that has the host with that MAC address. Routers strip off layer-2 frames, including the MAC addresses in the frames.