← Home

pegjs

Parser generator for JavaScript

7
Versions
MIT
License
No
Install Scripts
Missing
Provenance

Supply chain provenance

Status for the latest visible version.

No SLSA provenance npm registry signatures gitHead linked

Without SLSA provenance there is no cryptographic link between this tarball and the public source — the axios compromise (March 2026) relied on exactly this gap.

Maintainers

dmajda

Keywords

parser generatorPEG

Accepted risks

Findings the reviewer chose to accept rather than block on.

SourceRuleReasonAccepted byWhen
source-diff obfuscated-file:lib/parser.js AI (source-diff): lib/parser.js is PEG.js's self-hosted generated parser; long lines are inherent to generated parser output, not obfuscation. ai
source-diff net-exec-file:lib/compiler/passes/generate-javascript.js AI (source-diff): False positive: this is PEG.js's parser code generator — it constructs JS source strings for parsers, no network calls present. ai
source-diff net-exec-file:lib/compiler/passes/generate-js.js AI (source-diff): Core code generation pass of a parser generator; String.fromCharCode for bytecode encoding, not malicious network/exec activity. ai
semgrep semgrep:eval-usage AI (semgrep): eval() is PEG.js's documented mechanism to compile grammars into runnable parsers at runtime; fundamental to the library's design. ai
provenance no-provenance AI (provenance): Package predates Sigstore provenance; long-established publisher with consistent history. ai

Versions (showing 7 of 7)

Version Deps Published
0.10.0 0 / 5
0.9.0 0 / 3
0.8.0 0 / 3
0.7.0 0 / 2
0.6.2 0 / 2
0.6.1 0 / 2
0.6.0 0 / 2

v0.10.0

2 findings
HIGH New file with network + code execution: lib/compiler/passes/generate-js.js source-diff

Newly added file contains both network calls and dynamic code execution. This is a hallmark of dropper/loader malware.

LOW No provenance attestation provenance

Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.9.0

3 findings
HIGH New obfuscated file: lib/parser.js source-diff

Newly added source file contains lines over 3000 chars, suggesting minified or obfuscated code. New obfuscated files are a strong attack indicator.

HIGH New file with network + code execution: lib/compiler/passes/generate-javascript.js source-diff

Newly added file contains both network calls and dynamic code execution. This is a hallmark of dropper/loader malware.

INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.8.0

2 findings
HIGH New file with network + code execution: lib/compiler/passes/generate-javascript.js source-diff

Newly added file contains both network calls and dynamic code execution. This is a hallmark of dropper/loader malware.

INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.7.0

1 finding
INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.6.2

1 finding
INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.6.1

1 finding
INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v0.6.0

1 finding
INFO No provenance attestation provenance

[Accepted risk] Package was published without Sigstore provenance. Only ~12% of npm packages have provenance, so this is common but not ideal.