iptables allow creation of rules to define packet filtering behavior.

learn more… | top users | synonyms

1
vote
1answer
659 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
1answer
461 views

port forwarding to internal lan server

I've ppp0 --> eth1 and eth0 (internal lan). I need forwarding externel 10022 port to port 8999 of the server 192.168.1.254 iptables -t nat -A PREROUTING -p tcp -i ppp0 --dport 10022 -j DNAT --to ...
0
votes
0answers
18 views

“iptables -L” isn't showing a rule I just added

I have issue with iptables it's not listing any newly added IPs. I tried both: iptables -A INPUT -s 188.143.232.15 -j DROP and iptables -I INPUT -s 188.143.232.15 -j DROP and service iptables ...
1
vote
1answer
12 views

Allow ftp out through iptables

I have been having difficulty allowing ftp through iptables. Right now my ftp looks like this. Chain INPUT (policy DROP) target prot opt source destination ACCEPT tcp ...
1
vote
1answer
516 views

Randomize external port when doing NAT with iptables

I want to configure a NAT behavior different from the default one implemented by iptables. In this example: iptables -t nat -A POSTROUTING -o eth1 -j SNAT --to-source 193.49.142.107:2000-400 The ...
2
votes
3answers
3k views

How to change user agent on all http requests made from my machine with Squid intercepting proxy?

I'd like to change the user agent on all HTTP requests made from this machine. It's easy enough to change the user agent in each browser, but other apps also make http requests. It's vital I catch ...
1
vote
0answers
13 views

Valid iptables Firewall on DD-WRT to access Internet on a Virtual Access Point

Device: Linksys WRT54G v5.1 Firmware: DD-WRT v24-sp2 (07/22/09) micro - build 12548M NEWD Eko I use this router as an AP with 2 SSIDs (Private wl0 + Guest wl0.1) and I connect it to a switch ...
1
vote
1answer
36 views

What is blocking: Firewall and tcpwrapper?

Is it possible to find whether firewall(Iptable) or tcpwrapper is blocking a connection without accessing the remote server? (tcpdump?) Thank you,
4
votes
2answers
108 views

Did this tutorial block pings to my server?

I am a programmer teaching myself linux admin stuff. I followed this tutorial to setup a firewall on a VPS. As a part of that tutorial, I block all traffic except for web traffic and SSH traffic. I ...
1
vote
0answers
58 views

Port forwarding with iptables and PIA VPN for single user

I've gotten a Private Internet Access VPN setup on a Mythbuntu 14.04 machine and I am at wits end trying to get port forwarding working with rTorrent (and ruTorrent). My setup is rTorrent running ...
0
votes
0answers
18 views

Fedora 21 Port Forwarding with firewalld (firewall-cmd); how does it REALLY work? Or, does it?

Fedora's ability to forward ports using the apparently "native" networking software, firewalld, appears to continue to be broken beyond credulity. Please note that it hasn't really worked since at ...
1
vote
0answers
41 views

Redirect all ARP traffic from eth0 to eth1

I would like to redirect ARP traffic, but I'm struggling with arptables and ebtables. I have 2 interfaces: eth0 10.10.10.25 eth1 10.10.10.20 Both in 10.10.10.0/24 I want to redirect the ARP ...
1
vote
0answers
30 views

Linux - iptables - get YouTube streaming bytes usage

How do I get bytes usage using iptables for a particular IP, including YouTube streaming videos? Currently, I am using the following IP tables rules to get data usage by IP address: sudo iptables -I ...
0
votes
2answers
25 views

IPtables errors

I am working on a project. I am trying to write iptables rules to control network traffic. I have written some rules. When I try to apply them to the boxes that I am working on I either get locked ...
4
votes
2answers
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 ...
0
votes
1answer
924 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 ...
1
vote
1answer
24 views

linux nat different rules

eth0 (192.168.1.0/24) --> wan eth2 (192.168.10.0/24) --> lan0 I use these rules to enable NAT on my linux gateway: iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE iptables -A FORWARD -i ...
0
votes
0answers
63 views

How can I redirect internet traffic from local to proxy server with ip tables (DEBIAN 6)

So i made topology as shown in figure. Router have 3 interfaces like this: eth0 to internet side (with ip 192.168.1.10/24 gateway 192.168.1.254/24). eth1 to server-PC side (with ip ...
24
votes
5answers
5k views

Block network access of a process?

Is it possible to block the (outgoing) network access of a single process?
1
vote
0answers
29 views

Route wireless LAN through OpenVPN

I am trying to set up my home server to act as an OpenVPN gateway so I can connect to my VPN from any device without installing special software of them. My server is running Ubuntu 14.04. The host ...
1
vote
0answers
14 views

How to route vpn traffic over hostapd-raspberry pi

I have a raspberry pi running hostapd and I am able to connect my laptop as a wifi client to the raspberry bi wifi router. The problem is with the vpn traffic, I cant connect to my office vpn with ...
1
vote
1answer
14 views

iptables drop policy

Audit my rules I'm ask if I really need of two INPUT policy: iptables -P INPUT ACCEPT iptables -F iptables -A INPUT -i lo -j ACCEPT iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT ...
5
votes
1answer
549 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 ...
0
votes
0answers
13 views

Why does my PPTP connection work if I DMZ the server behind the router, but it does work if I use port forwarding?

Why does my PPTP connection work if I DMZ the server behind the router, but it does not work if I use port forwarding for the wide area network? Is there another port I need to open/port forward ...
0
votes
0answers
28 views

How to forward range ports in my linux server?

Is there any tools to do range port forwarding in my CentOS system? Just like any ports from 8000 to 9000 shoud be forwarded another IP's 8000~9000 respectively. I know it's easy to be done in Router ...
2
votes
1answer
51 views

Is iptables -p proto -m proto redundant?

I keep seeing "-p tcp -m tcp" all over the place, but it looks redundant. Why the '-m' if the '-p' already matches the protocol?
1
vote
0answers
32 views

iptables not getting saved ? centos

I am trying to save the iptables, when I run command #service iptables save it says [ok] but when I again open the iptables the rules get revert to default. Can anyone help me to understand this ...
-1
votes
0answers
13 views

-m owner --uid-owner

Please point out to me if -m owner --uid-owner spring can be used in the following rules: (1) iptables -A OUTPUT -o lo -m owner --uid-owner spring -j ACCEPT (2) iptables -A OUTPUT -o eth0 -m ...
1
vote
0answers
21 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 ...
0
votes
1answer
25 views

mount times out with iptables --policy OUTPUT DROP

I previously ACCEPTed all output traffic by default. Recently changed the policy to DENY output by default, only opening ports needed for server/application functionality. When I tried to mount a ...
0
votes
0answers
55 views

CentOS as home network router: IPTables Port Forwarding failure

I have currently set up a home server with a CentOS 6.6 installation on it. The server has two NIC interfaces which I'm using it as my router and DHCP server. Here's a diagram showing the network ...
0
votes
1answer
34 views

DDOS defence with iptables

I have server with Debian 6 with a many games servers and sadly, I'm getting ddosed. So, there is my ask for help. I want make solid firewall, where my server will safe.
1
vote
1answer
454 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 ...
2
votes
1answer
34 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 ...
6
votes
3answers
11k views

iptables redirect outside requests to 127.0.0.1

I have a service running on 127.0.0.1 with port 2222. I need to forward all requests to 192.168.2.2:2222 (outside IP) only from subnet 192.168.1.0/24 to 127.0.0.1:2222. I'm trying to use this, but ...
1
vote
3answers
60 views

how to automate creating firewall rules?

There is a complex live system - few vlans. In each of them there are linux servers, and on every server there are services. Services connect together - for example service http on host A connect to ...
2
votes
2answers
56 views

Is it possible to have multiple virtual machines with the same (guest) ip on the same host?

What I try to achieve: Multiple virtual machines (virtualbox) on a Debian host which communicate with another server (not with each other or the host). All VMs need to have the same static network ...
1
vote
1answer
30 views

Does NAT allow accessing internal network (or router's local interface) from outisde by default?

I am using older SOHO router wl500gP (it is v1 but I think this is not important) with custom Oleg firmware. My topology looks like this: 192.168.3.3 192.168.3.2 NAT 192.168.2.1 ...
1
vote
1answer
49 views

iptables allow INPUT from a specific url

I'm using DD-WRT, and can telnet into it to add iptable rules. I'm looking for a rule that will allow IN from a specific address (say, mydomain.com) on port 80 that will point to an internal IP (say, ...
3
votes
4answers
1k views

Can't add large number of rules to iptables

I made a very simple bash script (echo at start, runs commands, echos at end) to add approx 7300 rules to iptables blocking much of China and Russia, however it gets through adding approximately 400 ...
0
votes
2answers
38 views

output in iptables

I have added the rule to iptables file, however the command does not show it. $ sudo less /etc/sysconfig/iptables Generated by iptables-save v1.4.7 on Fri Oct 24 13:28:48 2014 *filter :INPUT ...
0
votes
1answer
29 views

How to prevent an application from connecting to a network with iptables? [duplicate]

I have read the manual page of iptables in terminal, but it has complicated syntax and I don't fully understand how to use options like: user, user ID, UUID and so on. Suppose my username is foobar ...
1
vote
1answer
42 views

How to enable ping between machines connected in two interfaces?

I have a linux board with two ethernet interfaces as mentioned below. eth0 connected to another linux machine (ad-hoc) eth0 on board 191.168.1.2 connected to Linux machine 192.168.1.3 eth1 on board ...
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 ...
0
votes
1answer
27 views

iptables | redirect from local [interface:port] to local [interface:port]

0 down vote favorite I have two interfaces eth0 (192.168.1.95) and eth0:1 (10.0.0.100) i want all packet for 192.168.1.95:9900 (from any 192.168/24) will be redirect/forward to 10.0.0.100:9900 and ...
0
votes
2answers
862 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) ...
2
votes
1answer
463 views

iptables Port Forwarding — no service with the port

I have setup a network as in the image below: Firewall (FW) running CentOS 6 has two physical interfaces with subinterfaces: eth0:2 — 10.100.1.78/25 eth0:3 — 10.100.1.79/25 eth3 — 192.168.0.21/24 ...
1
vote
2answers
37 views

Impossible to browse web after configuring iptables

I'm trying to configure iptables on my ubuntu computer. These are my rules: Chain INPUT (policy DROP) target prot opt source destination ACCEPT tcp -- anywhere ...
1
vote
0answers
20 views

Shorewall configuration : providers and LAN

Hi all and thanks in advance for the answers. Currently, I have different providers configured in shorewall. I'll will probably have to change one of them. The problem is I won't have any Public IP ...
1
vote
1answer
38 views

Email evading my spam filter

I'm having trouble with email evading my Barracuda Spam firewall. I believe the spammers are using my A Record to bypass my MX Record which is what directs email to my Barracuda for processing. How ...