Skip to content

pnpm license scanning does not work? #7890

Closed Answered by DmitriyLewen
otbe asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @otbe
Thanks for your report!

We use PostAnalyzer logic and virtual filesystem for fs mode.
In your case Trivy "sees" only pnpm-lock.yaml files (trivy fs pnpm-lock.yaml)
To detect licenses you need that PATH includes node_modules dir:
e.g.:

root@9e124ec6440e:/tmp/foo# trivy -q fs . --scanners license

pnpm-lock.yaml (license)

Total: 3 (UNKNOWN: 0, LOW: 3, MEDIUM: 0, HIGH: 0, CRITICAL: 0)

┌──────────────┬─────────┬────────────────┬──────────┐
│   Package    │ License │ Classification │ Severity │
├──────────────┼─────────┼────────────────┼──────────┤
│ react        │ MIT     │ Notice         │ LOW      │
├──────────────┤         │                │          │
│ js-tokens    │       …

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@otbe
Comment options

@DmitriyLewen
Comment options

@otbe
Comment options

Answer selected by otbe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
triage/support Indicates an issue that is a support question. scan/license Issues relating to license scanning
2 participants