Questions tagged [iptables]

Iptables is a module that provides the Linux operating system functions of firewall, NAT and logging of data traveling over a computer network.

Filter by
Sorted by
Tagged with
1
vote
1answer
25 views

Forward ssh connection to Android devices

In my lab I want to set up a ssh jump host that forwards incoming ssh connections to Android devices that are connected to it via USB. All Android devices have USB-tethering turned on. The tethering ...
3
votes
2answers
3k views

iptables rules to allow devices on VPN to access internet

I have a linux firewall setup as my home network gateway that is correctly leasing IP addresses to devices on my network, and those devices have internet access. I also setup OpenVPN on the same ...
0
votes
0answers
6 views

Kali Hotspot with Internet access thru proxy

i have i question. My Kali laptop is only have access to the internet with a proxy (username, password, serverip an Port). Now i configured a Hotspot with Hotapd and i want to use the Internet with ...
0
votes
0answers
13 views

Allow client to client communication in OpenVPN for certain IP range

The Goal We've got one OpenVPN Server that's up and running (10.8.0.0/16). And some clients. Clients can be separated into two specific groups: humans and non-humans. The non-humans shall only have ...
0
votes
0answers
9 views

how to configure windows 2012 SNAT?

I want to change source IP of out packet, on the linux system is easy to done by one iptables rule iptables -t nat -A POSTROUTING -d 192.168.47.216 -p udp -m udp --dport 6661:6680 -j SNAT --to-source ...
0
votes
0answers
17 views

Manipulating MTU size in IPTables with mangle for use with OpenVPN

I am looking for any and all pointers in regards to modifying or resetting MTU size with the mangle table in iptables. Specifically where in the iptables flow is it more efficient to modify MTU to ...
0
votes
1answer
5k views

sysctl: cannot stat /proc/sys/net/ipv4/icmp_echo_ignore_broadcast: No existe el fichero o el directorio

I have a Debian 9 Stretch and I'm configuring as webserver. For this I'm applying rules in iptables and another parameters in /etc/sysctl.conf I would like to apply this rule in FW:(it's inside the ...
1
vote
1answer
45 views

Failed login attempts, constant brute force

I'm running a VPS with an iptables firewall (configured via ufw). I have shut down all traffic with: sudo ufw default deny incoming sudo ufw default allow outgoing After that I have opened certain ...
0
votes
1answer
63 views

OpenVPN but one user by VPN

I expose here my project. I have a server running a ubuntu. The server is set up with multiple VPN connection (tun0, tun1, tun2 ect) I use this to launch my VPNs: sudo systemctl start openvpn-client@...
2
votes
1answer
4k views

Man in the middle using iptables

I wish to test a subsystems which communicates with another subsystems via tcp. I have used the following: "iptables -A OUTPUT -p tcp --dport "+port_number" -j DROP" to stop the traffic on a port so ...
0
votes
0answers
60 views

firewalld failed since installing docker

Firewalld has been writing the following errors in the logs since installing Docker: WARNING: COMMAND_FAILED: '/usr/sbin/iptables -w10 -t filter -F DOCKER' failed: iptables: No chain/target/match by ...
2
votes
1answer
20 views

Terminate or bust natted connection

I have a problem with natted connection on linux. I'm using Debian 10, and iptables to do some SNAT to force all my packets outgoing from eth0 to a specific UDP port to use a specific IP attached to ...
0
votes
0answers
28 views

iptables, limit openvpn forwarding for specific destination sub-nets

I'm attempting to setup a openvpn server, which runs 2 different instances of openvpn, to provide access to different vpc subnets. If users are connected to the 10.6.0.0/24, they should have access ...
0
votes
0answers
7 views

Iptables rule lock me out

I found this security rule, but when I use it, it lock me out. I wonder why others recommend this one when it is not so perfect obviously? Perhaps, the rule have some errors? /sbin/iptables -t raw -A ...
1
vote
2answers
441 views

iptables forward non-local traffic through ssh proxy

I trying to forward traffic from a local port to a remote machine through SSH proxy (not tunnel). I learned, that it can't be done only with iptables rules (please correct me, if it's not true), so I ...
0
votes
0answers
10 views

Block with iptables

I tried to block all connection except from one specific ip with iptables: Allow all from one ip sudo iptables -A INPUT -s %MY_IP% -j ACCEPT Denied all sudo iptables -A INPUT -j REJECT But after the ...
0
votes
0answers
9 views

Change originating IP address if the destination IP is a certain IP

Using windows boxes. I have a webserver on a windows box, that has three IP addresses. Internal management, data and external The webserver uses the data IP for communication between the subsystems. ...
2
votes
1answer
3k views

Route LAN traffic through eth0, not tun0, on my VPN access point

How can I make my Access Point send traffic to 192.168.1.0 through eth0 and all other traffic through tun0? I have set up a Raspberry Pi VPN access point. It sits on the same subnet as all my servers,...
0
votes
0answers
10 views

Android: how to find application locking xtables? [migrated]

I have Pixel Experience (Android 10) installed on my Redmi K20. + Magisk 21.4. In terminal I enter command iptables -t mangle -L -n | grep TTL which throws Another app is currently holding the xtables ...
0
votes
1answer
3k views

DNS resolving broken after installation of bind due to iptables

I successfully configured my web server (Apache, PHP etc.) and blocked the ports I don't need using iptables, which was working perfectly fine. Today, I installed BIND and configured it, which also ...
0
votes
1answer
4 views

Basic Linux Iptables firewall problem

After inputting these commands into a terminal on a host with Iptables installed, no web pages are loaded after connecting to a wireless network with internet access. I know it's something simple but ...
0
votes
1answer
26 views

iptables on DD-wrt to bypass VPN outgoing port 993

I'm using the DD-wrt, openVPN client and NordVPN. I recently found out NordVPN blocks Email ports like secure Imap port 993. Ive been trying to create a rule in my DD-wrt commands, and i can't seem to ...
2
votes
1answer
4k views

Docker tunnel traffic on specific port via VPN

Not sure if this is docker specific or a general networking question. I'm running a Debian Jessie server with serveral docker containers. My understanding is that docker creates a virtual interface (...
0
votes
0answers
13 views

What is being logged in iptables with these entries?

I have a server behind a hardware firewall supplied by the phone company. I'm logging these entries with iptables. I don't expect any public IP address from outside the USA to be accessing the server. ...
0
votes
0answers
15 views

Route all traffic of one interface (local: eth0) to another interface (tun0) & vice versa including broadcast in Debian Linux for specific port

I am using eth0 port on my device to connect multiple 3rd party devices on same subnet. On my device, I have also initialized VPN Interface (tun0) to connect it externally. Locally (eth0) all devices ...
0
votes
0answers
11 views

socat tee very laggy/stuttery?

I have to implement a videorecorder on a networker. In order to do that I need to duplicate the unicast Stream from the camera to 2 hosts. I've tried the following: socat - udp4-listen:53260,fork,...
0
votes
1answer
29 views

How to change destination-IP from packets through iptables?

I managed to duplicate the data through: Sudo iptables –t mangle –A PREROUTING –p udp –d 192.168.2.100 –dport 53260 –j TEE –gateway 192.168.2.80 Linux at 192.168.2.80 receives the packets, however the ...
0
votes
0answers
16 views

iptables: only allow specific mac addresses

I hope someone here can help me out with this as it's probably a really easy setup. I am on centos 8 -- disabled firewalld and installed iptables-services. I have one physical interface with a bridge ...
0
votes
0answers
37 views

how to get udp unicast to two hosts?

The two hosts need to have to same ip. My solution at the moment is a port mirror, but the problem is as mentioned the duplicate of the ip address, I think. I couldn't find a way to disable the IP-...
20
votes
3answers
100k views

How to verify if iptables is running or the firewall is activated

When I run on my linux Redhat version 6.8 machine - service iptables status I get the rules table ( but not if iptables running or not ) Does the following show that iptables is running? # ...
0
votes
0answers
181 views

Forward all web traffic From wlan0 to eth0 in iptables

There's so many howtos on how to do this, and they're all slightly different, and they all give me a headache to try and decipher... I have a Raspberry Pi that's "bridging" eth0 to wlan0 ...
3
votes
2answers
7k views

DD-WRT firewall rule configuration

I'm using DD-WRT on my linksys router. I want to limit each user on my network to 200 connections at any given time. Does anyone know the rules I enter the firewall in DD-WRT admit panel. I tried ...
0
votes
1answer
3k views

Centos 6 server does not open ports

So after some battling and struggling with the firewall, i see that I may be doing something or the firewall isnt responding correctly there is has a port filter that is blocking certain ports. Okay, ...
0
votes
0answers
35 views

IPtables rule to allow Lets encrypt

This message appears when I try to get Lets encrypt certificate, because the IPtables rules. I cannot figure out which rule blocks it, so I want to append "allow" rule. Do you know the right ...
0
votes
2answers
3k views

how to restore iptables after iptables -F?

I used iptables -F on my machine, and what can I do to recover the iptables into the default without rebooting my machine? I restarted the iptables service and it failed, and I can't find iptables ...
3
votes
1answer
4k views

Match multiple strings in iptables

I have 2 strings, and i wish to queue the packet if it contains both the strings ( something like ("jsh"&&"gjhyg")), i tried following ways, but they don't seem to work: sudo iptables -A ...
3
votes
1answer
7k views

iptables-restore failed at COMMIT line, no detailed description

I'm trying to setup iptables (using iptables-restore) for a new server and was looking at the security docs from Linode, so basically used their templates for IPv4 and IPv6. These are both failing at ...
0
votes
1answer
56 views

Routing between two wireless interfaces - Linux

Basically, my network looks like that +------+ 10.0.0.10 ------ 10.0.0.1=|Laptop|=11.0.0.11 ------ 11.0.0.1 (wlan0,client) (AP,wlan0)+------+(wlan1,client) (AP)...
0
votes
1answer
20 views

Access Raspberry Pi behind a NAT firewall through Internet

I have been developing projects with Raspberry Pi 4. For the current project I am running a NextCloudPi server on it. I am able to access the server using my Internal IP. I want to access it using a ...
0
votes
0answers
20 views

Open Custom ports in Ec2

I am trying to open up custom port 12345 from Ec2 instance. Here are the details. When i do nmap on localhost i see the below Nmap scan report for localhost (127.0.0.1) Host is up (0.0000080s latency)....
1
vote
0answers
41 views

500 Server Error: Internal Server Error with Kathara, Docker and iptables/nftables

I want to use Kathara via "kathara lstart" but I get a 500 Server Error: Internal Server Error and I don't understand why. I'm using Docker (Preview version for Apple M1). I don't know if ...
0
votes
1answer
32 views

Lighttpd returning from curl rather than nginx

I have been having issues with being able to reach my websites hosted on my Raspberry Pi on my home network. It was all working until recently and I can't work out what I've done to break things :( If ...
1
vote
0answers
69 views

IPtables help forwarding port through WireGuard connection

I have a home server behind a carrier-NAT so I cannot forward any ports to it. I have PLEX running (in a docker container) on the server and would like to access it from outside my home network. ...
0
votes
0answers
25 views

Iptables Forward All traffic to different interface except local inter-lan

I have two Local Area Networks (LAN). Local LAN: 172.30.30.0/24 with gw 172.30.30.254 Remote LAN : 192.168.2.0/24 with gw 192.168.2.1 Both LAN's can communicate and ping each other devices. I have ...
1
vote
1answer
3k views

What is MASQUERADE made for?

A simple redirection is used on my server, with iptables rules : $ iptables -t nat -A PREROUTING -p tcp --dport 80 -j DNAT --to-destination 13.37.42.1:80 $ iptables -t nat -A POSTROUTING -j ...
1
vote
0answers
14 views

Server connections refused when hostname used, works fine with IP

Hope someone can help. I've run a local server for a while on a Rapberry Pi 3b (Raspbian Buster) that includes a PBX server, DNSmasq and local webserver. I recently upgraded to a Pi4 and performed a ...
0
votes
0answers
25 views

Forwarding a port to a local address using iptables

I'm running a TeamSpeak 3 server on a home server. I would like to mask the IP address of the home server so I am using a VPS as an entry point to my TeamSpeak 3 server. I found a tutorial online that ...
4
votes
4answers
12k views

OpenVPN connection through SSH tunnel

I'm currently visiting China, so I have some options for VPNs set up. However, my VPN servers have a habit of suddenly disappearing from the network after I've used them for a while. I thought it ...
1
vote
1answer
4k views

Sharing OpenVPN to specified IP-range on the local LAN

Is it possible and how to share OpenVPN (currently Anonine) -connection to specified IP-addresses on the local LAN? Local LAN consist windows- and linux machines and Android devices. Current setup, ...
0
votes
1answer
47 views

Nordvpn blocking internet traffic despite being disabled

I have a problem with NordVPN on Debian Buster: I've been using iptables on my Linux PC, but after disconnecting from NordVPN, the IPtables rules still persist and I have to manually reset them to ...

1
2 3 4 5
33