Questions tagged [firewalld]

Firewalld is an open source firewall solution available on several linux distributions. Firewalld uses D-BUS for monitoring and dynamic management.

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

How can I create a firewalld rule that allow SSH connection only from a specific IP address?

I am not a system engineer or a network expert (I am more a software developer) and I have the following problem that I have to solve related IPTABLES firewall. I have n Linux machines that must ...
AndreaNobili's user avatar
  • 6,901
0 votes
0 answers
35 views

How can I be informed if firewalld is disabled

I want to be informed when firewalld is disabled or enabled from logs. For finding this I searched this kind of logs in syslog file but I can't find it. I forward Linux's(RHEL 8/9) logs to the SIEM ...
Faig's user avatar
  • 1
0 votes
0 answers
82 views

Cannot access smb fileshare from PC in different subnet

I'm currently running a network with 2 subnets - the secondary router's a 'DIY' router running ubuntu and firewalld I set up a few years back, the primary is a huawei ONR. The .2.x network is what I ...
Journeyman Geek's user avatar
  • 126k
0 votes
0 answers
145 views

Stuck on converting firewalld direct rule syntax to rich rule syntax

I've been googling around to try to translate an iptables script I use for some wireguard rules into native firewalld rules, since all the docs I've been reading about iptables indicate that: ...
likeyeah's user avatar
2 votes
0 answers
26 views

firewalld Zone "trusted" Drops about 15% of Frames that are Passed by Zone "public"

Background I have two lab machines, which I'll refer to as A and B, running RHEL 8.0. I SSH into A and B from my Windows desktop over a 1 GbE link, whose network interface I'll refer to as eth0. A and ...
Dave's user avatar
  • 971
0 votes
1 answer
239 views

Adding a firewalld service closes the required port instead of opening it

I have a fresh install of Rocky Linux 9 on a Linode Shared CPU instance. I just installed firewalld to get it setup. By default it has the http and ssh services enabled. Doing an nmap scan at this ...
IneptusMechanicus's user avatar
0 votes
1 answer
140 views

firewalld at Almalinux 9 does not apply other zones when 'sources' is specified and matched

I'm migrating from Almalinux 8 (RedHat 8) to Almalinux 9 (RedHat 9) and have got strange behaviour of firewalld. Here is the condiguration I have (as listed by firewall-cmd --list-all-zones): public (...
Xtra Coder's user avatar
0 votes
0 answers
21 views

firewalld runtime config vs permanent config

firewalld.zone man page has two paths to zone.xml, in its synopsis: /etc/firewalld/zones/zone.xml /usr/lib/firewalld/zones/zone.xml Do they have anything to do with permanent vs runtime ...
user1730671's user avatar
1 vote
1 answer
280 views

Firewalld DNAT Subnet translation

I want to translate subnets using firewalld. I have a ethernet interface, that should translate incomming packets targeting 192.168.1.0/24 to 192.168.178.0/24. My home network is 192.168.8.0/24 I ...
appletree's user avatar
1 vote
1 answer
731 views

firewalld: forward traffic as a wireguard VPN gateway

I have setup a pi running Pi OS 11 as a VPN gateway for my local network using Wireguard & Nftables, that all works fine. However, I wish to switch over to firewalld to be compatible with docker ...
uhsl_m's user avatar
  • 113
0 votes
0 answers
404 views

Firewalld open all ports except one

With firewalld, I am trying to allow all ports except one for everyone, as that port must be enabled for a specific host, and I have tried the following: firewall-cmd --permanent --zone=public --add-...
jonyluke's user avatar
1 vote
0 answers
23 views

Is it possible to use iptables ipset together with firewalld?

Currently, I am using firewalld and now I need to use iptables ipset so I was wondering if I can use iptables ipset alongside firewalld and if I can how I should be doing that
poqdavid's user avatar
  • 585
0 votes
1 answer
859 views

Port for forwarding DNS queries to OpenDNS

I'm trying to configure DNS forwarders in domain controllers to OpenDNS. DNS forwarders are configured but the requests are not getting redirected via OpenDNS. I've allowed TCP port 53 to openDNS IPs ...
Guest098's user avatar
0 votes
0 answers
182 views

Firewalld, opening all subnet for zone

Another question about firewalld, I need someone to explain this to me in simple words, because I read countless posts and I don't know what's happening here. I've enable the home zone in ...
Syco's user avatar
  • 236
0 votes
1 answer
433 views

Docker expose port with advance firewall rules

I'm using docker-compose to deploy my app. I want to access the deployment database from my development machine. Is there a way to expose a port with a source IP address limit? Like what happens in ...
M.A. Heshmat Khah's user avatar
3 votes
1 answer
972 views

firewalld rich rules don't drop incoming traffic (CentOS 8 behind a NAT)

Post-Solving Edit The reason this was so hard to solve at the firewall level was that it wasn't a firewall problem. Something @tom-yan said in chat made me revisit the script which pulls out the IP ...
Mark's user avatar
  • 113
2 votes
0 answers
138 views

Fedora unable to mount nfs due to firewalld

I am trying to create a nfs to share between my host and guest VM (run with qemu-kvm). I followed this guide ad this is the situation: host: cat /etc/exports /mnt/nfsshare 192.168.122.76/24(rw,sync,...
Louis's user avatar
  • 21
1 vote
0 answers
193 views

how to configure firewalld, port-forward to specific VM:port and permit VM to external

I have KVM/libvirt env as follows. em1(external) | bridge0 / | \ VM1 VM2 VM3 I hope to access to VM1(192.168.122.103) with 9091 port from external with following. # firewall-cmd -...
HTR's user avatar
  • 11
0 votes
0 answers
330 views

How can I stop firewalld from interrupting an existing outgoing ssh exec session when it is started or restarted?

I have a java program running on a Centos7 server that continuously "tails" a file on another Centos7 server using the JSch library to run an ssh exec process to run a shell script on the ...
Ross's user avatar
  • 1
1 vote
0 answers
135 views

Fedora 33 as wireless router to the internet: stations are always isolated, cannot ping/connect between devices on the wireless lan

Wifi adapter : Asus PCE-AC88 Running on the router : Fedora 33, firewalld, hostapd (built from master), dnsmasq Routing to the internet works great, all stations are routed to the WAN provided by my ...
Ebenezer Cooke's user avatar
1 vote
2 answers
1k views

How to get an IP address blocked with firewall-cmd with immediate effect?

To replicate the problem have two different servers with their own IP addresses. Now start pinging one of them from the second one, and while still pinging block the first server's IP on the second ...
Sasha's user avatar
  • 11
1 vote
1 answer
535 views

How can I fix IPv6 not forwarding traffic correctly between interfaces?

I have two OpenSUSE servers, one with IPv6 and IPv4 while the other only has IPv4 capablities. The two of them are connected with OpenVPN and can communicate using IPv6 through the tunnel just fine. ...
NeonMan's user avatar
  • 153
1 vote
0 answers
214 views

iptables: Limit hit /24 per ip (NETSCAN-Limit) dst limit for ip

in centos we have nat and vpn: 1- detect connections per IP to any /24 if more than 3 different ips in /24 within 5 seconds 2- set dst limit all /24 only for the source ip wich wanted to hit them 3- ...
DjMohsen's user avatar
0 votes
1 answer
1k views

CentOS 8.1: Forwarding OpenVPN Clients to LAN without NAT

So there's an OpenVPN Server with multiple clients, which I successfully divided into multiple subnets. 10.0.30.0/26 for generic clients which are only allowed to communicate with the OpenVPN Server ...
binary_jam's user avatar
1 vote
1 answer
187 views

Firewalld: allow only certain source and destination port pairs

I am using firewalld to configure my firewall. I tried to create a service that allows a specific pair of source and destination ports: <?xml version="1.0" encoding="utf-8"?> <service> &...
equaeghe's user avatar
  • 445
0 votes
1 answer
340 views

How can I block (ssh) traffic from source ports other than a pre-defined one?

A VPS get lots of ssh attacks. Those attacks are various source ports: sshd[76661]: Invalid user ts3server from 76.103.161.19 port 33062 sshd[76661]: Received disconnect from 76.103.161.19 port 33062:...
equaeghe's user avatar
  • 445
0 votes
1 answer
352 views

/var/log/firewalld is not getting rotated

I am not sure why this particular file is not getting rotated. It is not a directory. Any ideas? The size of the firewalld file: $ ls -alh /var/log -rw-r--r--. 1 root root 134M Jan 31 13:49 ...
Shōgun8's user avatar
  • 190
0 votes
1 answer
1k views

I can send E-Mails but not receive E-Mails.. | CentOs - Docker - poste.io

I run a Server on CentOs 7 with FirewallD, on there i run Docker with Poste.io Mailserver. (SQLite, Dovecot, NGiNX, Haraka, RSPAMD, ClamAV, Roundcube, Z-Push) Soo my problem is i can´t receive E-...
TheTrashinger's user avatar
0 votes
1 answer
542 views

Trouble using SCP command

After successfully establishing a ssh connection between two Ubuntu systems via ssh chh1@192.168.1.67 from a local machine with user name chh2 I tried copying a file from my server with the ...
Christian Hick's user avatar
0 votes
1 answer
208 views

CentOS 7 - Load settings for iptables at OS startup

I would like to load the settings below for iptables on CentOS 7 at OS startup using a bash script. How can I do this? #!/bin/bash iptables -I OUTPUT -d 0.0.0.0/0 -j ACCEPT iptables -I FORWARD -d 0....
Eduardo Lucio's user avatar
7 votes
1 answer
10k views

firewall-cmd - add-forward-port don't work

I have a KVM server (host) with multiple virtual machines (guests). My goal is my host forward port 222 to port 22 of a guest running an ssh service. This works... iptables -I OUTPUT -d 0.0.0.0/0 -...
Eduardo Lucio's user avatar
1 vote
0 answers
249 views

Routing Issue Between Interfaces under CentOS7/Firewalld

I use a Linux PC as my Internet gateway; it's running a fresh installation of CentOS 7 x64. I have one subnet (192.168.2.0/24) which is my regular Home network, and I have a second, separate subnet (...
Fred's user avatar
  • 11
0 votes
1 answer
358 views

firewalld - change destination of outgoing http and https requests from local process

I have a process that listens for incoming port 80 and 443 traffic and then sends it out to an extranet recipient. It's a proxy but I don't want to use that term because I need to send ITS outgoing ...
bisharkha's user avatar
1 vote
1 answer
779 views

Blacklist list of IPs from File Centos 7.5

I've to deny access from set of IP set from specific country and downloaded the list from http://www.ipdeny.com/ site. I tried to block this set using firewall-cmd --permanent --ipset=blacklist --...
vish's user avatar
  • 111
0 votes
1 answer
2k views

Linux - FirewallD - Why is ping blocked?

I know that the drop zone (my default zone) in FirewallD blocks all incoming traffic, including icmp, so also ping. The FedoraWorkstation zone, does not block icmp. But where can I see this? If apply ...
Dan's user avatar
  • 89
1 vote
1 answer
585 views

Ho to route one subnet to another using firewalld CentOS 7

I have a CentOS 7 system, with a VPN host and one physical network interface. I have my physical network interface assigned to public zone, while my VPN requests are going through trusted. Also, I ...
László Stahorszki's user avatar
6 votes
1 answer
14k views

How can I configure firewalld to block all outgoing traffic except for specific ports while allowing localhost to access any of its own local ports?

I'll confess at the start that I'm asking this question only after finding the answer and wanting to share it with everyone else. If this is bad form, then my sincere apologies and I'm open to the ...
John T.'s user avatar
  • 241
2 votes
1 answer
3k views

Whitelist websites for specific user on linux?

Due to a child protection and safeguarding issue, I want to set up a restricted or limited account for a tech-savvy teenager to use. I would like to whitelist only specific websites (e.g. iPlayer and ...
DMCoding's user avatar
  • 223
1 vote
2 answers
1k views

Can I block internet access of a single app with firewalld?

Is it possible to prevent a single app to access the internet with firewalld? To be precise, i have an application packaged as an AppImage, currently installed in my Home directory, and I want it to ...
Sekhemty's user avatar
  • 9,066
0 votes
1 answer
976 views

How to make UFW work with firewalld on CentOS 7?

I've installed UFW on a fresh CentOS 7 installation, but it doesn't open the ports. I'm configuring UFW as I would on a Debian system: sudo ufw default deny incoming sudo ufw default allow outgoing ...
HypeWolf's user avatar
  • 103
3 votes
1 answer
1k views

Setting up rules in firewalld to allow clients in the same VPN subnet to communicate

I am trying to setup a Wireguard VPN on a Fedora server. I have it up and running and can connect with multiple clients, browse through it, ssh into the server etc. In general it just works. Except ...
user2858835's user avatar
3 votes
0 answers
2k views

Docker container can't make DNS queries with FirewallD running

While FirewallD is running, all DNS queries fail and are blocked by the firewall. Running tcpdump -i docker0 while running ping google.com in a container shows me 21:27:02.683342 IP 172.17.0.2.35118 &...
ollien's user avatar
  • 83
0 votes
1 answer
116 views

New Linux install, can't get ssh or http connections working, connections are made but drop?

So, I / we have brand new Fedora Core 28 installation we've been trying to bring online. The installation went perfectly so far as we could tell. It has two network cards, one for an internal net, one ...
Richard T's user avatar
  • 447
1 vote
1 answer
9k views

firewall-cmd configure destination NAT

I am trying to configure destiation NAT on a RHEL 7.4 server. I want any traffic generated for 10.10.10.10:443 to go to 10.20.20.20:443. After some Googling I used following direct rule: firewall-...
user686299's user avatar
1 vote
1 answer
1k views

firewall-cmd blocking snmp

I inherited a system that has rules implemented with firewall-cmd, it has the below rules. Another system is trying to connect to snmp port (UDP/161) but is not able (my server is responding with ICMP ...
Rima's user avatar
  • 125
1 vote
1 answer
376 views

Per client firewall settings

I've successfully set up an OpenVPN-Server and can connect to it from the internet. Now I'm trying to implement per-client firewall rules so different clients can only connect to certain addresses in ...
Fang's user avatar
  • 321
0 votes
1 answer
84 views

How to create a firewall rule, to block a website for a particular user? [closed]

can anybody helps me to make a firewall rule to block a particular website for a particular user. i have a Linux operating system am trying to make that OS like a firewall.
sumith ps's user avatar
2 votes
2 answers
3k views

Firewalld block / drop and allow by IP

We have a linux root server which primarily just is a docker server. Hosting containers and a CI runner. To protect this server the basic idea for now is to block all traffic except for one (or more)...
Daniel Böttner's user avatar
1 vote
1 answer
8k views

How to open a UDP port in the Centos 7 firewall, firewalld, using firewall-cmd?

Centos 7 server. Trying to open port 3000 for UDP, nodejs ws websockets. Any ideas? I'm stuck! I've checked a few other SO posts to no avail. Thx, Keith =) If is stop the firewall, the udp unicast ...
kmiklas's user avatar
  • 179
1 vote
0 answers
3k views

TFTP Server With Red Hat 7

How do I set up a TFTP Server w/ Red Hat 7? This is a fresh VM install of RHEL 7.3. I'm using the RHEL 7 Installation Guide instructions at https://access.redhat.com/documentation/en-US/...
coderimpersonator's user avatar