OSPF filtering routes between areas
- February 21, 2018
- 1 reply
- 12188 views
Hi there,
I have a really frustrating problem with OSPF ...
I have two ASAs on the left within the area 1.1.1.1 and a vpn tunnel endpoint with the ip 192.168.200.1/32
I set up OSPF on both ASAs to redistribute the connected VPN client. That works as I want it to work. Actually it works too good...
The FortiGate in the middle shall be a ABR between the two areas.
But I don't want R2 in area 0.0.0.0 to have every /32 route for every VPN client. So I tried to set up a filter-list on the FortiGate to block the prefix 192.168.200.1/32 route (yep, already that desperate to keep it simple).
But no matter what I do the /32 route keeps popping up on R2 
Here's the output from the FortiGate:
FortiGate-VM64-KVM # get router info routing-table all
Codes: K - kernel, C - connected, S - static, R - RIP, B - BGP
O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default
C 192.168.1.0/24 is directly connected, port2
O 192.168.2.0/24 [110/11] via 192.168.1.2, port2, 00:18:14
C 192.168.3.0/24 is directly connected, port1
S 192.168.200.0/24 [10/0] via 192.168.3.1, port1
O E2 192.168.200.1/32 [110/20] via 192.168.3.3, port1, 00:18:13
config router prefix-list
edit "filterarea0"
config rule
edit 1
set action deny
set prefix 192.168.200.1 255.255.255.255
unset ge
unset le
next
end
next
end
config router ospf
set router-id 192.168.1.1
config area
edit 1.1.1.1
config filter-list
edit 1
set list "filterarea0"
next
edit 2
set list "filterarea0"
set direction in
next
end
next
edit 0.0.0.0
config filter-list
edit 1
set list "filterarea0"
next
edit 2
set list "filterarea0"
set direction in
next
end
next
end
config ospf-interface
edit "Internal"
set interface "port2"
set dead-interval 40
set hello-interval 10
next
edit "ASA-side"
set interface "port1"
set dead-interval 40
set hello-interval 10
next
end
config network
edit 1
set prefix 192.168.3.0 255.255.255.0
set area 1.1.1.1
next
edit 2
set prefix 192.168.1.0 255.255.255.0
next
end
config redistribute "connected"
end
config redistribute "static"
set status enable
end
config redistribute "rip"
end
config redistribute "bgp"
end
config redistribute "isis"
end
end
And yes, i know the filter shouldn't be applied everywhere. But as I mentioned, I'm REALLY desperate...
Looking forward to hear from you :)
~Sam
