First fetch the address list in “mikrotik” format. Open “New terminal” in winbox. For example script:
/tool fetch url=" mode=http;
:log info "Downloaded spamhaus.rsc from Joshaven.com";
:delay 40;
/ip firewall address-list remove [find where comment="SpamHaus"];
/import file-name=spamhaus.rsc;
:log info "Removed old Spamhaus records and imported new list";
This script downloads a file with a black list of IP addresses (spam) from the site to the firewall address list. Next, you can set up a firewall rule that will deny connections to these IP addresses.
Add rule to firewall for this list:
/ip firewall raw add chain=prerouting action=drop src-address-list=SpamHaus
2,697
Xem tiếp...
/tool fetch url=" mode=http;
:log info "Downloaded spamhaus.rsc from Joshaven.com";
:delay 40;
/ip firewall address-list remove [find where comment="SpamHaus"];
/import file-name=spamhaus.rsc;
:log info "Removed old Spamhaus records and imported new list";
This script downloads a file with a black list of IP addresses (spam) from the site to the firewall address list. Next, you can set up a firewall rule that will deny connections to these IP addresses.
Add rule to firewall for this list:
/ip firewall raw add chain=prerouting action=drop src-address-list=SpamHaus
Similar Posts:
- Mikrotik: drop ports scanners + honeypot
- pfsense connection tracking setup like a Mikrotik
2,697
Xem tiếp...