Add more than 5 hundred access-list at same time

Unanswered Question
Sep 22nd, 2008


I 've a file (blacklist ip file ). Which is the fastest way add the ips to the router?

Is there any script to add them or maybe one by one added to the router?

Best regards

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Mark Yeates Mon, 09/22/2008 - 15:46


I don't know of a scripted method to apply a large access list. I would recommend breaking the ACL into many pieces and paste them in a section at a time to prevent errors. Then after you validate the ACL made it into the router accurately then apply it to the interface.



edgar-quintana Mon, 09/22/2008 - 22:27


ofcourse, this access-list is not a very big list... they are 400 or 500 access-list blocking networks.

I do not want to enter those lines manually even using sdm

Mark Yeates Tue, 09/23/2008 - 04:32

So you just have a list of networks that you would like to block? I've used excel to create large ACL's and it made things a lot easier than using wordpad.


edgar-quintana Tue, 09/23/2008 - 04:53



I've a file with ips in this format

to block

Do you use excel? How?

Mark Yeates Tue, 09/23/2008 - 05:39

There will definitely need to be alot of typing and conversion involved. Quite time consuming but when you get your spread sheet all done it will be much easier to make changes to your ACL. If you make each row an ACL and each column a different piece of an ACL. such as permit/deny |protocol | source IP/network |wildcard | destination ip/network | wildcard | port.




Mark Yeates Tue, 09/23/2008 - 06:17

After you create the spread sheet you can merge the lines then you can copy and paste them into the router and then apply the ACL to the interface.



PS: Don't forget a permit statement after your

deny statements.

cisco24x7 Tue, 09/23/2008 - 06:48

This is very easy to accomplish. What you're

asking can be done with EXPECT scripts. With

expect scritps, you can control the flow input

of the ACLs. I've add about 50,000 of ACLs into

a Pix firewall using Expect script.

Easy right?


This Discussion