Jump to content

Block Country Ips


Recommended Posts

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

  • Premium

So you can get a list of cidrs for a given country and add them to IPFW:

Get lists here:

https://www.ipdeny.com/ipblocks/data/countries/XX.zone

Where XX is the two digit country code, for example:

https://www.ipdeny.com/ipblocks/data/countries/fr.zone

 

You can manualy paste those into your table, or make a batch to do it for you. Using that example it will be something like:

ipfw -q table BLOCKED add 103.122.52.0/24

ipfw -q table BLOCKED add 103.133.84.0/22

etc

Considering your table is named BLOCKED.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.