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)

0
votes
0answers
13 views

squid transparent proxy for https / ssl trafic

I am trying to configure squid as transparent proxy , I followed below steps to configure Downloaded squid3.5 from the website, As squid3.1 will not support for ssl bump ./configure ...
0
votes
1answer
14 views

PSAD IPTables logging error

I installed PSAD on my Ubuntu server and then set the IPTables accordingly. But I still get this error by email: You may just need to add a default logging rule to the /sbin/iptables 'filter' ...
0
votes
0answers
8 views

Combining IPTables Accounting and Transparent Proxy Rules

I'm trying to combine IPTables traffic accounting rules with those required for transparent proxying and still maintain the accounting. I have one system that is handling both accounting and the ...
-3
votes
2answers
39 views

iptables: open port 25 CentOS 7

I have problems opening port 25 for sendmail on my CentOS 7 machine. Here's my iptables configuration: *filter :INPUT ACCEPT [0:0] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [0:0] -A INPUT -m state ...
6
votes
2answers
103 views

Default policy for OUTPUT

Are there any security risks of having policy for OUTPUT set to ACCEPT? Machine in question is VPS hosting few websites, git repositories, jabber server and mail.
-2
votes
0answers
12 views

Tomcat 7 inaccessible on digital ocean

So, I'm trying to get Tomcat to work on Digital Ocean. The server starts up without errors, but it's inaccessible both locally and remotely. It hangs when I try to access it. However, it does work ...
-1
votes
2answers
23 views

How can I enable protocol traffic with firewalld?

I need to allow Protocol 50 (esp) traffic for ipsec. I can do: iptables -A INPUT -p esp iptables -A OUTPUT -p esp How could I do this with firewalld instead? Same question closed on StackOverflow ...
1
vote
0answers
21 views

iptables keeps using old nat rules

I use iptables snat on my gateway to change local source ip addresses to external. The trouble is that after I change the rules (or even if I flush iptables nat table) gateway keeps using the old rule ...
1
vote
1answer
32 views

Why some iptables DNAT rules stop working after some times until reboot?

After a while some of my iptables DNAT rules stop working. If I reboot my server, all of the rules work back. Desciption of the architecture : Tens of hosts (senders) send some UDP packets (one-way ...
1
vote
0answers
42 views

SSH connection doesn't work from server to another server

For a cross backup script, I'm using ssh to transfer files from a server A to a server B. And mutually from B to A. SSH is configured on the port 54321 (not used by another service). There is no ...
0
votes
1answer
31 views

iptables: when to use input or output with LAN connections?

In a SSH server/firewall (192.168.2.3) that has a LAN behind it, say 192.168.2.1/30, will the connection attempts made by the internal machines of the 192.168.2.1/30 network be interpreted by the ...
0
votes
1answer
16 views

How do I get boto to work with port 443 being prerouted to another port?

My title may be poorly worded, but I'll try to get the backstory straight: I have Ubuntu instances with clusters of Docker containers all hosting web servers In order to appease firewalls we want to ...
0
votes
0answers
20 views

iptables ipset misconfiguration?

I'm looking for a solid method to block unwanted TCP/IP traffic. On my linux machine iptables and ipset seem to offer a nice way to do so. Until now I've done this: ipset create ipsok hash:net ...
0
votes
0answers
16 views

Given: iptables entry in place; my.cnf properly set up; MySQL user & permissions properly set - but still cannot access MySQL remotely: Suggestions?

I would like to access MySQL remotely on an Amazon EC2 CentOS instance (I assume it is CentOS because I use yum to update installed applications and libraries). I believe that iptables is set ...
-1
votes
0answers
32 views

Want to filter a single packet out of a TCP stream [duplicate]

I run a gameserver and I have a problem setting up a firewall rule to block an injected packet. First , this is the target data from worldserver without any injection in the exe that connects to the ...
-3
votes
1answer
42 views

iptables rules for blocking specific packets [on hold]

Im using the following iptables rule: iptables -A INPUT -p tcp -m tcp --tcp-flags PSH,ACK PSH,ACK -m length --length 52 -m state --state ESTABLISHED -j DROP It does it's job for blocking the ...
0
votes
2answers
29 views

unexpected RCODE REFUSED - eating up log files

I have a website which I host myself, and I use bind9 as my DNS server (host my own nameservers etc.). I am having a problem with traffic bandwidth, and my syslog is full of the following type of ...
-1
votes
1answer
26 views

How can I apply a firewall rule to a specific local IP?

I host gameservers and as a result have a few IPs. On the main server IP I have the game panel, other IPs are reserved for use by the gameservers I host for my customers. As a result I would like ...
0
votes
0answers
12 views

How to config iptables to forward connection from/to internal VM

I have an host with proxmox and some virtual machine installed, the first machine is a proxy with haproxy that forward the request to other VM and in proxmox host i have this iptables script: ...
1
vote
1answer
33 views

Need advices on iptables

Helly guys ! :-) . I need a (several?) advice(s) from you about my iptables setup. I'm pretty new to iptables, and this is the first time I configure a server with iptables ONLY as a firewall (we ...
1
vote
1answer
40 views

Linux - show dropped packets form firewall

I am trying to set up a sip trunk and so far everything has gone well. The only issue I face is that the call does is not received when the iptables service is running. By stopping the service ...
0
votes
0answers
39 views

Docker open ports in iptables (rabbitmq)

I'm having a docker image based on rabbitmq. Nothing in my Dockerfile specifies anything about ports. I bind the usual rabbitmq ports (5671, 5672 and 15672) to my custom ports by running my instance ...
-1
votes
0answers
26 views

Incoming connections blocked from some IPs on Centos

I have some server processes running on CentOS. I find that I can connect from some external IPs, e.g., port 4005 has some connections: [root@xxxxx dfxbin]# netstat -an | grep :4005 tcp 0 ...
0
votes
0answers
22 views

setting up iptables dmz for dns (bind9) and web server (apache2) [closed]

I have a pc server as dns server (example.com) and also a web server inside. I want to access the web server from the Internet using my public IP. What settings should be applied in iptables if the ...
0
votes
0answers
28 views

iptables logging public server

I would like to create iptables for a public webserver, since I would like some stats on how-many times this server is being tried for open ports/ssh logins/ ... To do this I wanted to filter out all ...
0
votes
0answers
17 views

Routing between eth0 <-> tun0 doesnt work

I am configuring a linux vm as a openvpn client to act as router to route to another machines connected to the central vpn hub Data. Lan: 192.168.10.0/24 Remote vpn subnet: 192.168.40.0/24 openvpn ...
0
votes
1answer
21 views

What exactly happens to packets written to a TUN/TAP device?

I'm trying to send packets to an application listening on eth0 from machine's user-space as if they were coming from a remote machine. What I can't seem to find good documentation for is the exact ...
0
votes
1answer
22 views

IPTables from public ip and port to lan ip

I own 3 public IPs for my server and I have multiple VMs that have their own 'job'. The server has 1 NIC. Public IPs: XX.XX.9.247 (MAIN) XX.XX.21.141 (additional) XX.XX.21.142 (additional) LAN ...
0
votes
0answers
9 views

Route Sepcific URL to another interface [closed]

I have a Raspberry Pi Model B running Raspian. RPi is in between of my local network and Internet Router (as gateway; so all traffic is passing from RPi's eth0 interface to virtual interface eth1). I ...
0
votes
1answer
18 views

How to duplicate multicast packets on several interfaces?

I would like to send a stream from a Linux server to several Linux clients via a multicast address. The clients are directly connected to the server but on different interfaces: bnep0 and bnep1. ...
0
votes
0answers
9 views

L2TP daemon server multiple IP

I have VPS with 3 public IP - Debian 7. I would like to have 3 L2TP damemons (one ip each) NATing traffic to each ip. Something like this l2tp_multiple_public_ip_diagram. I have set up l2tp daemon for ...
1
vote
0answers
46 views

Connect AWS and Azure via OpenVPN

I am trying to connect two networks (AWS and Azure) together via OpenVPN. I am aware of other implementations (OpenSwan+Azure GW etc.) but I need maximal portability as I will be expanding this to ...
0
votes
1answer
24 views

forwarding packet from one interface to another interface

I have an embeded system with 2 interfaces e0 and m0, whose ips are 10.0.0.20 and 192.168.0.20, respectively. Incoming packets into e0 have an ip of 10.0.0.10 and should be forwarded to m0 interface ...
0
votes
0answers
37 views

How to prohibit connections on port 25 except from real mail servers - exim, ubuntu

I'm fairly new to email servers, and my VPS has being blacklisted (for the second time) IP Address 45.56.85.76 is listed in the CBL. It appears to be infected with a spam sending trojan, proxy ...
0
votes
0answers
15 views

HTTP DoS prevetion with UFW firewall

I am trying to creator an HTTP DoS attack on my servers using UFW firewall using this Resource. I edited /etc/ufw/before.rules to get the following rules. # # rules.before # # Rules that should be ...
0
votes
0answers
13 views

How to disable or enable Tor transparentProxy without restarting a process

I am scripting FireFox to download web pages with Tor. I am using Tor TransparentProxy because the FireFox proxy is already used by a Data Aggregator. Tor TransparentProxy let you redirect all your ...
0
votes
1answer
17 views

http requests working on KVM virtual machine, mysql not?

I have an Ubuntu server with KVM virtual machines. I allowed SSH in the firewall so I could access the host. Also I allowed incoming traffic that has state related, established. This is the full ...
0
votes
0answers
14 views

Using ppp0 via VPN for everything but ftp [migrated]

I have an ubuntu server I use to wget certain files from the internet via a VPN. I have set the VPN up using PPP0 and currently adjust the route like this: sudo route add default ppp0 Everything ...
1
vote
0answers
16 views

How to use iptables or IFB to mark incoming traffic by device?

I'm trying to use iptables to mark incoming packets based on the device where those packets arrived (rather than their originating IP address or port etc), but haven't found a way of getting this to ...
0
votes
1answer
50 views

iptables v1.4.21: Couldn't load match `-d':No such file or directory

i am running kerenl 3.14.18 and using iptables 1.4.21, built with these options --static-enable --disable-shared. when i run this command: /sbin/iptables -A PREROUTING -m -d 127.3.0.2/24 -j DNAT ...
0
votes
1answer
29 views

New iptables rules only affect new spawned process

Is there a way to update iptables rules to block a connexion without the need of restarting it? Here is an example of the behavior I want to avoid: On shell#1: I start a ping command 8.8.8.8 On ...
-1
votes
1answer
53 views

iptables and routing mechanics [closed]

At what stages of handling a data packet does the linux kernel apply the different iptables chains and routing? I am looking for a schematic overview of the process.
1
vote
2answers
34 views

NAT-ing with iptables rewrites source IP in logs

I have the following infrastructure in place: internet [outside 81.x.x.x] router [inside 192.168.1.1] | [network 192.168.1.0/24] ...
-2
votes
0answers
22 views

How configure requests from other ports to port 443? [migrated]

I am trying to configure my first https, and i think i get it, but there is a problem: the site wont open in http, just https, because of this, i want redirect everything to https. I am using ...
0
votes
1answer
20 views

ports to open to access samba share

When I turn off my iptables service, I can successfully list my samba shares. But when I turn it back on, I cannot access them at all. Also, my SELINUX is set to permissive Here is my current ...
0
votes
1answer
35 views

redsocks + socks server on different machine

I have the following setup: Host-X (192.168.1.100) running ssh -D so that it can be used as a socks server. Host-Y (192.168.1.101) running redsocks configured with Host-X as socks. They are in the ...
0
votes
0answers
20 views

iptables, outside and inside NAT; Return traffic going out incorrect gateway

Overview (TL;DR at bottom) I have a third party firewall/proxy appliance which is running Linux (Ubuntu), and its routing and firewall engine is backed by iptables and the Linux (source)routing ...
-2
votes
0answers
27 views

Unable to Forward Ports on centOS 6.5

Ports on my machine are not being opened. Here are my iptables -L -n -v and iptables-config files iptables -L -n -v Chain INPUT (policy ACCEPT 0 packets, 0 bytes) pkts bytes target prot opt in ...
-4
votes
1answer
43 views

Applying firewall rules: iptables-restore: line 1 failed [closed]

I'm trying to do Port forwarding on my centOS machine. When i'm restarting iptables i'm getting the error iptables: Applying firewall rules: iptables-restore: line 1 failed [FAILED]. My iptables file ...
0
votes
0answers
23 views

Temporary IPTable Rules when Process Runs

Struggling to find the solution for this and maybe it's easier than I'm making it out to be. I need to open ports in the firewall when a process runs. That process could be requesting the usage of a ...