From 1cd025b2eaa2cfa3f90d0bedccbcab7caa23cbe5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Aime?= Date: Mon, 8 Feb 2021 17:22:44 +0100 Subject: [PATCH] Small changes regarding Analysis translation --- analysis/classes/report.py | 2 +- analysis/classes/suricataengine.py | 2 +- analysis/classes/zeekengine.py | 2 +- analysis/{lang => locales}/en.json | 0 analysis/{lang => locales}/fr.json | 4 ++-- 5 files changed, 5 insertions(+), 5 deletions(-) rename analysis/{lang => locales}/en.json (100%) rename analysis/{lang => locales}/fr.json (99%) diff --git a/analysis/classes/report.py b/analysis/classes/report.py index f823708..d38d26e 100644 --- a/analysis/classes/report.py +++ b/analysis/classes/report.py @@ -451,7 +451,7 @@ class Report(object): color:#CCC; } @bottom-center { - content: REPORT_FOOTER; + content: "REPORT_FOOTER"; font-size:12px; color:#CCC; } diff --git a/analysis/classes/suricataengine.py b/analysis/classes/suricataengine.py index 268f6b0..fb7edd9 100644 --- a/analysis/classes/suricataengine.py +++ b/analysis/classes/suricataengine.py @@ -26,7 +26,7 @@ class SuricataEngine(): # Load template language if not re.match("^[a-z]{2,3}$", self.userlang): self.userlang = "en" - with open(os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])), "lang/{}.json".format(self.userlang))) as f: + with open(os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])), "locales/{}.json".format(self.userlang))) as f: self.template = json.load(f)["alerts"] def start_suricata(self): diff --git a/analysis/classes/zeekengine.py b/analysis/classes/zeekengine.py index 367c803..4ce60a5 100644 --- a/analysis/classes/zeekengine.py +++ b/analysis/classes/zeekengine.py @@ -35,7 +35,7 @@ class ZeekEngine(object): # Load template language if not re.match("^[a-z]{2,3}$", self.userlang): self.userlang = "en" - with open(os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])), "lang/{}.json".format(self.userlang))) as f: + with open(os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])), "locales/{}.json".format(self.userlang))) as f: self.template = json.load(f)["alerts"] def fill_dns(self, dir): diff --git a/analysis/lang/en.json b/analysis/locales/en.json similarity index 100% rename from analysis/lang/en.json rename to analysis/locales/en.json diff --git a/analysis/lang/fr.json b/analysis/locales/fr.json similarity index 99% rename from analysis/lang/fr.json rename to analysis/locales/fr.json index 47eed56..15be281 100644 --- a/analysis/lang/fr.json +++ b/analysis/locales/fr.json @@ -75,7 +75,7 @@ }, "report": { "numbers": [ - "un", + "une", "deux", "trois", "quatre", @@ -102,7 +102,7 @@ "report_footer": "Ce rapport a été automatiquement généré par une instance de TinyCheck. Pour toute question et retours, n'hésitez pas à contacter tinycheck@kaspersky.com.", "high_msg": "Votre appareil semble être compromis car vous avez {} alerte(s) élevée(s).", "moderate_msg": "Vous avez {} alerte(s) modérée(s), votre appareil peut être compromis. Regardez ces alertes en détail.", - "low_msg": "Vous avez uniquement {} alerte(s) faibles, n'hésitez pas à les regarder, on ne sait jamais...", + "low_msg": "Vous avez uniquement {} alerte(s) faibles, n'hésitez pas à les consulter.", "none_msg": "Toute semble normal, vous avez aucune alerte. Cependant, n'hésitez pas à regarder les communications non catégorisées." } } \ No newline at end of file