iptables allow creation of rules to define packet filtering behavior.

learn more… | top users | synonyms

0
votes
0answers
10 views

Raspberry Pi OpenVPN SSH problem

I followed this tutorial to configure OpenVPN and it and runs very well: http://blog.frd.mn/raspberry-pi-vpn-gateway/ Now I want to access my Raspberry Pi via SSH. OpenVPN is most of the time ...
0
votes
1answer
1k views

iptables redirect traffic from VPN interface to next interface

Can you help me with this problem please? I need redirect all traffic from tun0 interface (OpenVPN tunnel) to eth1 interface. eth1 is internal network behind this system which works as special ...
0
votes
0answers
25 views

Use iptables to redirect **all* requests, even DNS-unsolved domain?

Context: With iptables, I redirect all the traffic - incoming at port 80 - to a distant server IP (X.X.X.X). I aim that anywhat you write in the urlbar of browser, you get X.X.X.X. IP That works ...
4
votes
1answer
53 views

forward all mysql traffic to a ssh tunnel

I have a local application that needs to connect to a remote mysql server at 40.40.40.40:3306 The main firewall blocks all connections but ssh, I can set up a ssh tunnel and connect to the server ...
1
vote
2answers
566 views

iptables - Redirect web traffic to LAN Server

I have a webserver which is running on ip address 192.168.11.100 How can i use iptables to redirect all web traffic (http and https) to my webserver on LAN? After that i want to add except list mac ...
1
vote
1answer
862 views

DROP all for port 22 if not geoip set of US for iptables and xtables

I want to simply block all ssh access from anywhere but with in the US. This is my whole iptables, and I have followed ...
1
vote
2answers
35 views

Using IPTables to Block Ports to Class A Subnets While Allowing Web Ports (80/443)

This is about a cPanel server which, like most servers, is under constant attack from lands afar. Considering that I only host to clients in the US and Canada, there is less of a reason to allow full ...
0
votes
1answer
584 views

iptables configuration for Transparent squid proxy

I have to setup a transparent squid proxy server using iptables and squid. Following is the scenario: [INTERNAL NETWORK] -> [Main Switch] -> [Proxy Server] -> [Firewall] -> [EXTERNAL ...
2
votes
1answer
17 views

Per user routing on wifi

I'm using vpn but i want to have one user that could access network not through vpn but using my real ip address. The problem is that all solutions i found by quick google'ing, for example this ...
1
vote
1answer
736 views

iptables allow only ssh and vpn traffic

I have dedicated server with ubuntu 14.10 installed. The server should connect to an openvpn server and the traffic should only go through the vpn, except for SSH traffic. My idea is to realize it ...
0
votes
1answer
100 views

How to unmask an IP with iptables?

Is there a way to unmask an IP using iptables? I know to mask all-in-one is following by: iptables -t nat -A -POSTROUTING -j MASQUERADE Thanks in advanced.
0
votes
1answer
31 views

iptables and ssh

I'm running Arch Linux and I have a running SSH daemon to access my machine when I'm out side my LAN. I can do the connection, but iptables keeps blocking SSH Daemon, so I can only connect if I turn ...
0
votes
1answer
13 views

iptables rules' weird behavior

I have a set of iptables rules (see below) whose purpose is to disallow traffic to go out of my machine when my VPN connection is abruptly lost or manually terminated: #!/bin/bash echo "Please wait ...
0
votes
0answers
6 views

RHEL 6 IPTables filtering of IPSEC protected Traffic

looking for some guidance to make sure I'm going in the right direction and maybe get some hints or gotcha's I need to be thinking about. I'm working on RHEL 6.4. I have a cluster of computers that ...
13
votes
4answers
7k views

Is there a way to find which iptables rule was responsible for dropping a packet?

I have a system that came with a firewall already in place. The firewall consists of over 1000 iptables rules. One of these rule is dropping packets I don't want dropped. (I know this because I did ...
3
votes
2answers
660 views

Policy routing with load balanced ppp connections

This my setup using Debian 6.0. 6. It's role is a proxy server and a load balancer using eight 3G modems. Whenever a ppp connection dials it takes over the default gateway which is ok but it also ...
0
votes
1answer
16 views

Default gateway is not reachable

I have a vmware player on which i have installed CentOS 6.5. And on that CentOS 6.5 i have installed lxc and on that lxc i have installed centos 6.3. I am using NAT and bridger as a Network adaptor ...
5
votes
1answer
785 views

What are the definitions of addrtype in iptables?

I am keen to use addrtype in combination with -src as a rule in one of my filter chain like so to drop some bogon ips: -A INPUT -p tcp --dport 80 -m addrtype --src-type UNICAST ! -s 127.0.0.0/8 -j ...
5
votes
0answers
36 views

Why doesn't NAT reserve ports from the machine's TCP and UDP port pool?

I made two experiments. This is the network for both of them: [private network] [public network] A -------------------- R ----------------- B 192.168.0.5 192.168.0.1|192.0.2.1 ...
1
vote
0answers
90 views

CSF not blocking port when removed from csf.conf

I have removed VNC port 5901 from the csf.conf configuration file and executed a csf -f a csf -x and a csf -e to flush and restart CSF. There is a vncserver running on port 5901 and when doing an ...
3
votes
1answer
27 views

Is it possible to reduce infomation in iptables log?

I noticed that there are data in the iptables log that I don't need, so I was wondering if it's possible to change some configuration so that the log has less information, reducing the log's size. ...
2
votes
1answer
50 views

Rewrite source IP in TCP replies using iptables

I'd like to rewrite the source IP on TCP/514 traffic leaving a redhat machine, for connections that weren't initiated from the machine. The machine receives TCP/514 traffic on an interface, for ...
1
vote
1answer
648 views

Bridged TAP interface to virtualbox

I need bridged TAP interface on client side of my VPN to virtual machine. I use VirtualBox 4.3.12. But in Adapter Network options in Attached to: Bridged adapter I do not see my TUN adapter. I have ...
3
votes
2answers
2k views

What is a solid iptables configuration for my desktop?

On my desktop, I want to configure iptables pretty strictly. I see no reason why I need to allow anything except for internet traffic that I initiated. And maybe even that could be limited to only a ...
4
votes
3answers
2k views

iptables multiple -d flags not allowed

I am trying to log all my outbound connections to a file using iptables. This is my rule: -A OUTPUT ! -o lo ! --destination 127.0.0.1 -m state --state NEW -j LOG --log-prefix "new_connection " ...
1
vote
2answers
2k views

ping: unknown host with iptables enabled

I can't ping www.google.com. However I can ping the IP address: ping 74.125.237.142 At first, I thought it is a problem with my DNS settings. But I checked my resolv.conf, hosts, and hostname ...
14
votes
4answers
10k views

Iptables to redirect DNS lookup IP and Port

I have discovered that my ISP (verizon) is intercepting all DNS traffic on port 53. Using iptables, I want to redirect all DNS lookup traffic to a specific IP and Port (5353). Any attempt for my ...
0
votes
0answers
40 views

server1 ssh's to server2 but server2 sees server1 by it's private ip due to both servers being on the same firm/network

I ssh into server1 via it's public IP from server2. I then ask server1 what my IP is. i.e. server2's IP. It shows me server2's private IP. I want it to show me server2's public IP. If server2 was ...
4
votes
3answers
59 views

Why do some TCP reset packets show up in my iptables log?

I started to add some basic iptables rules on my Debian Jessie server. My objective is to filter and log network traffic (for security and learning purposes). Disregarding ICMP packets, these are ...
0
votes
1answer
79 views

iptables - how to drop protocols [closed]

I have the desktop-server Debian Jessie machine running for testing purposes just for 19 hours now. I have already set a few rules as you can see above. But I am not really into networking. So it ...
0
votes
1answer
32 views

Apache VirtualHost redirect 302 (cyclic link)

I seek some wisdom, so please help... I have one VM acting as router/web server/dnsmasq server on IP: 192.168.100.1. And I have other machine acting as client. Server has IPTables rule to redirect ...
0
votes
0answers
18 views

iptables: block communication with others in same subnet

I have a couple of devices in my subnet (e.g. 192.168.0.0/24) and would like to make sure that one of these devices (identified by MAC or IP) can only talk via the router (where I'd like to set up ...
4
votes
3answers
1k views

Port fowarding and load balancer in ubuntu server 12.04

I am looking to create a load balancing server. Essentially here is what I want to do: I have a public IP address, lets say 1.1.1.1 I have a second public IP address, lets say 2.2.2.2. I have a ...
2
votes
2answers
2k views

Iptables GEOIP not working under Debian Squeeze

I've just installed xtables-*, compiled the geoip database, but when I try to use an iptables command it always gives back the following error: Command: iptables -I INPUT -p tcp --dport 80 -m geoip ...
9
votes
1answer
7k views

Linux as router with multiple internet providers

Linux as router: I have 3 Internet providers, each with its own modem. Provider1, which is gateway address 192.168.1.1 Connected to linux router eth1/192.168.1.2 Provider2, gateway address ...
1
vote
2answers
28 views

How to use routing to use the next available inetface

My system has 2 interfaces (eth0, eth1). I open a socket and bind it with an ip attached to eth0, now I want the OS to route the packets to another ip (which attached to eth1 but i'm not sure it's ...
2
votes
1answer
64 views

Who's messing with my router?

Recently, I've been feeling that somebody is doing bad things to my Access point. My wifi access point is "protected" with a hidden ssid, and a WPA2 password. Nobody granted access apart from me, ...
0
votes
0answers
39 views

How to build via iptables an transparent reverse proxy

I just use an Server with an public ip X.X.X.X to redirect without (changing the header ip) to another public ip Y.Y.Y.Y and the same back. My backend server is windows 2012 r2 and my proxy server is ...
0
votes
1answer
18 views

What does the numbers in brackets means on the iptables-save output?

What do the [368:102354], [0:0] and [92952:20764374] in my iptables output file mean? :INPUT ACCEPT [368:102354] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [92952:20764374]
1
vote
1answer
44 views

iptables - why do I get “Table does not exist (do you need to insmod?)”

I need to install some iptable ruels to block traffic that originates from a certain country, I found this script example on http://www.cyberciti.biz/faq/block-entier-country-using-iptables/ it works ...
0
votes
1answer
732 views

Port Forward :80 and :8080 to Two Different Servers

On a CentOS 6 server with an IP address of 172.16.1.10, how can I configure iptables to route traffic destined for 172.16.1.10:80 to 192.168.1.10:80, and traffic destined for 172.16.1.10:8080 to ...
2
votes
1answer
32 views

Iptables rule to drop packets to and from local network

I want to set a virtual machine on laptop, but I don't trust the guest system fully, so I would like to block it's access to local network (to network 192.168.0.1/16 or 10.0.0.1/8 or ... the other one ...
0
votes
2answers
1k views

Route wlan0 to openVPN tunnel and rest to eth0

I'm having problems to create route/iptables rules for following configuration: I have an openVPN server (tun type) running on my raspberry machine at home At work i have company pc (behind proxy) ...
1
vote
1answer
23 views

installed application keeps open port

I installed an application (a text editor) and it keeps a connection alive. I blocked the IP with iptables, but the port stays open. netstat shows: tcp 0 0 127.0.0.1:<port> 0.0.0.0:* ...
0
votes
0answers
26 views

openvpn: iptables not forwarding

I have the following topology: And I'm following the iptables rules listed on https://community.openvpn.net/openvpn/wiki/BridgingAndRouting Here's the output of iptables -L -v Chain INPUT (policy ...
2
votes
1answer
67 views

Local port is not accessible with public IP address

I have a linux server which has public IP and Private IP. So, when ever I login with public IP, the terminal directly shows private IP. example: $ ssh root@55.27.XX.XX root's password: ...
1
vote
0answers
17 views

Routing only VM traffic through VPN

I'm stuck on a problem and would like some help if possible :-) My goal is to make my VM going through my VPN connection and my HOST through the standard gateway. Configuration : VM (192.168.100.1) ...
2
votes
1answer
93 views

On a router, what decides if a packet should be forwarded or directed into the router itself?

I'm trying to learn how packet routing works on a linux-based router (OpenWRT in my case) a bit better for setting up a few projects/just-learning. Referencing the below chart, I'll break this into ...
3
votes
2answers
1k views

Open and redirect port

I'm trying to set up SNMP for a router so I can monitor it from an existing Nagios installation on an off-site server. I'm having trouble getting the router to respond to SNMP requests from the WAN, ...
2
votes
1answer
48 views

iptables rule in /etc/rc.local are not loaded

/etc/iptables.conf contains a rule to dump my outgoing packets to 10.199 network as, *filter :INPUT ACCEPT [122:9273] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [73:8165] -A OUTPUT -d 10.199.48.0/24 -j ...