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

5
votes
1answer
1k views

IPv4, IPv6 and IPTables

I have just recently learned that even if I block all traffic to my webserver using iptables it is still vulnerable to external attacks via IPv6. In my understanding, this renders iptables-only ...
0
votes
1answer
94 views

NATing with a single-homed machine possible?

I have the following setup: a) a single-homed machine, A, that can see the Internet. b) other machines B, C, and D that cannot see the Internet. c) A, B, C, and D can see each other. d) all ...
0
votes
1answer
200 views

How to read iptables -L output?

I'm rather new to iptables, and I'm trying to understand its output. I tried to RTFM, but to no avail when it comes to little details like these. When iptables -vnL gives me a line such as: Chain ...
1
vote
1answer
2k views

Port forwarding with IPTABLES and VBox

I have a small problem with getting a proper configuration of iptables under Ubuntu. But before, let me describe the network configuration: I am using xDSL line terminated with modem+router+DHCP ...
0
votes
2answers
2k views

Implementing a global proxy with iptables

I'm running a Linux box (Lubuntu 12.04) in an Windows environment where a pac file is used to configure internet access. proxy.pac file: function FindProxyForURL(url, host){ var proxy_yes = "PROXY ...
2
votes
1answer
4k views

Deny all incoming connections with iptables?

I want to make some simple iptables rules to deny all incoming connections and allow outgoing. How can I do that?
0
votes
1answer
314 views

How to setup IPtables to allow capture network traffic from a virtualbox VM configured with NAT

I would like to have a VirtualBox virtual machine that can't get online. I want to be able to monitor all network traffic attempts from the Linux host. So, if the virtual machine attempts to make a ...
1
vote
1answer
812 views

linux drops packet when trying to route it - why?

I track packets using LOG targets for all chains of all tables and the last chain I see my packet in is the POSTROUTING chain of the mangle table: mangle_PREROUTING: IN=eth0 OUT= ...
0
votes
1answer
199 views

Using my previous desktop computer as custom ubuntu router, will throughput be high?

I'm going to be redoing my home network soon and am thinking of using a dedicated ubuntu machine to use as the router/firewall as well as being a web server, nas (media file server), dns, wifi, and ...
1
vote
2answers
5k views

How to alias an IP address to make DLNA resource accessible from different IP network

what I have I have a home wifi network 192.168.1.0/24 having DLNA resource 192.168.1.100. I have a TV with ethernet and a netbook with both wifi and ethernet interfaces. I want to make my notebook ...
7
votes
1answer
2k views

iptables vs route

What's the difference between these two tools? Can anybody tell me what the main workflow of networking behind Linux (in relation to IPv4 packet filtering, NAT and IP routing table) is?
1
vote
0answers
679 views

Internet Connection Sharing bypassing MAC Filter in Ubuntu Linux

My university gives me an internet connection by Ethernet, DHCP but they have installed MAC Filtering to allow only using my PC. I have a wireless router TL-WR340GD. which has MAC address cloning ...
0
votes
1answer
66 views

Regulate outgoing ip traffic on a VM

I am making a virtual network setup for my high school cybersecurity team to practice. I am connecting all the VMs together through a VPN and then people who are practicing will VPN in and ssh/remote ...
0
votes
1answer
115 views

Mark packets across computers?

I use Transmission on Ubuntu and I'm having this issue, which basically says that QoS is broken because there is no way to limit which outgoing ports uses. I was thinking of doing a dirty and ugly ...
0
votes
1answer
231 views

Push local traffic “outside” the nat

I have a server functioning as my nat that hosts some services. When I locally connect via UDP to this server it my client uses the public ip but the server answers with its local ip. So the question ...
3
votes
1answer
2k views

Allow access from outside network with dmz and iptables

I'm having a problem with my home network. So my setup is like this: In my Router (using Ubuntu desktop v11.04), I installed squid proxy as my transparent proxy. So I would like to use dyndns ...
0
votes
1answer
717 views

Linux, how to force all traffic to specific host over VPN?

I'm trying to ensure that all traffic to our stats server is forced over the VPN, in the case that the VPN falls down, it shouldn't be that the traffic tries to route over the WAN. To short-circuit ...
5
votes
2answers
5k views

How to negate a range in iptables?

I've seen people use the exclamation mark (!) in multiple examples, but when I try to use it I get an error. The rule I'm trying: -A OUTPUT -m owner --gid-owner 1006 -d ! 192.168.1.0/24 -j DROP The ...
0
votes
1answer
2k views

iptables trouble: nat with ip alias (virtual interface) not working

I'm setting up an Ubuntu 11.10 server to act as firewall for a network running several different SSL websites. The idea is fairly common: have all public IP's for each site aliased to the public ...
1
vote
0answers
688 views

Iptables port redirecting. Rule doesn't work or show up in iptabels

I'm trying to redirect some incoming TCP traffic on port 443 to port 999 with iptables in an Ubuntu VM. I am using sudo iptables -t nat -A PREROUTING -p tcp --destination-port 443 -j REDIRECT ...
1
vote
0answers
540 views

SSH login with secure IP VPN

I have a PC behind a router with port forwarding setup Port 22 for SSH which works perfectly - I can login and everything. What I am trying to do is let this PC connect to a VPN and only allow ...
0
votes
0answers
407 views

filtering Internet traffic and caching on another machine using a dd-wrt router

In my home network, I have a spare machine which I would like to configure to filter Internet traffic (block ads) as well as cache content. I would like to tell my DD-WRT router to pass all Internet ...
1
vote
0answers
94 views

Portforwarding to VM doesnt work.. anymore

I have a windows 2k8 server vm on my Ubuntuserver which I use for i.e terraria & apache. It was working great before a little minor accident when the electricity stopped flowing through the cables ...
2
votes
1answer
186 views

Secondary NIC: what all can I do?

I was loaned a NIC which I promptly installed in my F16 workstation just to 'play' with it (using iptables and stuff). Other than forwarding packets from the new NIC to the old NIC using various ...
3
votes
2answers
4k views

How to blacklist IPs on Windows 7?

I'm trying to find something similar to iptables in Linux for Windows. I've tried using Windows firewall as well as editing the host file to block specific IPs, but had no success. I've also tried ...
-2
votes
1answer
399 views

Open a linux port without using iptables in Centos? [closed]

just a quick question, is it possible to open a port on linux Centos without using iptables? If so, how do I do that from the command line?
0
votes
2answers
2k views

IPtables: Blocking all traffic on an interface except select ports

I have four interfaces on my system (eth0, eth1, eth2, and eth3). I want to block all incoming and outgoing traffic on eth2 except for port 80 and 443, although I'm only worrying about 80 right now. ...
3
votes
1answer
2k views

Why is this iptables rule that does port forwarding not working?

I have a server bound to localhost:7060. It is using ipv6 socket instead of ipv4. Below is netstat outout. # netstat -an Proto Recv-Q Send-Q Local Address Foreign Address State tcp ...
0
votes
2answers
664 views

How to drop traffic before it hits existing iptables conntrack rule?

I am running an application that injects iptables connection tracking rules into the kernel so the machine can forward incoming UDP traffic to its destination as fast as possible. Some of the ...
0
votes
2answers
290 views

In Linux can I direct all traffic from a specific ip address or mac address to file

In Linux can I direct all traffic from a specific ip address or mac address to file. I am look of a way to take all traffic from a specific ip address or mac address and put it into a file. Does ...
10
votes
3answers
10k views

How can I check if an iptables rule already exists?

I need to add a rule to iptables to block connections to a tcp port from the Internet. Since my script may be called multiple times and there is not a script to delete the rule, I want to check if ...
5
votes
2answers
3k views

Blocking Skype using snort and iptables

I am trying to block Skype using snort and iptables. I read a lot of papers and blocked the port, keywords and patterns which Skype uses. But it is still not blocked. My question is: if Skype uses ...
5
votes
5answers
4k views

How to block sites with iptables

I would like to block sites using iptables. How do I go about this, and how do I ensure that the iptables rules are saved?
0
votes
1answer
381 views

How can a PPTD VPN route traffic to other servers on network?

I a have a number of servers which expose various public services to the web. These are behind a server which is acting as a firewall using IPTables and forwards traffic to and from the servers. All ...
6
votes
2answers
7k views

Setup routing and iptables for new VPN connection to redirect **only** ports 80 and 443

I have a new VPN connection (using openvpn) to allow me to route around some ISP restrictions. Whilst it is working fine, it is taking all the traffic over the vpn. This is causing me issues for ...
1
vote
2answers
752 views

Firestarter device not ready when booting Ubuntu

I am trying to get firestarter running on Ubuntu 11.10 and I am getting an error: Failed to start Firewall The device eth1 is not ready. Please check your network device settings and make sure ...
1
vote
1answer
3k views

Ubuntu 11.10 firewall/gateway - no client internet access

I have read many other posts but cannot figure this out. eth0 is my external connected to a Comcast modem. The server has internet access with no issues. eth1 is internal and running DHCP for the ...
4
votes
1answer
5k views

How to use iptables to forward all data from an IP to a Virtual Machine

OK, in an attempt to get some response, a TL;DR version. I know that the following command: iptables -A PREROUTING -t nat -i eth0 --dport 80 --source 1.1.1.1 -j REDIRECT --to-port 8080 ... will ...
1
vote
1answer
297 views

iptables Settings as WAN Input for Router

I have an eee running ArchLinux with wireless access to the Internet. I want to use it as the WAN input for an Asus RT-G32 router into which it is hardwired. The router in turn is hooked up to a ...
0
votes
1answer
1k views

will the left|rightfirewall option of StrongSwan open UDP 500/4500 and protocol number 50 on iptable?

I know the StrongSwan use UDP 500 and 4500 for IKE traffic and IP protocal number 50 for ESP packages. I am not sure the usage of left|rightfirewall ...
0
votes
1answer
196 views

conectivity problem

I have 2 PCs (anuin and hed), both running Linux that are connected via ethernet (192.168.1.1 and 192.168.1.3). Both PCs can ping each other. anuin is connected to the internet via an USB-stick ...
0
votes
3answers
81 views

Chaining subnet fails

Is it possible to do the following: Machine1 Kubuntu 8.04 desktop wired internet Cable modem Machine2 eepc701 Xubuntu 1O.04 wired machine1 cross ethernet cable Machine3 nokia n900 wireless to ...
0
votes
1answer
2k views

Remove port aliases in iptables

How can I make iptables show me port numbers instead of aliases for well known port numbers (eg. http for 80, https for 443 etc.). Is there a way to make it show just port numbers at all times?
0
votes
1answer
699 views

iptables + vpnc + Cisco IP Phone 7941

I have a Linux gateway with kernel 2.6.39 connected to a Cisco ASA 5500 with vpnc. I'm using iptables with masquerading and forwarding to give the LAN access to the tun0 device connected to the VPN. ...
3
votes
1answer
371 views

Why small TCP connections succeeds, but big ones fails?

Sometimes from Linux system I see the following weird behaviour: I able to ping things and sometimes use some services, but networking is very bad. For example, now I routed connection through my ...
1
vote
0answers
98 views

How can I restrict my Virtual Machine using an iptables rule?

I am using CentOS Linux and am planning to setup a rule on my VM's iptable. I want to restrict all outgoing and incoming packets to the VM for a temporary period and allow only the DHCP packet to ...
0
votes
1answer
3k views

How do I block all ports except 22 and 80 in Fedora's iptables? [duplicate]

I am trying to only allow port 22 TCP/UDP and port 80 TCP/UDP from anywhere using Fedora 15 iptables, and all the rest will be never accessible nor scannable from a public network. But it never ...
0
votes
2answers
125 views

iptables ACCEPT policy

In Redhat EL 6, iptables INPUT policy is ACCEPT but INPUT chain has REJECT entry in the end. /etc/syconfig/iptables is as below: *filter :INPUT ACCEPT [0:0] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [0:0] ...
2
votes
1answer
4k views

DD-WRT Setting Up Guest Network

I have a router on which I installed DD-WRT firmware. I am trying to set up a virtual interface to use as a guest network. The guest network should be on the 192.168.8.0/24 subnet while our LAN is ...
0
votes
2answers
225 views

Blocking a botting URL to an Linux server running Apache

I have a webserver running OpenSUSE 11.1 and I need to block a URL. The reason I want to block a URL is because it seems to have a different IP address all the time, but the URL stays the same. I'd ...