From c6da3bb7d14820802811f24cb6f8fb5d6bf77afd Mon Sep 17 00:00:00 2001
From: Eric Garver <eric@garver.life>
Date: Wed, 19 Jan 2022 15:23:15 -0500
Subject: [PATCH] fix(check-config): use the dictionary variants

It was possible for newer config fields of an io_object to not be
checked. That is, the fields covered by check_config(), i.e. the fields
covered by the tuple based dbus APIs.

Conflict: NA
Reference: https://github.com/firewalld/firewalld/commit/c6da3bb7d14820802811f24cb6f8fb5d6bf77afd

(cherry picked from commit 3b466b8bf092256dcbd1b541df4924d154ca7386)
---
 src/firewall/core/io/functions.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/firewall/core/io/functions.py b/src/firewall/core/io/functions.py
index 35a7eaf8..c357223a 100644
--- a/src/firewall/core/io/functions.py
+++ b/src/firewall/core/io/functions.py
@@ -73,7 +73,7 @@ def check_config(fw):
                         obj = readers[reader]["reader"](file, _dir)
                         if reader in ["zone", "policy"]:
                             obj.fw_config = fw_config
-                        obj.check_config(obj.export_config())
+                        obj.check_config_dict(obj.export_config_dict())
                         readers[reader]["add"](obj)
                     except FirewallError as error:
                         raise FirewallError(error.code, "'%s': %s" % (file, error.msg))
@@ -83,7 +83,7 @@ def check_config(fw):
         try:
             obj = Direct(config.FIREWALLD_DIRECT)
             obj.read()
-            obj.check_config(obj.export_config())
+            obj.check_config_dict(obj.export_config_dict())
         except FirewallError as error:
             raise FirewallError(error.code, "'%s': %s" % (config.FIREWALLD_DIRECT, error.msg))
         except Exception as msg:
@@ -92,7 +92,7 @@ def check_config(fw):
         try:
             obj = LockdownWhitelist(config.LOCKDOWN_WHITELIST)
             obj.read()
-            obj.check_config(obj.export_config())
+            obj.check_config_dict(obj.export_config_dict())
         except FirewallError as error:
             raise FirewallError(error.code, "'%s': %s" % (config.LOCKDOWN_WHITELIST, error.msg))
         except Exception as msg:
-- 
2.23.0