Stop DDOS attacks on a cisco router

ISPs have other options available that depend on routing changes, such as black hole filtering. Black hole filtering works by forwarding malicious traffic to an imaginary interface known as Null0 – similar to /dev/null on Unix machines. Since it’s not a valid interface, traffic routed to Null0 is essentially dropped. Moreover, this technique minimizes performance impact – a useful feature during the DDoS investigation so the rest of the network remains stable under the heavy load.

Here’s the simplest form of a black hole route:

Router(config)# int null0
Router(config-if)# no ip unreachable
Router(config)# ip route null0

This statement sends all traffic arriving on this router to the null0 interface — in effect, discarding it and sending it to the black hole.

You could also redistribute this route into your dynamic routing protocol and have it sent to all other routers on your network. Then, all routers would send traffic to your router, and your router would drop that traffic.

Using ISP back hole you could limit some bad traffic, imagine that the target IP for the DDOS is and my AS is 1234. The transit provider is 1000 and he blackhole community is tagged with 666.

On a cisco router I may use the following to blackhole the traffic before the
traffic enter my network.

router bgp 1234
bgp router-id
redistribute static route-map static-to-bgp
route-map static-to-bgp permit 5
match tag 666
set community 1000:666 additive


Author: Ali MEZGANI

My name is MEZGANI Ali. I was born back in 1978 in Rabat Morocco. My interests are Debian Linux , programming , science and music.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s