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

0
votes
0answers
68 views

iptables not forwarding vbox traffic

I have a vbox vm that i would like to give unfettered internet access to, and i have found instructions on how to properly forward traffic using iptables, as well as the recommendation that the vm ...
0
votes
1answer
43 views

why iptables is accepting all in INPUT?

As we can see in this, which is the default iptables on fedora 20 $ iptables -L INPUT --line-number Chain INPUT (policy ACCEPT) num target prot opt source destination 1 ...
0
votes
0answers
31 views

A more complex iptables rule

I want to make a script that sees if a number of connection attempts are made from one or more IPs ($CT_MULTIPLE_IP_THRESHOLD) in an ammount of time ($CT_TIME). If this happens, than in that ammount ...
1
vote
1answer
108 views

How to transparently tunnel a port from IPv4 to a remote IPv6 device?

At home, I am connected with an IPv6 address and additionally, my provider provides a NAT-like setup through which I receive a public IPv4 address that I share with other customers (the reason being ...
0
votes
1answer
258 views

What does this iptables rule mean: tcp flags:0x06/0x02 TCPMSS clamp to PMTU?

What does this iptables rule mean: tcp flags:0x06/0x02 TCPMSS clamp to PMTU? Doing iptables -vnL on my DD-WRT router shows the following rule in the FORWARD chain: TCPMSS tcp -- * * 0.0.0.0/0 ...
0
votes
1answer
171 views

How to create a local-remote-local tunnel to a specific port using ssh

I'm able to establish an ssh connection from my windows computer (localhost - eth1) to my linux computer (remotehost - eth0) by doing: ssh user@192.168.1.100 Instead of using that, because I use ...
0
votes
2answers
110 views

Is Iptables blocking outgoing ssh connections?

I have been trying to do pulls from github and it keeps hanging. My iptables rules have no rules which block outgoing traffic but I cannot connect to github using either ssh or http. I can't even ...
0
votes
0answers
132 views

Access to a NATed LAN Network without public ip address using VPN and Apache Virtual Host

my question is: I need to access from the outside to a DVR that in my LAN has the local ip: 192.168.1.x I have multiple LANs located in 3 different places not connected each other at the moment. I am ...
0
votes
0answers
197 views

Why does iptables suddenly stop properly forwarding packets?

My home network consists of a desktop PC running Slackware 64 [192.168.1.10]. My Windows PC [192.168.1.20] is routed through the Slackware PC via a direct ethernet connection. In addition to iptables, ...
1
vote
1answer
54 views

Forwarding all traffic to other server with iptables

Assume I have a sever with X.X.X.X IP address and a web server with Y.Y.Y.Y IP address. How would I forward web traffic from X.X.X.X to Y.Y.Y.Y using iptables? My servers run Linux and use iptables
2
votes
1answer
28 views

When writing an iptables save file by hand, how does one calculate the packet-counter and byte-counter values?

I am attempting to write a 22MB iptables rule-set file, the very kind that is generated with the iptables-save command, except endlessly long. Understandably, this takes a prohibitive amount of time. ...
0
votes
1answer
120 views

IPTABLES forward all ports except ssh

I have nat and packet routing working just fine, but I'd like to forward all ports except SSH to a static ip(192.168.0.3) What would be the correct iptables syntax to do this?
0
votes
1answer
622 views

Forwarding all incoming traffic on eth0 to go to eth1

I am trying to setup my raspberry pi to sit between my router and my modem. I'm basically trying to set it up as an intercepting proxy so that all web traffic goes through the proxy. I have the ...
2
votes
0answers
560 views

Route outgoing VPN traffic through local transparent proxy

I have a Digital Ocean droplet (similar to an Amazon EC2 instance) running Ubuntu Server 12.04.3 x64 with both strongswan 5.1.1 (built from source) and squid 3.4.2 (also built from source) installed. ...
1
vote
1answer
165 views

bind/named not working on UDP from external

This one is weird. I've set this up a long while ago, on a centos5. From what I remember, it used to work. For some time now, it's not. I've just been informed so no clue what changed when that made ...
1
vote
1answer
68 views

iptables password protection followup

This is a follow up on my other post about this iptables: plaintext password protection I could not get help in the old topic...I just really need some help... Here is the command I tried, something ...
1
vote
1answer
89 views

Use IPTables to force TCP packets over router

To test a TCP-stack program, I need to get the TCP packets via the router. When I try to connect to my server program via the router, the OS does not hit the router as the destination IP is the same ...
0
votes
3answers
256 views

How to configure iptables correctly

I'm a newbie to linux.I just implemented the following commands in iptables which I found on a site for security (i don't understand much about how each rule works). The commands are as follows: ...
0
votes
1answer
72 views

Per application rules in iptable

Is there possibility to add rule via iptable for specific process name? Good explanation of why I need it is here: "Under Windows, this helps making the PC more secure. There are many ...
1
vote
2answers
103 views

Connecting to an SSH server behind a NAT

I am having trouble connecting to an SSH server behind a NAT on an ubuntu workstation. I've installed openssh package(both the client and the server) and forwarded port 22 through the NAT and tried to ...
1
vote
2answers
284 views

Is selective VPN routing worth it?

I want to setup routing tables on my RT-N66U router to selectively route traffic through a VPN. For instance, only Pandora requests would go via the VPN. I've found a way to do this with iptables: ...
0
votes
0answers
35 views

how to keep counters on iptables rule replace ?

When replacing a rule (by it's number), the counters also get reset. I can think of a scripting solution, though on very high traffic, this loses packets. Is there a way to keep the counters up? For ...
0
votes
1answer
95 views

Routing traffic over Vpn without NAT?

I want to tunnel traffic through my vpn but I just realized that my kernel does not have nat enabled ;( iptables -t nat -A POSTROUTING -s 10.20.0.0/24 -o eth0 -j MASQUERADE iptables v1.4.14: can't ...
0
votes
1answer
159 views

How do I block every connection except vpn and ssh without endangering the state of my vps?

I have some vps space but I get alot of scans based on what I see in iftop. I tried some iptables stuff but it gets tiring and useless to put all the ips that I see in the logs. I am wondering about ...
1
vote
0answers
89 views

“iptables -P OUTPUT DROP” blocks DDWRT's web interface

When I do iptables -P OUTPUT DROP it blocks DDWRT's web interface. That is I am not able to access http://192.168.1.1 via Firefox. I put this rules before changing the chain policy to drop: ...
0
votes
0answers
81 views

unable to configure nat on centos 6.4

i have configured nat on my centos 6.4 on vmware workstation with the following cofiguration i have two ethernet adapters eth0 and eth1 eth0 has public ip automatically taken by dhcp eth1 has private ...
1
vote
0answers
150 views

using iptables to filter vboxnet (virtualbox host only network)

Im trying to use iptables to filter the traffic coming from a guest OS running on virtualbox. The guest is configured to use a host only adapter for the network, and my Ubuntu host is configured to ...
0
votes
0answers
92 views

Why does iptables restart cause connectivity timeout for about a minute?

I have a centos 6.5 64bit router with 3 nics. The box is configured to route 2 networks. netA - eth1 [ about 10 clients ] netB - eth2 [ about 100 clients ] provider - eth0 [ fiber to isp ] I have a ...
0
votes
1answer
133 views

UFW default rules… where are they?

In the tutorial on UFW here https://help.ubuntu.com/community/UFW it says that UFW uses the default rules if enabled and not configured. I checked the folder: /etc/ufw/ and the files I found ...
0
votes
1answer
190 views

IPTables and Port redirection Apache2

I'm using Apache to redirect a subdomain to a port (mod_proxy, mod_proxy_http, mod_proxy_ajp) and IP Tables to restrict direct port access except to me and the local server. My IP Tables looks like ...
0
votes
0answers
29 views

Redirect clients to portal web page

May I know the iptables command in Ubuntu 12.04 LTS (act as gateway) to re-direct clients to the portal web page. Currently I'm using this command but seems it doesn't work. sudo iptables -t nat -A ...
0
votes
0answers
87 views

client still cannot get internet access from gateway pc

I have already set up a laptop as a gateway in ubuntu 12.04. with 2 interface cards. internet >> eth0 >> gateway pc >> eth1 >> Access Point for eth0 IP dhcp for eth1 Static Ip 192.168.5.1 Access ...
0
votes
0answers
31 views

Need help changing where iptables logs to

I'm writing a program that needs to read in and look at the iptables log file. I know how to write rules for iptables and to make it log, but by default it logs to kernel.log. Is there a way to make ...
0
votes
0answers
18 views

Masquerade in both directions [duplicate]

I have a two networks that I need to link in two directions. network A 10.11.0.0/24 - and its gateway 10.11.0.1 network B 10.0.0.0/24 network B has a server (10.0.0.38) that is connected to the ...
0
votes
1answer
59 views

Bidirectional two networks link

I have a two networks that I need to link in two directions. network A 10.11.0.0/24 - and its gateway 10.11.0.1 network B 10.0.0.0/24 network B has a VPN server (10.0.0.38) that is doing a ...
0
votes
1answer
29 views

Setting up Debian local server on specific port

I'm trying to set up a local web server using the port 8000 to be accessed from an internal LAN network in order to test a web application. The problem is I'm not sure how to do it. I created two ...
0
votes
3answers
173 views

Temporary iptables changes

I have a remote system that I SSH. Since I am planning to make this system more publicly accessible, I want to improve my iptables rules over the current policy of accepting anything. I have added a ...
1
vote
1answer
115 views

iptables detects clients behind NAT?

I'm setting up a server that I want to protect from DoS attacks, by setting a limit using iptables: iptables -A INPUT -p tcp --dport 80 -m limit --limit 25/minute --limit-burst 100 -j ACCEPT (default ...
0
votes
1answer
8 views

Is there a way to see when iptables was last changed?

Is there a way to see when iptables was last changed? I'm running CentOS5. I found this morning that the configuration is different from what I set 6 months ago.
1
vote
2answers
590 views

Route traffic through VPN to some IPs occasionally

I would like to route traffic to some specific addresses through VPN. Easy enough, one can simply add a route: ip route add <destination ip> dev tun0 scope link Here comes the catch: I do not ...
1
vote
1answer
148 views

How to block incoming traffic on a virtual interface?

How do I block all incoming traffic on eth0:0 but keep eth0 open? What I've tried is this: iptables -P INPUT DROP iptables -A INPUT -i lo -j ACCEPT iptables -A INPUT -i eth0 -j ACCEPT But this ...
0
votes
0answers
91 views

Ping through GRE tunnel discarded between 2 interfaces of a router - Ping does not reach subnet

I have an interesting issue that I hope someone can help with. I am trying to create a GRE tunnel between 2 routers (running Linux Ubuntu 12.04) and pass traffic between 2 subnets trough this tunnel. ...
0
votes
2answers
128 views

is there an iptables rule to allow only email on port 25?

Is there a way to block port 25 for everything but mail communication? Had no luck finding an answer to this yet. Maybe it's possible to block every application but those related to above usage? I am ...
2
votes
1answer
111 views

How does uTorrent can automatically forward port through Linux Net Filter based firewall?

I have dilemma: How it is possible that uTorrent shows on my internal machine with internal IP, that my connection is OK (green check in the bottom right of its window), while I never forwarded any ...
0
votes
1answer
79 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 ...
1
vote
1answer
92 views

excluding port from VPN client

I use hidemyass which is a vpn service. I use it for privacy reasons. The main purpose of the VPN is for my web browsing. How can I exclude certain ports from using the VPN connection? For example: ...
1
vote
2answers
218 views

Why nic with incorrect subnet mask can still ping the gate way?

At first, my network config was like this: $ ip a 2: em1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 3c:97:0e:bd:b1:68 brd ff:ff:ff:ff:ff:ff ...
-1
votes
1answer
241 views

Iptables: allow wget

for some reason the following rules block wget. iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT iptables -A INPUT -p tcp --dport 80 -j ACCEPT iptables -A INPUT -p tcp ...
1
vote
1answer
145 views

Iptables limit user access time and mac

I am trying to create an iptable chain to kick my daughter off her ipad during the night. With the mac only filter I can block access but when I add time it no longer works. Does anyone see an issue ...
0
votes
3answers
135 views

Show a default page after connecting to WIFI LAN

I have the following setup at home: |--------------------| INTERNET ---- | GATEWAY COMPUTER | ----- WIRELESS ROUTER )))))) CLIENT 10.10.0.2 ...