aboutsummaryrefslogtreecommitdiff
path: root/cvss/severity.go
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2022-02-07 11:03:09 -0500
committerPaul Duncan <pabs@pablotron.org>2022-02-07 11:03:09 -0500
commit19bcc5e8df039f5de0f46fd6aa71e425a5e797bb (patch)
treed931dc7b113cd2f989d0afdde9adfa00e6aca3ba /cvss/severity.go
parent5bc6072dd22038f8f0c3cf6cc8ed758293725a8f (diff)
downloadcvez-19bcc5e8df039f5de0f46fd6aa71e425a5e797bb.tar.bz2
cvez-19bcc5e8df039f5de0f46fd6aa71e425a5e797bb.zip
cvss: add severity and tests
Diffstat (limited to 'cvss/severity.go')
-rw-r--r--cvss/severity.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/cvss/severity.go b/cvss/severity.go
new file mode 100644
index 0000000..88df96a
--- /dev/null
+++ b/cvss/severity.go
@@ -0,0 +1,16 @@
+package cvss
+
+type Rating byte
+
+//go:generate stringer -linecomment -type=Severity
+
+// CVSS score severity rating.
+type Severity byte
+
+const (
+ None Severity = iota // None
+ Low // Low
+ Medium // Medium
+ High // High
+ Critical // Critical
+)