diff farolluz/vulnerability.py @ 39:2e36289616db

Don't consider a Base Score of 0 as no Base Score
author Benoît Allard <benoit.allard@greenbone.net>
date Tue, 23 Dec 2014 09:01:38 +0100
parents e317097af486
children
line wrap: on
line diff
--- a/farolluz/vulnerability.py	Wed Dec 17 11:24:55 2014 +0100
+++ b/farolluz/vulnerability.py	Tue Dec 23 09:01:38 2014 +0100
@@ -331,7 +331,7 @@
         return ((0.6 * impact) + (0.4 * exploitability) - 1.5) * f(impact)
 
     def validate(self, productids):
-        if not self._basescore:
+        if self._basescore is None:
             raise ValidationError('A CVSS Score Set must have a Base Score')
         if self._vector and not self.vector:
             raise ValidationError('Syntax Error in CVSS Vector')
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)