Skip to main content

Questions tagged [iptables-persistent]

2 votes
1 answer
804 views

Why was UFW removed automatically?

I noticed that the package UFW had been removed from a server, but do not recall having manually removed it. Looking at the logs at /var/log/apt/history.log, I noticed this entry: Start-Date: 2024-06-...
ealfonso's user avatar
  • 1,005
0 votes
2 answers
3k views

cannot get iptables to auto load rules on reboot with iptables-persistent

I need some help, or advice. I have a latest server I am trying to get into production and I cannot get it to load its rules on a reboot. "Debian GNU/Linux 10 (buster)" it is up to date in ...
gstlouis's user avatar
0 votes
1 answer
789 views

How can I copy all traffic on a network and forward it to another IP address?

I'm trying to use iptables. I'm simulating a network with Mininet. I currently have a router connecting two subnets (10.0.1.1/24 and 10.0.2.1/24). If I use these two iptables rules on the router I see ...
Luigis94's user avatar
0 votes
1 answer
872 views

Iptables Accept All From Specific Ip And Port

I want to accept all traffic that is coming from an IP address and its specific port to any of my ports. Here is the configuration: Details: I am using Jitsi in a server, and I want to reach Jitsi ...
sahin's user avatar
  • 1
0 votes
3 answers
362 views

Blocking internet of an DHCP assigned static IP, but allowing internal LAN network to get to device

I have a Rasberry Pi that DHCP assigns a static IP address (Based on it's MAC address) at 192.168.2.12 with the Local gateway at 192.168.2.1, I want to block internet traffic to it and from it, but I ...
Rick T's user avatar
  • 357
0 votes
0 answers
140 views

Something is modifying my iptable, can it be traced?

I've got the following command in my iptable: -A FORWARD -o enp0s3 -j ACCEPT That somebody doesn't like, because after 2 reboots, it's gone from the iptable... I've got iptables-persistent installed, ...
Adam Larsson's user avatar
1 vote
1 answer
4k views

Can UFW work with iptables-persistent?

I used a script to set up iptables rules and then made them persistent with iptables-persistant. This is described here as a means to prevent a certain user sending traffic over eth0 so it can just ...
bomben's user avatar
  • 549
1 vote
1 answer
561 views

Debian10 iptables-restore [legacy] just fails with simplest rule

I'm trying to set up a simple firewall with docker and I wanted to use iptables-restore. I changed the iptables used to legacy (so shouldn't use nftables if I'm right). The problem is that even a file ...
Brummbaer's user avatar
0 votes
1 answer
420 views

Ubuntu 18.04 Server Internal and External network configuration

I have issue in Ubuntu 18.04 Server to configurate internal and external network. Case is that i have Gateway device which has DHCP service to lease IP addresses for wlan connected devices. Gateway ...
Sami Pylkkänen's user avatar
2 votes
0 answers
543 views

arptables-nft persistence

Introduction This is on Debian Buster with kernel 4.19.0-6 I've installed iptables-persistent and netfilter-persistent versions 1.0.11 and added a basic rule to arptables-nft to block all LAN ...
seanlum's user avatar
  • 41
0 votes
2 answers
235 views

Default configuration iptables, how to avoid to be blocked when flushing tables?

I have this base for iptables when I have a new server to configure : *filter :INPUT DROP [0:0] :FORWARD DROP [0:0] :OUTPUT ACCEPT [0:0] # Keep state. -A INPUT -m state --state ESTABLISHED,RELATED -...
Mévatlavé Kraspek's user avatar
3 votes
2 answers
4k views

Force iptables to immediately put drop rule into effect

I have the following setup: in /etc/iptables/rules.v4 # Generated by iptables-save v1.4.21 on Mon Jul 1 11:32:00 2019 *filter :INPUT ACCEPT [0:0] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [3:620] -A ...
spaceman117X's user avatar
1 vote
2 answers
4k views

How to get UFW to read current iptables rules after modification? (Ubuntu)

I am adding a chain using iptables: iptables -N ETDROP When I reboot, this is lost. I read of many ways to make iptables rules permanent... however You must remember, I am using UFW and UFW has ...
conanDrum's user avatar
  • 465
6 votes
1 answer
5k views

How to save only specific iptables chains?

I need to configure iptables on a linux machine with running docker containers. If I save iptables rules with iptables-save > /etc/iptables/rules.v4, rules from all chains will be written to file. ...
Marat Safin's user avatar
1 vote
1 answer
3k views

iptables-restore failed in Debian buster/sid if it has --multiport option in the rules file

I have /etc/iptables/rule.v4 file contains many rule, the below is the line where I see the issue -A INPUT -p tcp -m multiport --dports 22 -j ACCEPT -A INPUT -p udp -m multiport --dports 16384:32768 -...
Karthik's user avatar
  • 189

15 30 50 per page