Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support National Vulnerability Database (NVD) #195

Open
fraxken opened this issue Sep 4, 2023 · 4 comments
Open

Support National Vulnerability Database (NVD) #195

fraxken opened this issue Sep 4, 2023 · 4 comments

Comments

@fraxken
Copy link
Member

fraxken commented Sep 4, 2023

Add a new strategy to support NVD: https://nvd.nist.gov/

The API has a ratelimit but an API key can be requested here

Maybe we need to somehow thinks how to design this given API (We can take inspiration from nodejs-dependency-vuln-assessments

@fraxken fraxken added good first issue Good for newcomers help wanted Extra attention is needed labels Sep 4, 2023
@fabnguess
Copy link
Contributor

fabnguess commented Dec 4, 2023

Hi @fraxken and @PierreDemailly .
I'd like to make sure that I haven't misinterpreted this issue. Its purpose is to call the NIST vulnerability API for each package in the current project in order to detect any known vulnerabilities in them? Below, I present my attempted approach to this subject.

async function getVulnerability(dependency) {
    const response = await fetch(
        `https://services.nvd.nist.gov/rest/json/cves/2.0?keywordSearch=${dependency}`, { headers }); 
    return response.json();
}

const vulnerability = await strategy.getVulnerability("@nodesecure/i18n");

console.log(vulnerability)

@fraxken
Copy link
Member Author

fraxken commented Dec 4, 2023

@fabnguess I think you need to wait that I finish my own PR

@fabnguess
Copy link
Contributor

noted

@fraxken fraxken removed good first issue Good for newcomers help wanted Extra attention is needed labels Jan 26, 2024
@fraxken
Copy link
Member Author

fraxken commented Jan 26, 2024

We need to work on standalone API before dealing with that task (see #226)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants