Bug 1650995 - firewalld adds extra single quotes to log message configured in rich rules
Summary: firewalld adds extra single quotes to log message configured in rich rules
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: firewalld
Version: 31
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: ---
Assignee: Eric Garver
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-11-18 15:41 UTC by Rick Dicaire
Modified: 2020-11-24 15:49 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1727155 (view as bug list)
Environment:
Last Closed: 2020-11-24 15:49:28 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github firewalld firewalld issues 480 0 None open Issues with special characters in rich rules 2020-05-04 04:49:42 UTC

Description Rick Dicaire 2018-11-18 15:41:07 UTC
Description of problem:

firewalld adds extra single quotes to log message configured in rich rules:

Chain IN_public_log (1 references)
target     prot opt source               destination         
LOG        tcp  --  anywhere             anywhere             tcp dpts:rfb:5903 ! match-set home src ctstate NEW,UNTRACKED LOG level warning prefix "'TL0G_VNC: '"
LOG        tcp  --  anywhere             anywhere             tcp dpt:ssh ! match-set home src ctstate NEW,UNTRACKED LOG level warning prefix "'TL0G_SSH: '"

From /etc/firewalld/zones/public.xml:
  <rule family="ipv4">
    <source ipset="home" invert="True"/>
    <service name="vnc-server"/>
    <log prefix="TL0G_VNC: " level="warning"/>
    <reject type="host-unreach"/>
  </rule>
  <rule family="ipv4">
    <source ipset="home" invert="True"/>
    <service name="ssh"/>
    <log prefix="TL0G_SSH: " level="warning"/>
    <reject type="host-unreach"/>
  </rule>

Single quotes inside double quotes didn't exist prior to upgrade from Fedora 28. I cannot confirm if single quotes were there with initial version of firewalld shipped with Fedora 29 as my rich rules broke firewalld, and wasn't resolved until 0.6.3 was released.


Version-Release number of selected component (if applicable):
Name         : firewalld
Version      : 0.6.3
Release      : 1.fc29
Arch         : noarch
Size         : 1.8 M
Source       : firewalld-0.6.3-1.fc29.src.rpm
Repo         : @System
From repo    : updates
Summary      : A firewall daemon with D-Bus interface providing a dynamic firewall
URL          : http://www.firewalld.org
License      : GPLv2+
Description  : firewalld is a firewall service daemon that provides a dynamic customizable
             : firewall with a D-Bus interface.


How reproducible:
Create rich rule, configure a log message prefix.

Steps to Reproduce:
1.
2. 
3.

Actual results:

From iptables -L:
LOG        tcp  --  anywhere             anywhere             tcp dpts:rfb:5903 ! match-set home src ctstate NEW,UNTRACKED LOG level warning prefix "'TL0G_VNC: '"

From syslog:
Nov 18 10:25:59 daw kernel: 'TL0G_SSH: 'IN=ens3 OUT= MAC=52:54:3c:0e:7c:89:00:12:f2:91:b8:00:08:00 SRC=205.185.121.253 DST=162.35.145.51 LEN=44 TOS=0x00 PREC=0x00 TTL=247 ID=54321 PROTO=TCP SPT=39303 DPT=22 WINDOW=65535 RES=0x00 SYN URGP=0


Expected results:
From iptables -L
LOG        tcp  --  anywhere             anywhere             tcp dpts:rfb:5903 ! match-set home src ctstate NEW,UNTRACKED LOG level warning prefix "TL0G_VNC: "

From syslog:
Nov 18 10:25:59 daw kernel: TL0G_SSH: IN=ens3 OUT= MAC=52:54:3c:0e:7c:89:00:12:f2:91:b8:00:08:00 SRC=205.185.121.253 DST=162.35.145.51 LEN=44 TOS=0x00 PREC=0x00 TTL=247 ID=54321 PROTO=TCP SPT=39303 DPT=22 WINDOW=65535 RES=0x00 SYN URGP=0

Additional info:

Comment 1 Zdenek Dohnal 2019-03-12 13:45:39 UTC
If the report was created on demand in https://bugzilla.redhat.com/show_bug.cgi?id=1644432#c24 , then I encountered the same error - firewalld was running, but several errors were reported at the start - it was connected to my created rich rules for machines in virtual network and one of them was for mdns communication, so the issue had an outcome as blocking all mdns communication for me.

Comment 2 Zdenek Dohnal 2019-03-12 14:12:28 UTC
It is not, as Rick said in https://bugzilla.redhat.com/show_bug.cgi?id=1644432#c26 , sorry for the noise.

Comment 3 Rick Dicaire 2019-07-04 17:24:06 UTC
Hi, is this being ignored, or was it fixed in Fedora 30?

Comment 4 Eric Garver 2019-07-05 16:39:39 UTC
(In reply to Rick Dicaire from comment #3)
> Hi, is this being ignored, or was it fixed in Fedora 30?

It is not being ignore. It's just not yet fixed upstream.

  https://github.com/firewalld/firewalld/issues/480

Comment 5 Ben Cotton 2019-10-31 19:04:26 UTC
This message is a reminder that Fedora 29 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 29 on 2019-11-26.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '29'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 29 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 6 Rick Dicaire 2019-10-31 20:12:17 UTC
Thanks for the update.

Comment 7 Ben Cotton 2020-04-30 20:49:52 UTC
This message is a reminder that Fedora 30 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 30 on 2020-05-26.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '30'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 30 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 8 Ben Cotton 2020-11-03 17:11:51 UTC
This message is a reminder that Fedora 31 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 31 on 2020-11-24.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '31'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 31 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 9 Ben Cotton 2020-11-24 15:49:28 UTC
Fedora 31 changed to end-of-life (EOL) status on 2020-11-24. Fedora 31 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.