https://github.com/cfunkz/linux-firewall-autoconfig
Auto configuration for common firewalls for linux newbies
https://github.com/cfunkz/linux-firewall-autoconfig
autoconfig autoconfiguration bash firewalld firewalld-configuration linux ufw ufw-firewall
Last synced: 4 months ago
JSON representation
Auto configuration for common firewalls for linux newbies
- Host: GitHub
- URL: https://github.com/cfunkz/linux-firewall-autoconfig
- Owner: cfunkz
- Created: 2025-01-04T19:20:04.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-01-04T20:54:33.000Z (9 months ago)
- Last Synced: 2025-02-26T14:27:09.367Z (8 months ago)
- Topics: autoconfig, autoconfiguration, bash, firewalld, firewalld-configuration, linux, ufw, ufw-firewall
- Language: Shell
- Homepage:
- Size: 43.9 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Firewall Management Script


This script is designed to help configure and manage firewalls on a Linux system, using two firewall management tools: **firewalld(Firewall-CMD) and UFW(Uncomplicated Firewall)**. It allows you to open and close ports, enable or disable the firewall, list active rules, and show the status of the firewalls.
Additionally, this script offers the functionality to specify **interfaces** (e.g., eth0, enp1s0) when enabling or disabling ports, allowing more control over the firewall rules especially if you're a newbie.
## What this does
- **firewalld and UFW**:
- Enable or disable ports with interface restrictions.
- List active firewall rules.
- Enable or disable firewall.
- Show the status of firewall.## What need
- **firewalld or UFW** installed and configured on your system.
- `sudo` privileges to modify firewall settings.## What do
1. **Download the script using curl:**
```bash
curl -sSL https://github.com/cfunkz/linux-firewall-autoconfig/raw/main/firewall_config.sh -o firewall_config.sh
chmod +x firewall_config.sh
./firewall_config.sh