Skip to content

Syft Extract dependencies from Package.json in JavaScript Package Cataloger #3108

@murarishetti

Description

@murarishetti

What would you like to be added:
Today, JavaScript package cataloger parses only parent name and version but it did not extract dependencies listed in package.json

Why is this needed:
It is a gap in the parser and we are missing dependencies listed in the package manager file

Additional context:
In the below package.json file, Syft today extracts only name and version but not dependencies listed.

Source/Input: "Directory"

{
    "name": "test-3p",
    "version": "0.0.1",
    "description": "Test",
    "lockfileVersion": 1,
    "engines": {
      "node": ">=16.17.1"
    },
    "dependencies": {
      "loadash": "4.17.15",
      "epxress": "4.17.1"
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    Status

    Ready

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions