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

learn more… | top users | synonyms

1
vote
0answers
128 views

Setting up RTMP for streaming (Console)

So I have been trying to set this up for the past few days and I am having so much trouble actually getting this to work. I have installed Nginx with the optional RTMP module onto my Mac and I also ...
1
vote
2answers
165 views

does IPTABLES as a router always require masquerade / SNAT?

If I set up a linux box as a router behind a DSL gateway, do I need to enable masquerading or SNAT? Logically I would assume that all I need to do is enable ip_forwarding (done) but traffic to ...
1
vote
1answer
6k views

Fail to start iptables.service: 'No such file'

I'm trying to directly use iptables instead of firewalld to manage firewall rules. However systemctl start iptables prints: [root@centos-new ~]# systemctl start iptables Failed to issue method call: ...
0
votes
1answer
65 views

How to I configure iptables for both IP masquerading and firewalling at the same time?

I have a host that acts as a gateway for routing a home network to Internet. IP Masquerading has been enabled for months now and the system has worked fine. How do I configure it to function also as ...
0
votes
0answers
29 views

iptables wont take any arguments

I have an ubuntu server configured as a gateway router with eth0 (ext connected to a dsl router) and eth1 (internal network) I have Source NAT enabled, to share the external IP with all internal ...
0
votes
1answer
39 views

Iptables issue error at line 2

I messed up with my ip table now i am facking some kind of issue with that iptables to start.Below content is present in my iptables file. But when i try to start the ip tables i am facing error as ...
0
votes
0answers
182 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
0answers
37 views

Disabling incoming traffic on an interface

I have an embedded device, which uses iptables v1.2.11 for packet filtering. The device has two interfaces eth0 and a mobile channel ppp0. My goal is to disable all incoming traffic (to any listening ...
0
votes
0answers
26 views

Is it possible to route all traffic to a vpn except multicasts?

I am using a router with tomato firmware installed. My lan includes a tv, eg ip 192.168.0.2. The tv receives multicast broadcasts from an iptv provider, but can also access the internet to view ...
0
votes
0answers
59 views

Allow access to camera only by one IP - tomato

I'm running tomato shibby 1.2.8 on an ASUS router. I have a camera in my network, which has the IP 192.168.1.222 (static IP). I would like to block all connections to this IP, where the source is ...
0
votes
0answers
26 views

How does IPTables console logging effect network packet drops?

How does console logging effect network packet drops? I am asking because I have iptables running with logging option and it logs packets to /var/log/iptables. I didn't configure --limit option in ...
0
votes
0answers
222 views

Setting up Raspberry Pi as router with multiple interfaces on same subnet

Backstory: My college doesn't allow for multicast/zeroconf/upnp on their network (and understandably so, since there are way too many devices on the network). As a result, I'm trying to use my ...
3
votes
1answer
2k views

Two NICs on the same subnet but with different networks?

Description This is similar to this question, but different: Linux computer has two NIC. eth0 is statically assigned with an IP. eth1 is assgiend by personnel in the field which could be same IP or ...
1
vote
0answers
33 views

Problems with opening ports on Linux

Basically I have tried every tutorial I could find but I can't seem to open a port in a Linux VM. I tried downloading gufw and opening a port there; didn't work. I disabled gufw; didn't work Set a ...
0
votes
0answers
11 views

IPtables restrictions and OpenVPN

So, my friend has a virtual machine that runs linux and an OpenVPN instance. He wants to restrict all IP addresses except for address of an OpenVPN instance. The idea is, not to let anything to ...
0
votes
0answers
59 views

Unable to remove port 22 from firewalld

I am running a VPS that i have gone and installed firewalld on, on this box, the service comes by default with port 22 open so that you can still gain ssh access. I have manually changed the SSH port,...
0
votes
0answers
120 views

Can't reach server, using external IP from internal network

I have a Raspberry Pi 2, running Raspbian and using as a wireless VPN router. I'm a beginner with networking, but successfully set up masquerading to VPN's tap0 interface and allowing forwarding ...
0
votes
2answers
269 views

With iptables how to route traffic from virtualbox internal adaptor to eth0 interface?

i was learning iptables a bit deeper and things were going good but i am confused with using DNAT, SNAT and MASQUERADE, i was doing paractice with them and couldn't find a way to simply route traffic ...
0
votes
0answers
25 views

filezilla not connecting even with required ports opened

Server: Ubuntu 15.04 - 2.6.32-042stab094.8 Client: Windows 10 I did some iptables changes, saved all rules, naturally, reapplied them afterwards, summary of changes are: open ports tcp: 20, 21 ,...
1
vote
1answer
90 views

Port 80 forward on home router

I have a generic Linux home router. I can change iptables on it by telnet to console. Currently, it is set up to forward all incoming connections to machine on my internal network, using something ...
1
vote
0answers
198 views

tomatousb - Allow only specific IP to connect to other IP port

I'm using tomato shibby on a router, and I'm trying to set some specific rules using iptables to set the following: I have a server, which runs on 192.168.1.2 (LAN) port 2232. Everybody from the LAN ...
0
votes
0answers
47 views

SSH Connection Refused : Wrong conf

I am trying to harden my SSH configuration. In addition to modify sshd_config file, I added some iptables rules. Here are the common ones: # Default policy iptables -P INPUT DROP iptables -P FORWARD ...
0
votes
1answer
979 views

TCP connect: No route to host

I started a tcp server on a host A and then start a tcp client on another host B. Both hosts are in the same LAN via the wireless router at home. the tcp client tries to connect to tcp server on port ...
0
votes
0answers
40 views

Local host's iptables dropping packets even though router firewall only forwards one port

I have a computer on a small WLAN that is connected to the internet via a router. The router has firewall software and I have set up the router firewall to forward port 1234 and only port 1234 to my ...
1
vote
1answer
57 views

Connect to wifi while hosting AP on another iface

I have two wireless interfaces. wlan1 and wlan0. And I want to host some Access Point on wlan1 (airbase-ng and isc-dhcp-server) and redirect packets from access point interface(at0) to wlan0 which ...
0
votes
0answers
32 views

How to fail fast with iptables?

Inspired by the Pi-hole I set up my own one. What it does: The Pi-hole is configured as a dedicated IP in my local net on a virtual adapter of Raspberry Pi. Get list of known spam / phishing / ad ...
1
vote
0answers
68 views

iptables SNAT target and TCP ACK packets

I need to establish a TCP connection where the client is spoofing its IP for all outgoing traffic. My first attempt was to add a rule to the POSTROUTING chain like so: iptables -t nat -A POSTROUTING -...
1
vote
1answer
1k views

using firewalld and firewall-cmd how to add-rule to primary INPUT chain not INPUT_direct

so after reading the firewalld man page and fedora documentation, I have come to the understanding that to add a custom rule to firewall with specific arguements i need to use the structure firewall-...
0
votes
0answers
454 views

IPTables NAT and virtual interfaces

I have 2 VM's running CentOS 7 with the following ifconfig configurations: VM1: ifconfig eth0: public ip eth0:0: LAN IP 172.22.xx.x1 VM2: ifconfig eth0: no public ip eth0:0: LAN IP 172.22.xx.x2 ...
0
votes
0answers
240 views

Opening the Postgresql port

I'm trying to connect to a Postgresql server from a remote computer using: psql -U dbuser -h [host address] But I get the following error: psql: could not connect to server: No route to host Is ...
0
votes
0answers
24 views

Hostapd does not process HTTPS trafic from ppp0

I setup router server with hostapd 2.3 which works perfectly with eth0 -> wlan0 configuration. But if I'm switching config to ppp0 -> wlan0, then clients connected to wlan0 can access only to HTTP ...
1
vote
1answer
1k views

Squid 3.3 Transparent IPv4 and IPv6 Proxy with TPROXY

I'm attempting to change my Squid transparent setup from using generic NAT that's limited to IPv4 only and switching it to TPROXY, for IPv6 support. I'm having difficulties getting transparent clients ...
1
vote
0answers
196 views

Can't ping server itself after connected to PPTP VPN

I've set up a PPTP server on a CentOS 6.5 machine to use VPN from public networks and other miscellaneous scripts. Everything seem to be working OK except I can't ping the VPN server by its public IP ...
0
votes
0answers
108 views

Policy based routing with uid (ArchLinux)

Desktop (ArchLinux) with 1 physical NIC wlp0s29u1u5 connecting to the Internet. There is then a Openvpn client run on it as tun0. How can I make it that user (uid 1000) traffic only uses tun0? I've ...
0
votes
0answers
383 views

Cannot open pritunl port to outside

I'm trying to install pritunl on my Ubuntu 14.04 VPS, I managed to open port 9700, so I can connect to the web interface, my VPN should be running on port 16118, but for some reason I am unable to ...
0
votes
1answer
717 views

Mark packets with iptables by destination mac address

I need to mark packets which goes to a specified mac address. I need this to use in shaper with tc. --mac-destination doesn't exist in iptables. Also I tried to use ebtables: ebtables -t nat -A ...
1
vote
1answer
744 views

Check for packets MARKed by iptables

I am marking TCP and UDP packets in order to send them to two different interfaces (say wlan0 and eth0), I did this by following this answer. Assuming this configuration: eth0 address: 192.168.0.84 ...
0
votes
0answers
38 views

iptables linux - open all ports/everything for few servers and close everything from other servers

I want to open all ports (everything) for few servers and close all traffic incoming from any other server. iptables -A INPUT -s <ip of server1>/24 -p all -j ACCEPT iptables -A INPUT -s <ip ...
0
votes
0answers
59 views

Iptables in DD-WRT

I have a WRT54GL router with DD-WRT connected to (in the same VLAN): IP radio with very low bandwith (192.168.1.107) Arduino with Ethernet Shield sending UDP messages (192.168.1.110) Another router ...
0
votes
0answers
99 views

Using pptpd with iptables and interface ppp0

I already asked this stackoverflow, but I was told to ask it here :) I'd like make a few ports only accessible via VPN (PPTP). I'm running Debian 8 on the server and pptpd v1.4.0 from apt-get and ...
0
votes
0answers
298 views

Route all traffic of several VMs through a specific VM

I want to setup 3 VMs such that VM1 and VM3 can only talk to each other through VM2. So basically, all the traffic from VM1 and VM3 needs to be routed through VM2. VM2 then forwards the traffic or ...
0
votes
0answers
134 views

How to block HTTP 302 redirection package by matching a specific string on Location?

The HTTP response I want to block has: Header HTTP/1.1 302 Found Location: http://www.yxjiaodai.com/ad/?id=1023&url=http%3A//a1819.oadz.com/link/C/1819/3081547/dtMdon4l79FwsIo2JXEHqtdp5eQ_/p007/...
0
votes
1answer
186 views

What are the security risks of connecting to a VPN?

Does connecting to a shared-IP VPN expose local ports to other users of the same VPN server? Does a VPN tunnel neutralize the protection offered by a NAT router? Are local ports reachable from a ...
0
votes
0answers
175 views

Error when configuring iptables while setting up OpenVPN on Raspberry Pi

I'm in the process of setting up OpenVPN on my Raspberry Pi. Not sure if this is the right forum to post this but when I was trying to configure iptables i get this error message. Any thoughts? Thanks....
1
vote
0answers
93 views

OpenVPN and port translation

So, here's the deal. I have an openvpn instance on a port 443. I need it to also be on port 993, the same instance, the same virtual network. Openvpn can not really do that, but Linux comes with ...
-1
votes
2answers
60 views

how to verify firewall rule for a particular service?

How could i check which firewall rules are used by a particular service and whether port is blocked to restrict access by external users? i.e netstat -tulnp | grep 123 udp 0 0 0.0.0.0:...
0
votes
0answers
40 views

transfer ARP on linux iptables with diffrent subnet

Firewall(linux) - with 2 interfaces: internal, external ; also used as GW Internal: 192.168.254.1/16 External: 10.0.254.1/16 external_client(linux) IP: 10.0.1.1/16 internal_client(linux) IP: 192.168.1....
1
vote
0answers
37 views

How is Windows ICS service different from Linux-based NAT & routing when I want to hide my LAN structure from ISP?

Background I've been using a WIFI-router as my home gateway perfectly until my ISP appears to restrain the number of connected devices. And currently there is not any realistic upgrade plan from the ...
0
votes
1answer
57 views

Giving a local machine an external static IP ( can be just forwarded ports)

I've planned to make one of my home machines to be a mail server I can receive mail from other people on. I have a domain name for it, and I know I need a machine with a static external IP so I have a ...
0
votes
1answer
169 views

can't telnet on port 5433 on localhost after iptables stop

I'm trying to do a telnet localhost 5433 on my RHEL box but I get a connection refused error. I did a service iptables stop but am still getting the same error. Where else do I need to look to allow ...