Community discussions

MikroTik App
 
thebombdig
just joined
Topic Author
Posts: 14
Joined: Tue Apr 17, 2018 1:28 pm

FIREWALL Deny any any

Tue Apr 17, 2018 1:44 pm

Hi I wanted to check if there is a way to put a block all rule at the bottom of the firewall rules, like on a cisco or checkpoint firewall; on the lines of Deny any any. So that unless your traffic matches any of the allowed rules above your traffic will be dropped.

As I tried to add a rule below at the bottom of any regular rules but it just dropped all traffic in to the router.

chain=input action=drop src-address=dst-address= log=yes log
 
solar77
Long time Member
Long time Member
Posts: 586
Joined: Thu Feb 04, 2016 11:42 am
Location: Scotland

Re: FIREWALL Deny any any

Tue Apr 17, 2018 4:37 pm

Mikrotik check its firewall rules from the top. so drop all rule needs to be at the very bottom, traffic does not match any of the rules before it, will be dropped.

so normally in input chain, you would have drop invalid, accept winbox on 8291 and any other traffic you wish to allow, accept established and related, then drop all
 
User avatar
Steveocee
Forum Guru
Forum Guru
Posts: 1120
Joined: Tue Jul 21, 2015 10:09 pm
Location: UK
Contact:

Re: FIREWALL Deny any any

Tue Apr 17, 2018 4:48 pm

Place something like this at the bottom of your rules and you'll be good to go.
/ip firewall filters
add action=drop chain=input comment="DROP ALL" in-interface=WAN-INTERFACE
Notice that it does not specify source or destination addresses (as not needed in my opinion) or logging as it will get hit a lot but specifies only traffic coming up your WAN as you don't want to lock yourself out locally.
 
thebombdig
just joined
Topic Author
Posts: 14
Joined: Tue Apr 17, 2018 1:28 pm

Re: FIREWALL Deny any any

Tue Apr 17, 2018 6:13 pm

Thanks you very much

Who is online

Users browsing this forum: Amazon [Bot], bmaddison and 96 guests