From 4be8f8bc40efc1ad80e082351de31b987d21fc34 Mon Sep 17 00:00:00 2001 From: Giovanni Pellerano Date: Sat, 23 Nov 2024 13:16:26 +0100 Subject: [PATCH] Perform database changes review to support integration of #711 Changes: - Add 'antivirus_enabled' variable to make it possible to enable/disable the functionality via UI - Edit the set of 'antivirus' variables to enable type checking on the configuration of the ClamD endpoint --- backend/globaleaks/models/config_desc.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/globaleaks/models/config_desc.py b/backend/globaleaks/models/config_desc.py index 33e5fdcf22..b471979b3f 100644 --- a/backend/globaleaks/models/config_desc.py +++ b/backend/globaleaks/models/config_desc.py @@ -127,7 +127,9 @@ class Bool(Item): 'version_db': Int(default=DATABASE_VERSION), 'wizard_done': Bool(default=False), 'uuid': Unicode(default=uuid4), - 'url_file_analysis': Unicode(default='http://localhost:3000/api/v1/scan'), + 'antivirus_enable': Bool(default=False), + 'antivirus_clamd_ip': Unicode(default='127.0.0.1'), + 'antivirus_clamd_port': Int(default=3301), 'max_msg_external_to_whistle': Int(default=1), 'max_msg_external_to_whistle_not_aff': Int(default=1), 'external_organization_activation': Bool(default=True),