From ded6d274c6e59a12933c7d2c3fd7592b34eb89bf Mon Sep 17 00:00:00 2001 From: Rottler Tamas Date: Tue, 28 Feb 2023 21:38:48 +0100 Subject: [PATCH] asa config check --- routerbackup | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/routerbackup b/routerbackup index 1530074..9e01cf2 100755 --- a/routerbackup +++ b/routerbackup @@ -365,6 +365,11 @@ class AsaConfig(Config): self.config = '\n'.join(shrun) self.extra['iproute']['content'] = '\n'.join(iproute) + def is_bad_config(self): + super().is_bad_config() + if not re.search(': end', self.config): + return "does not contain ': end'." + return False def setup_logging(hostname, logfile, loglevel): handler = logging.FileHandler(logfile, 'a')