From 5619a6390e3d65acf3638ed23bcabbff3b34b316 Mon Sep 17 00:00:00 2001 From: Juha Kosonen Date: Wed, 1 Apr 2020 10:28:30 +0300 Subject: [PATCH] Change the criticality of kube-hunter test Vulnerabilities discovered by kube-hunter does not impact to overall result of test suite execution. Change-Id: If3593412e68f397258de0fe7dcf86f102ae4d0ce Signed-off-by: Juha Kosonen --- bluval/bluval.py | 2 +- tests/k8s/kube-hunter/kube-hunter.resource | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/bluval/bluval.py b/bluval/bluval.py index c79c830..63b301f 100644 --- a/bluval/bluval.py +++ b/bluval/bluval.py @@ -64,7 +64,7 @@ def run_testcase(testcase): # run the test args = ["robot", "-V", str(variables_updated_file), "-d", str(results_path), - "-b", "debug.log", str(test_path)] + "-n", "non-critical", "-b", "debug.log", str(test_path)] print('Executing testcase {}'.format(name)) print('show_stopper {}'.format(show_stopper)) diff --git a/tests/k8s/kube-hunter/kube-hunter.resource b/tests/k8s/kube-hunter/kube-hunter.resource index 4611e75..6651ddc 100644 --- a/tests/k8s/kube-hunter/kube-hunter.resource +++ b/tests/k8s/kube-hunter/kube-hunter.resource @@ -89,7 +89,9 @@ Delete Scan Job Should Be Equal As Integers ${result.rc} 0 Should Discover No Vulnerabilities - Should Be True ${STATUS} + Return From Keyword If ${STATUS} + Fail Vulnerabilities discovered + ... non-critical Run Scan Within Pod ${result}= Run Process kubectl apply -f ${CURDIR}/job.yaml -- 2.16.6