{"_id":"cvss","_rev":"93339","name":"cvss","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","dist-tags":{"latest":"1.0.5"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"time":{"modified":"2021-06-03T10:31:00.000Z","created":"2016-05-02T18:27:25.552Z","1.0.5":"2019-01-03T21:56:41.328Z","1.0.4":"2018-09-17T00:05:39.960Z","1.0.3":"2018-05-21T20:17:33.678Z","1.0.2":"2017-02-01T20:41:26.445Z","1.0.1":"2016-05-02T18:28:24.210Z","1.0.0":"2016-05-02T18:27:25.552Z"},"users":{},"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"versions":{"1.0.5":{"name":"cvss","version":"1.0.5","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^15.4.5"},"gitHead":"7db33fd92be255d4b3dc59cb7a5d9f03057c8cf8","_id":"cvss@1.0.5","_npmVersion":"6.4.1","_nodeVersion":"9.10.1","_npmUser":{"name":"aaronmccall","email":"amacdagreat@gmail.com"},"dist":{"shasum":"6e9f280f225ee007ebcb81214b3dc3d08fbf13fc","size":8417,"noattachment":false,"key":"/cvss/-/cvss-1.0.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.5.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/cvss_1.0.5_1546552601137_0.9371037621592271"},"_hasShrinkwrap":false,"publish_time":1546552601328,"_cnpm_publish_time":1546552601328},"1.0.4":{"name":"cvss","version":"1.0.4","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^15.4.5"},"gitHead":"44bb567ee03115bdf82dd1beaf9afb544449bcce","_id":"cvss@1.0.4","_npmVersion":"6.2.0","_nodeVersion":"9.10.1","_npmUser":{"name":"aaronmccall","email":"amacdagreat@gmail.com"},"dist":{"shasum":"7f4093b0e462e2e6b11fe3dcd08168b8a8693163","size":8416,"noattachment":false,"key":"/cvss/-/cvss-1.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.4.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/cvss_1.0.4_1537142739827_0.8415082528079256"},"_hasShrinkwrap":false,"publish_time":1537142739960,"_cnpm_publish_time":1537142739960},"1.0.3":{"name":"cvss","version":"1.0.3","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^15.4.5"},"gitHead":"49c67cc3d566daf3157a441c15682ba4824e05fe","_id":"cvss@1.0.3","_npmVersion":"6.0.1","_nodeVersion":"9.10.1","_npmUser":{"name":"aaronmccall","email":"amacdagreat@gmail.com"},"dist":{"shasum":"70df9c4a4e07fdb9341f27a2847a21df25c3a83a","size":8288,"noattachment":false,"key":"/cvss/-/cvss-1.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.3.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/cvss_1.0.3_1526933853590_0.3977784338778314"},"_hasShrinkwrap":false,"publish_time":1526933853678,"_cnpm_publish_time":1526933853678},"1.0.2":{"name":"cvss","version":"1.0.2","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^10.3.1"},"gitHead":"60b683f7dd3cc5448d285df8f4e5082a60d69652","_id":"cvss@1.0.2","_shasum":"df67e92bf12a796f49e928799c8db3ba74b9fcd6","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.3.1","_npmUser":{"name":"aaronmccall","email":"aaron@andyet.net"},"dist":{"shasum":"df67e92bf12a796f49e928799c8db3ba74b9fcd6","size":8579,"noattachment":false,"key":"/cvss/-/cvss-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.2.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/cvss-1.0.2.tgz_1485981684569_0.12163481605239213"},"directories":{},"publish_time":1485981686445,"_cnpm_publish_time":1485981686445,"_hasShrinkwrap":false},"1.0.1":{"name":"cvss","version":"1.0.1","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^10.3.1"},"gitHead":"02cd81627392cc94e4b24be2ed5e0dca47f895e1","_id":"cvss@1.0.1","_shasum":"5c07df53616ac56d66e8f474bed25e3c146193db","_from":".","_npmVersion":"3.8.3","_nodeVersion":"5.7.0","_npmUser":{"name":"aaronmccall","email":"aaron@andyet.net"},"dist":{"shasum":"5c07df53616ac56d66e8f474bed25e3c146193db","size":8663,"noattachment":false,"key":"/cvss/-/cvss-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.1.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/cvss-1.0.1.tgz_1462213701732_0.4465111652389169"},"directories":{},"publish_time":1462213704210,"_cnpm_publish_time":1462213704210,"_hasShrinkwrap":false},"1.0.0":{"name":"cvss","version":"1.0.0","description":"A CommonJS library for working with Common Vulnerability Scoring System vectors and scores.","main":"index.js","scripts":{"test":"lab -v -t 99"},"repository":{"type":"git","url":"git+https://github.com/aaronmccall/cvss.git"},"keywords":[],"author":{"name":"Aaron McCall","email":"aaron@andyet.net","url":"https://github.com/aaronmccall"},"license":"ISC","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"homepage":"https://github.com/aaronmccall/cvss#readme","devDependencies":{"code":"^2.2.0","eslint":"^2.8.0","lab":"^10.3.1"},"gitHead":"104045d16918751e7a1a3d9010027d642b8dbd3c","_id":"cvss@1.0.0","_shasum":"bb628550a1df6b28ed775c99d4b13b1fe9af7c3f","_from":".","_npmVersion":"3.8.3","_nodeVersion":"5.7.0","_npmUser":{"name":"aaronmccall","email":"aaron@andyet.net"},"dist":{"shasum":"bb628550a1df6b28ed775c99d4b13b1fe9af7c3f","size":8662,"noattachment":false,"key":"/cvss/-/cvss-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/cvss/download/cvss-1.0.0.tgz"},"maintainers":[{"name":"aaronmccall","email":"aaron@andyet.net"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/cvss-1.0.0.tgz_1462213644575_0.999082695459947"},"directories":{},"publish_time":1462213645552,"_cnpm_publish_time":1462213645552,"_hasShrinkwrap":false}},"readme":"# cvss\nA CommonJS library for working with Common Vulnerability Scoring System vectors and scores.\n\n## Install\n\n`npm i cvss`\n\n## Usage\n\n```javascript\nvar cvss = require('cvss');\n\nvar score = cvss.getScore('CVSS:3.0/AV:P/AC:H/PR:N/UI:R/S:C/C:L/I:H/A:L');\n\nconsole.log(score) // => 6.2\n\nvar rating = cvss.getRating(score);\n\nconsole.log(rating) // => Medium\n```\n\n### #getScore [String or Object input], [Object options (optional)]\n\nThis is the main scoring method. It may be called with either a valid CVSS3 vector string (`'CVSS:3.0/AV:P/AC:H/PR:N/UI:R/S:C/C:L/I:H/A:L'`) or an object containing the key/value pairs (`{ AV: 'P', AC: 'H', PR: 'N', UI:'R', S: 'C', C: 'L', I: 'H', A: 'L' }`) corresponding to one as its **input** parameter.\n\nThe optional **options** parameter controls whether validation errors throw or not and whether optional temporal and environmental metrics are considered in score calculation\n\n**options**\n- _throw_: if validation returns an error, throw the error\n- _baseOnly_: only consider base metrics when calculating score\n- _temporal_: include temporal metrics when calculating score\n- _env_: include temporal AND environmental metrics when calculating score (both are included per CVSS3 spec)\n\n### #getBaseScore [String or Object input], [Object options (optional)]\n\nAccepts the same arguments as _getScore_ above, but enforces the _baseOnly_ option.\n\n### #getTemporalScore [String or Object input], [Object options (optional)]\n\nAccepts the same arguments as _getScore_ above, but enforces the _temporal_ option.\n### #getEnvironmentalScore [String or Object input], [Object options (optional)]\n\nAccepts the same arguments as _getScore_ above, but enforces the _environmental_ option.\n\n### #getRating [Number score]\n\nGiven a numeric score, returns the appropriate CVSS3 severity rating for that number: _None_ for scores < 0.1, _Low_ for scores >= 0.1 and < 4, _Medium_ for scores >=4 and < 7, _High_ for scores >= 7 and < 9, _Critical_ for scores >= 9.\n\n### #getBase [String or Object input], [Object options (optional)]\n\nReturns an object with the base score and its rating. Equivalent to\n```javascript\n{\n    score: getBaseScore(input),\n    rating: getRating(getBaseScore(input))\n}\n```\n\n### #getEnvironmental [String or Object input], [Object options (optional)]\n\nReturns an object with the environmental score and its rating. Equivalent to\n```javascript\n{\n    score: getEnvironmentalScore(input),\n    rating: getRating(getEnvironmentalScore(input))\n}\n```\n\n### #getTemporal [String or Object input], [Object options (optional)]\n\nReturns an object with the environmental score and its rating. Equivalent to\n```javascript\n{\n    score: getTemporalScore(input),\n    rating: getRating(getTemporalScore(input))\n}\n```\n\n### #getAll [String or Object input], [Object options (optional)]\n\nReturns object with the score and rating for all three scores:\n```javascript\n{\n    base: getBase(input),\n    temporal: getTemporal(input),\n    environmental: getEnvironmental(input)\n}\n```\n","_attachments":{},"homepage":"https://github.com/aaronmccall/cvss#readme","bugs":{"url":"https://github.com/aaronmccall/cvss/issues"},"license":"ISC"}