From 27d615c0b286c55260f36b4ad84d754f30e965d9 Mon Sep 17 00:00:00 2001 From: sever-sever Date: Wed, 28 Apr 2021 14:53:12 +0000 Subject: ipsec: T3333: Fix status for SA state op-mode --- src/op_mode/show_ipsec_sa.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/op_mode/show_ipsec_sa.py b/src/op_mode/show_ipsec_sa.py index d1385f959..4e65daf1e 100755 --- a/src/op_mode/show_ipsec_sa.py +++ b/src/op_mode/show_ipsec_sa.py @@ -67,7 +67,7 @@ status_data = [] for conn in connections: status = subprocess.check_output("ipsec statusall {0}".format(conn), shell=True).decode() - if not re.search(r'ESTABLISHED', status): + if not re.search(r'(:\s+ESTABLISHED).*(:\s+INSTALLED)', status, re.S): status_line = [conn, "down", None, None, None, None, None] else: try: -- cgit v1.2.3