Starting from RouterOS v7.1beta4 Mikrotik has support for REST API which can be used by FastNetMon to create or remove routes (usually blackholes) without using BGP.
Before starting this guide please read official Mikrotik guide and enable www or www-ssl service on Mikrotik.
To enable this capability please upgrade FastNetMon to version 2.0.359.
Then enable this logic following way:
sudo fcli set main mikrotik_announce_host true sudo fcli set main mikrotik_announce_host_blackhole true sudo fcli set main mikrotik_rest_api_urls http://admin:admin@192.168.1.131 sudo fcli commit
In addition to plain HTTP mode we support encrypted HTTPS mode to access Mikrotik REST API too.
After that FastNetMon will create / remove routes on Mikrotik side every time when FastNetMon blocks / unblocks hosts:
To test that integration works fine we recommend manually blocking and then unblocking some test host:
sudo fcli set blackhole 1.2.3.4
Then check list of blocked hosts and get UUID of it:
sudo fcli show blackhole
To unblock host you need to use UUID from previous command and issue following command:
sudo fcli delete blackhole d9b1885f-6d9b-4167-9e3e-0a3198bacee9