Skip to content

CVSS library for working with CVSS version 2 scores and base vectors

License

Notifications You must be signed in to change notification settings

aerissecure/cvss

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

cvss

CVSS library for working with CVSS version 2 scores and base vectors

Usage

Easily parse base vector components from a CVSS2 string:

In []: from cvss import cvss
In []: bv = cvss.BaseVector('AV:N/AC:L/Au:N/C:N/I:N/A:P')
In []: bv.av
Out[]: 'N'
In []: bv.au
Out[]: 'N'

Or constuct an instance of BaseVector from the components:

In []: bv = cvss.from_base_metrics('n', 'l', 'n', 'n', 'p', 'c')

Test for validity:

In []: cvss.valid_vector('AV:N/AC:L/Au:N/C:N/I:N/A:H')
Out[]: False

Calculate the base score:

In []: bv.base_score
Out[]: Decimal('5.0')

Calculate the NVD severity based on the base score:

In []: bv.severity
Out[]: 'Medium'

About

CVSS library for working with CVSS version 2 scores and base vectors

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages