Skip to content

A firewall program using python and netfilterqueue

Notifications You must be signed in to change notification settings

naklecha/firewall

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

firewall

DISCLAIMER: The following code is only for Ubuntu.

Features

  1. Block IP addresses
  2. Block access to certain ports
  3. Block specifed prefixes of IP address (to block networks)
  4. Block too many requests made by the same IP in a short period of time (user can specify threshold and time)

Steps to Run

  1. Type the following terminal command:
          iptables -I INPUT -d 192.168.0.0/24 -j NFQUEUE --queue-num 1
  2. Fill out the rules in the JSON file as follows:

  3. Execute firewall.py using python3

Requirements

  1. netfilterqueue
  2. scapy

Credits:

  1. Meghana Holla : https://github.com/meghana-holla
  2. Ornella D'souza : https://github.com/Onurene

Author

  1. Email: nishant.aklecha@gmail.com
  2. LinkedIn: https://www.linkedin.com/in/naklecha
  3. CodeChef: https://www.codechef.com/users/naklecha
  4. PYPI: https://pypi.org/user/naklecha
  5. GitHub: https://github.com/Naklecha
"Any suggestions would be appreciated"