iptables is the userspace command line program used to configure the Linux 2.4.x and 2.6.x IPv4 packet filtering ruleset. It is targeted towards system administrators. Please, when asking a question about iptables, add the output from the following command: iptables -L -v -n

learn more… | top users | synonyms (1)

1
vote
1answer
55 views

iptables forward incoming ipv4 traffic to ipv6 [closed]

I am new to iptables and I am lost and confused from its configuration. I have work server with IPv4 and IPv6 connection and the home server with only IPv6 connection. How to set up rules for ...
1
vote
2answers
196 views

Linux iptables drop traffic based on mac address

I'm doing some testing on my linux VM with one nic, I want to use it as some kind of a firewall which can block traffic of some clients based on a mac address. The client itself is having the VM as a ...
0
votes
1answer
54 views

How can I configure iptables to forward and forget?

I'm trying to create a front controller where users can connect to a specific port and have their connection redirected to a different IP/port. The reason I'd like to be able to do this is for ...
-1
votes
1answer
19 views

Can't connect to identically configured remote MySQL server

Where I work, we have a single development server, and a single production server that we manage on-site. When I try to connect remotely to the MySQL on the development server, I get this error: ...
0
votes
2answers
62 views

How to use iptables to block php scans

There are many scans for php files on my server, though I don't use php. I used the following rule to block those guys - iptables -I INPUT -p tcp --dport 80 -m string --string 'php' --algo bm -j ...
0
votes
1answer
31 views

DHCP wont release allocated IPs [closed]

I have a TP-Link td28151 router and I am using DHCP. I need to connect 40 devices to my router by Ethernet. I have set the count of my clients to 100, and my subnet mask is 255.255.255.0. I have ...
0
votes
2answers
87 views

How do I use OpenVPN for all traffic other than ports 80 and 22 (inbound and outbound)? [closed]

I use a dynamic DNS service which is sent ip address updates from my router. In router settings, ports 22 and 80 are forwarded to my server at 192.168.1.10. I have a webserver and sshd running on my ...
1
vote
0answers
143 views

Ports blocked on ubuntu 13.10 vps

I have been searching all over for an answer, i got a cheap vps server running ubuntu 13.10 and installed webmin which should allow me to go to serverip:10000 But i can't connect to it and ...
0
votes
0answers
21 views

OpenVPN on Ubuntu: IP Forwarding not working

I have successfully set up a VPN connection between a Windows 8 client and my Ubuntu server running OpenVPN. However, I just cannot get IP forwarding to work. I have adjusted all settings as desribed ...
1
vote
1answer
30 views

how to forward proxy requests using iptables

I've this schenario ----------------- ---------------- ---------- | SERVER A | ---(port:2128)> | PROXY | ---> | INTERNET | | (10.30.1.1) | ...
0
votes
1answer
90 views

Locked myself out of SSH with UFW

I had my server set up to accept SSH connections on port 21966, I followed some steps to configure ufw however it has now locked me out of all SSH access on any port! I've been able to boot my ...
0
votes
1answer
28 views

Tunnel interface inside Virtualbox IP forwarding

I am working on a solution to expose a development stack that resides inside a Virtualbox guest up to the Internet through OpenVPN tunnels. OpenVPN client fires up inside the guest VM and connects ...
0
votes
1answer
46 views

Turn IPTables Flush off CentOS

I made some changes to my iptables in a centOS machine. I noticed once I shut the server off it flushes all my iptables and goes back to the default. Is there a way to turn that off?
1
vote
1answer
41 views

Iptables configure gateway virtual machine with 2 interfaces

I have a virtual machine that works like a gateway from other virtual machines. The configuration of the interfaces is the following UBUNTU: eth0: ip: 10.0.2.2 netmask 255.255.255.255 ...
1
vote
3answers
56 views

Cannot connect to port 3306

I'm running CentOS on my VPS and are trying to get remote access to my MySQL database. So I added a line to my iptables using this command: /sbin/iptables -A INPUT -i eth0 -p tcp --destination-port ...
1
vote
2answers
20 views

Limiting MySQL User to connect from Second interface

The web server and the MySQL servers have a second interface on a network with no public internet access. How can a MySQL user be restricted to connect only from within the private network and ...
3
votes
1answer
43 views

Is it possible to create an iptables code lock?

Is it possible to implement a simple code lock triggered by connecting ports with iptables? So for example a visitor need to connect ports 1001,1009,1008,1004 in this order to get access to port 80. ...
1
vote
2answers
61 views

Why we have complex iptables settings for allowed services?

On several server systems, I encountered two dominant styles of iptables firewall configurations: The first one is blocking every INPUT except the ports of provided services like HTTP. The second ...
6
votes
1answer
126 views

Techniques to implement iptables rules

Usually a limited amount of services are configured on a server and most of the not needed ones are shut down, I was wondering what would be the best approach to firewalling with iptables. Is it ...
0
votes
1answer
87 views

iptables rules for a transparent squid2.7 proxy, and a single network interface

I want to use Squid 2.7 as a transparent caching proxy for HTTP traffic on a Raspberry Pi running Debian Linux. The raspberry pi will be connected to my wifi router (MBR1400) using a single network ...
-1
votes
1answer
23 views

Cannot connect to fedora via ssh (iptables) [closed]

I recently ssh-ed into my fedora machine at work. I ran the command: systemctl start iptables.service Now I can't ssh back into the machine. So far ssh has been my only way to access the machine. ...
0
votes
1answer
67 views

Cannot close Port 25 after installing postfix

Before installing logwatch (which installs postfix) on Ubuntu 12.04, the port 25 is blocked by iptables/csf PORT STATE SERVICE 25/tcp filtered smtp After installing logwatch (which installs ...
0
votes
1answer
28 views

Unable to nmap open port. IPTables has it listed as open

I have an IPtables firewall set up on a single system. I'm trying to nmap it with the following command: sudo nmap -Pn -A (IP addr) I expect everything incoming to be filtered except for ports 22 ...
0
votes
2answers
31 views

Forwarding all connections to different address

I have a script that tries to connect to rabbitmq using default url and port (localhost:5672). Is it possible to make linux redirect all connections to this url and port to different server? I am ...
1
vote
1answer
64 views

Linux iptables DNAT stops working after some time

3 down vote favorite I have a strange behaviour in my server setup. It looks like that. client1 192.168.11.2/24 <----> 192.168.11.7/24 (br1/vlan1) Server 192.168.21.1/24 (br21/vlan21) <---> ...
0
votes
0answers
18 views

Forward connecting IP address to KVM guests

I'm running kvm with iptables configured to use DNAT and masquerading. However the guest machines are logging the host bridge ip not the connecting client IP address. Is there a way to configure ...
0
votes
2answers
65 views

Portforwarding with IPTABLES and Remote IP detection

I was able to forward 80 port from my primary server 192.168.90.1 to the second one 192.168.90.2 with IPTABLES The primary server has a public address X.X.X.X so I forwarded X.X.X.X:80 -> ...
0
votes
2answers
50 views

Forward web request to another computer

I have one notebook and two servers: ip = 172.17.0.2 (I have installed nginx here) ip = 172.17.0.3 (There is nothing here, but I can ping 172.17.0.2 from here) I open browser on my notebook, open ...
2
votes
1answer
44 views

connected to Centos openvpn but no outside internet access

I am using Windows 7 to connect to a VPS server running CentOS 6.4 First off, I have read every single post and just cant find the solution to my problem I configured my VPN server with openvpn, and ...
2
votes
1answer
38 views

nmap lists host as up despite being black listed

I have an iptables rule setup that marks addresses as suspicious if they connect on certain ports or any unopen ports. If more than three consecutive connections are made without authentication, then ...
0
votes
1answer
56 views

Ubuntu 10.04LTS Server under attack, random reboots UNTIL I blocked China

What could have been sent to my server to cause it to reboot? Details: I have a for-internal-use LAMP server running Ubuntu 10.04LTS (upgrade is scheduled for that nebulous "when I have time"). It ...
0
votes
1answer
56 views

IPTables is blocking FTP for VMs

I have a CentOS 5 SolusVM Node setup and running. The VPS units are running fine and everything seems to be working. Until yesterday when I found no single VPS could be accessed through FTP. I checked ...
0
votes
1answer
29 views

IPTables cannot resolve dns [closed]

I'm running Debian 6 32Bit I finally just setup my iptables, but I cannot seem to connect to any external server from my box -A INPUT -i lo -j ACCEPT -A INPUT -p tcp -m tcp --dport 443 -j ACCEPT -A ...
0
votes
2answers
28 views

fail2ban rule results in “iptables returned 200” error message

I just tried to add a new fail2ban rule that is supposed to scan Apache2 error logs for suspicious file access attempts (People who try to access three common login urls that do not exist usually ...
1
vote
1answer
78 views

Ubuntu iptables logs not going to any log file

I am trying to put logs in iptables but I can not find any log in any file. Although when I run dmesg command, I can see the iptables entries. But the same entry doesn't go to any log file. Here is ...
0
votes
0answers
20 views

Can IPtables (possibly with libnetfilter_queue library) do everything that snort does?

I have just started getting into network security, firewall, etc. So, please excuse me for asking this basic question. I looked at IPtables and got a good hang of it (nowhere close to becoming an ...
0
votes
1answer
40 views

Adding port 25 to iptables won't getting to open centOS

I am facing a problem to open port 25 with iptables on my CentOS machine. I checked the connection by 'nmap' and 'telnet' but both failed. The follow things I did to trying make this work: iptables ...
0
votes
0answers
46 views

Can't run CSF on the host machine using Open VZ

I managed to configure CSF on my three VM inside OpenVZ, but when I try to run it on the host, all the VMs become unreachable. I can see that the host is been attacked, and it would be critical if it ...
0
votes
1answer
42 views

How to apply port forwarding with iptables on existing connections?

For load balancing purposes, occasionally our servers forward requests to a different port; The default port for our service is port 5000. This is the code used: iptables -t nat -A PREROUTING -p tcp ...
1
vote
2answers
28 views

iptables to block all but one port on PPP0

I have 2 dsl accounts. One is general use which is setup on my router and the second is setup on a server. My router is secured nicely, but I noticed after setting up PPPoe on my server that the ...
1
vote
1answer
70 views

iptables v1.4.7: option `state' requires an argument

Hi I'm trying to set IPTABLE rules and I get the error iptables v1.4.7: option `state' requires an argument when trying to issue. iptables -A FORWARD -m state --state RELATED,ESTABLISHED -j ACCEPT ...
2
votes
2answers
68 views

What are the security issues in creating a firewall between two subnets?

As I understand it, the hosts on different subnets cannot communicate with each other unless there is a router somewhere on both subnets that forwards traffic between them. I have have two subnets ...
3
votes
0answers
77 views

iptables/netfilter rules for samba/netbios access

Which iptables-rules do I have to set to allow clients to access a samba server with working netbios (i.e. being able to use \MyServer instead of \192.168.0.1 to access the server from Windows)? I've ...
1
vote
1answer
48 views

Scanning tagged traffic over bridge through iptables

I am working on bridge on linux box using brctl. Now I have to scan and monitor bridge traffic through iptables. So for the same I changed: net.bridge.bridge-nf-call-iptables = 0 to ...
2
votes
1answer
127 views

AWS WebServer architecture (ELB + iptables)

I'm currently working on the architecture of high-traffic high-availability website. We are using AWS. Currently, we have: Route 53 -> ELB -> Multiple EC2 instances -> RDS Multi AZ. Each EC2 ...
0
votes
0answers
33 views

enable user to connect to external pptp VPN server

I want to enable local user to connect to remote VPN server I added those rules to the iptables but still not able to connect -A OUTPUT -p gre -j ACCEPT -A OUTPUT -p tcp -m tcp --dport 1723 -j ACCEPT ...
1
vote
1answer
46 views

Logging in iptables

I have created rules in iptables to log and edited the rsyslog.conf file to output any message which contains "iptables" to a different log file. It seems that it is logging to both places, the ...
1
vote
0answers
99 views

Firewall/iptables rules for GlusterFS

A great pleasure would be to know which exact iptables rules to use for securing GlusterFS 3.4.2 (with Debian Wheezy) in shared environment. I'm running some dedicated servers at ISP. There are two ...
0
votes
0answers
56 views

Load-balancing PPTP connections

I'm trying to load balance two PPTP connections, connected to the same server. I use the following script, but there is no send and receive via PPTP connections. What part am I doing wrong? Are there ...
1
vote
2answers
42 views

Dynamically remove iptables policy by IP address

I would like to remove some NAT POSTROUTING rules in an automated fashion based on the source or destination IP address. I know the source and destination IP but I don't necessarily know which ...