Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [iptables]

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

Filter by
Sorted by
Tagged with
0 votes
0 answers
4 views

tun2socks configuration not working

I am trying to configure a tun2socks server that forwards all traffic to an external proxy found online. I also want to retain the ability to ssh into the server so I had to take this into ...
user avatar
0 votes
0 answers
3 views

Fail2Ban - Unban with actionban

I am looking to implement a quarantine system with fail2ban and would appreciate some advice. I have an action that redirects an IP to a captcha page rather than banning it. That is implemented via a ...
user avatar
0 votes
0 answers
15 views

Router [ER-X] as WireGuard Client to hide Office IP on Debian Server. Cannot bind to WireGuard IP from the server

Dear ServerFault community I have a problem with my WireGuard Tunnel overall configuration. I have an OVH VPS with 4 public IPs (MY_PUBLIC) acting as a WireGuard server and forwarding all the traffic (...
user avatar
  • 11
0 votes
0 answers
27 views

Redirect port 443 to 8080?

(note: I intentionally wrote "httpz" instead of "https" because I got an error message when trying to post the question) I have a web server (docker container) running on 8080. I ...
user avatar
  • 111
0 votes
0 answers
16 views

Why is the Nginx server unreachable despite the ports being open?

I am in a very unusual situation and I have spent almost 8 hours trying to figure out what the problem is. The setup I have a server running Debian 11. Inside this server, I have a setup a CentOS ...
user avatar
  • 101
0 votes
0 answers
18 views

Why is iptables blocking return traffic?

OS: Ubuntu 18.04.6 Firewall type: IPtables. UFW is Disabled. I have Kubernetes cluster with 3 nodes that provide the controlplane and etcd services, named cp01, cp02 and cp03. I see that etcd traffic ...
user avatar
0 votes
0 answers
10 views

How to alter ACCEPT to DROP with specific destination in iptables

I have this entry in iptables ACCEPT tcp -- anywhere 0.0.0.0.in-addr.arpa tcp dpt:4210. I want to alter ACCEPT to DROP. I tried using sudo /sbin/iptables -A DOCKER -p tcp -d 0.0.0....
user avatar
1 vote
1 answer
19 views

How to change default firewalld behaviour to drop all established connections on reload

I have a web-server and sshd services running and listening for connections on their ports. What I want to achieve is when I change my zone from public to something that prohibits ports 22 or 443, my ...
user avatar
0 votes
1 answer
18 views

How to block internet access for OpenVPN clients and restrict traffic to VPN network? (Installed with openvpn-install)

I setup an OpenVPN server using openvpn-install. I would like clients to be able to connect to the VPN server, but any traffic aimed towards the internet instead of the VPNs local network should be ...
user avatar
0 votes
2 answers
86 views

Create an NFQUEUE rule to match a local addresses destination in my raspberry pi router

I'm working on a project to verify the source of each packet if its destination is one of several IPs on the LAN network. I'm interested in the LAN IPs, not the WAN. I tried to create many matches ...
user avatar
0 votes
0 answers
25 views

Iptables redirection to main proxy after filter on local proxy

I manage a subnet linked to an Institutional network (IN). Internet access from my subnet is through a proxy with credentials (they are not related to the users of my domain) in the IN. I need to ...
user avatar
0 votes
1 answer
26 views

Routing fwmark to VPN gateway using nftables mark

I'm trying to setup selective routing of a traffic filtered by IP address over OpenVPN on my OpenWRT router I have an OpenVPN profile up and working with route-nopull option to disable setting default ...
user avatar
0 votes
1 answer
19 views

Can't connect to sendgrid from server (and iptables woes)

I'm getting timeouts when using telnet smtp.sendgrid.net 587 on my VPS, but it works fine from my local ubuntu station..so I think there's some firewall issue. I have a docker setup (yes that has some ...
user avatar
  • 103
0 votes
0 answers
27 views

Use iptables and nftables together

Is it possible to use nftables and iptables together? How can I give iptables rules higer priority than nftables. As I am using nftables for nat and iptables to drop traffic by matching hex & ...
user avatar
  • 1
-1 votes
0 answers
22 views

Router Dropping Packets

I'm seeing a strange issue with a wired connection to a router on the LAN, where TCP traffic is dropped and logged as a fragmented packet. Scenario has MTU set at 1500 on network clients and on router ...
user avatar
  • 1
0 votes
0 answers
10 views

Why ACCEPT target for POSTROUTING chain of nat table is not working in iptables?

I am trying to audit the packet and byte size of ping request to remote server at POSTROUTING chain in nat table of iptables. For that i have created the rule using ACCEPT target as follow iptables -t ...
user avatar
0 votes
1 answer
33 views

reaching apache public reverse proxy virtualhost url from localhost behind a NAT using iptables

I have an issue with a guest using virsh behind a server running with iptables firewall. This guest hosts websites, one is mattermost with reverse proxy. Everything is working well. I then installed ...
user avatar
  • 109
1 vote
1 answer
46 views

IP forwarding with IPTables for lvs nat mode

I am learning about the L3 loadbalancers and now working on the keepalived NAT mode.The packet flow should be Client ------> L3(lvs DNAT)------> real servers and the return flow should be exact ...
user avatar
0 votes
0 answers
27 views

Unbound DNS (Redirection of LAN)

I'm trying to redirect my LAN queries to local DNS server (installed in LAN) instead of default DNS ie 8.8.8.8. I'm using unbound 1.13.1 and tried the following: tried localzone local-zone: "10....
user avatar
  • 9
0 votes
1 answer
47 views

WireGuard combining Hub and Spoke with Point to Site

I want a Point to Site topology but since the "client" and "server" hosts are both in their own NAT networks I need to rely on a third host in a Hub and Spoke topology. ...
user avatar
0 votes
0 answers
16 views

How to redirect tailscale to shadowsocks

How to redirect tailscale traffic (TPC+UDP) through shadowsocks proxy on Linux? I've tried ss-redirect with no success.
user avatar
  • 117
0 votes
0 answers
55 views

Why do my iptable rules keep growing longer and longer

I added port 80 and port 3306 to my iptables rules on a VM.Standard.E2.1.Micro running Ubuntu on Oracle by doing: sudo iptables -I INPUT -p tcp -m tcp --dport 80 -j ACCEPT sudo netfilter-persistent ...
user avatar
  • 73
0 votes
0 answers
18 views

Investigating incoming IP connection issues on Ubuntu VPS

I'm investigation some issues with Stripe webhooks not reaching our test server. According to their docs they submit requests from the following IPs: https://stripe.com/docs/ips#webhook-notifications ...
user avatar
0 votes
0 answers
44 views

Using container with openvpn client to route other lan client

I have been dealing with this hassle for almost two months. I will explain the situation. I work from home and to access most of my company services I have to use an openvpn client. The thing is that ...
user avatar
  • 1
0 votes
0 answers
14 views

Make a remote host have a local IP address with ARP capability(Steam Link) [migrated]

Currently I have two subnets in the 10.0.0.0/16, which are 10.40.20.0/24, let's say that's A and 10.32.80.0/24, B. My PC is in the subnet A and what I'm going to do is use Steam Link, Oculus Air Link ...
user avatar
  • 1
0 votes
0 answers
20 views

OpenVPN unable to ping server ip range

Hi i have set up a system like this Situation Graph Here I have the server network at 192.168.255.1/24 and 2 subnets 10.0.0.1/24 and 10.0.1.1/24. I want these to be able to call a client that is in ...
user avatar
0 votes
1 answer
12 views

Is there a way to get event every time that Iptables rules/chains are modified?

I wish to know if there is any way to subscribe to event which accrue every time that iptables rule/chain is modified/added/deleted? Thank you
user avatar
0 votes
1 answer
72 views

OpenVPN routing between subnets and LAN not working

I have set up an openVPN server with topology subnet. It contains a set of subnets for clients in the region 10.0.X.X which are routed. In the Server network there is a client (not in VPN) that runs a ...
user avatar
0 votes
0 answers
21 views

iptables show chains without references

iptables -L -v -n gives me multiple chains but without references. Like this: Chain fail2ban-apache-auth (0 references) pkts bytes target prot opt in out source destination ...
user avatar
0 votes
0 answers
29 views

Docker container has no internet ... GoDaddy hosting

It's GoDaddy hosting (Linux 4.15.0-176-generic #185-Ubuntu) docker 1.5-1build1 $ docker pull busybox $ docker run busybox ping -c 5 google.com PING google.com (142.251.33.206): 56 data bytes --- ...
user avatar
0 votes
0 answers
24 views

iptables forward tcp port to another port on same host after connection already established

i have a tcp server that prints messages it gets(without sending back) on port 1234 and another tcp server on port 5678. i have a client that already communicates with the 1234 server and i want to ...
user avatar
0 votes
1 answer
63 views

Postfix: Couldn't Stop "SASL LOGIN authentication failed" Attack in Mail Logs

I'm trying to stop an attack and logs with SASL LOGIN authentication failed for my mail server. However, I've been trying for a day and am still not able to achieve it. The logs continue to generate ...
user avatar
-1 votes
1 answer
27 views

Access to the subnet of the OpenVPN server from the client side

i'am have server 172.26.8.231 in LAN 172.26.0.0/20 with OpenVPN server running(10.8.0.0/24, server 10.8.0.1). I want access host in server lan(172.26.13.14), i have added to server.conf: push "...
user avatar
  • 1
0 votes
0 answers
52 views

Docker Redsocks as proxy for all traffic

I'm using redsocks to connect to my socks5 proxy and everything works fine but because docker creates an new interface named docker0 no traffic gets forwarded to REDSOCKS Standart Redsocks config ...
user avatar
0 votes
0 answers
18 views

How to block non vlan traffic for an ip address on linux

I have a vlan created on a Linux vm and assigned ip address to it.I would like to block all incoming traffic to the IP address that is not coming from the same vlan I would still like to able to send ...
user avatar
  • 1
1 vote
1 answer
29 views

Properly configuring iptables for two layers of port forwarding: external server connected to local server via VPN

I had a minecraft server running on a VPS (Debian 10), but the VPS was too puny to handle it so I wanted to use a beefier local server to run it (Ubuntu 22.04). The VPS is hosting an OpenVPN server, ...
user avatar
  • 11
0 votes
1 answer
16 views

iptables: No chain/target/match by that name while trying to accept SSH connctions

I'm trying to use this rule to accept the SSH connections, however it doesn't work: sudo iptables -A FORDWARD -p tcp --dport 22 -j ACCEPT And I got this error: iptables: No chain/target/match by that ...
user avatar
1 vote
0 answers
142 views

Issues between docker and firewalld/iptables

OpenSUSE 15.3 user here. I broke the default rules created by docker on iptables and can't figure out how to repair this. I tried reinstalling docker already. Here is what happens: vm-dev:~ # ...
user avatar
  • 73
0 votes
0 answers
16 views

How to redirect output traffic which is directed to specific server? (e.g. via iptables)

everyone! I am trying to imagine situation: I have gitlab on server 'B', but server 'A' can't communicate with him. I have server 'A' that doesn't have connection to server 'B'. But I have a server 'C'...
user avatar
0 votes
1 answer
31 views

Unable to access one server on network, while able to access others

I am not certain about the terminology; I will try to be as clear as possible but note I might use a word wrong. I have a number of Ubuntu servers, all connected to the same network. I can access each ...
user avatar
0 votes
0 answers
48 views

Accessing the server using the router's IP works inside the network, but not outside

So I have a domain (nextcloud.selfhosted.tamashalasi.com) which points to 91.101.56.134: The public IP of my router is the mentioned IP, this screenshot is from https://whatismyipaddress.com/ ...and ...
user avatar
  • 101
0 votes
1 answer
33 views

fail2ban appears to be working but server still receives connection attempts

fail2ban mistery! Everything seems to be working and well configured but server still receives connection attempts. [moso@matrix ~]$ sudo systemctl status fail2ban ● fail2ban.service - Fail2Ban ...
user avatar
  • 1
0 votes
0 answers
31 views

IPTABLES rule in DNS rec running bind

We have 4 DNS Recursive server and 2 authoritative server all of them running CentOs7 and Bind. So we authorize only DNS 53 port for the anycast interface in rec servers. For iptables we found this ...
user avatar
0 votes
1 answer
20 views

How to mark all the packets coming from a device?

I create a tun device using ip tuntap add dev tun0 mode tun, then I want to set mark to all the packets coming from tun0 using iptables -t mangle -A OUTPUT -o tun0 -j MARK --set-mark 1. But when I ...
user avatar
0 votes
0 answers
33 views

Dhcp server dont access internet

I have 2 ethernet cards in Ubuntu Server 20.04; enp1s0 my main ethernet card, enp2s0 my dhcp server ethernet card. I want devices that receive ip via enp2s0 to access the internet, but if I set the ...
user avatar
  • 1
-1 votes
1 answer
52 views

~90% error rate with Stripe webhooks, unpredictable response. Server issue?

I'm setting up Stripe webhooks for the first time. I've made hundreds of test requests and I've had an error rate of around 90%. It's unpredictable as to why the failures occur. The failure responses ...
user avatar
  • 1
0 votes
0 answers
15 views

iptables: how does NAT Instance handle the traffic from the connection initiated from outside?

AWS allows developer to create an NAT instance in the public subnet, and provide private subnet the ability to access the internet. Here is the precedure to create the NAT instance. For the iptables ...
user avatar
  • 103
0 votes
0 answers
13 views

Outboud connection to external mysql server times out

I'm attempting to connect to an external mysql host (11.22.33.44), but the connection continues to time out. The server I'm connecting from (55.66.77.88) is up and has internet connectivity. Server 55....
user avatar
  • 709
0 votes
1 answer
24 views

Forward port on VM and keep source IP

I want to forward port 80 from the proxy to nginx and keep the original IP. My current structure: Proxy vm(192.168.0.104) - VM with iptables that redirects all traffic from port 80 to 192.168.106:80 ...
user avatar
1 vote
0 answers
19 views

Ubuntu L2TP Server not allow to connect multiple devices

Till today, this website showed me some answers that solve the problem. But it seems I couldn't find the correct answer to this problem. I have a project for a VPN network for remote service purposes, ...
user avatar

1
2 3 4 5
127