GHSA-f84p-cvgm-xgjj

Suggest an improvement
Source
https://github.com/advisories/GHSA-f84p-cvgm-xgjj
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/05/GHSA-f84p-cvgm-xgjj/GHSA-f84p-cvgm-xgjj.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-f84p-cvgm-xgjj
Aliases
Downstream
CGA (4)
Published
2026-05-12T14:59:45Z
Modified
2026-09-10T03:50:46Z
Severity
  • 7.8 (High) CVSS_V3 - CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H CVSS Calculator
Summary
protobuf.js is Vulnerable to OS Command Injection in the CLI
Details

Summary

pbts invoked JSDoc by building a shell command string from input file paths and executing it through child_process.exec. File paths containing shell metacharacters could therefore be interpreted by the shell instead of being passed to JSDoc as plain arguments.

Impact

An attacker who can control file names or paths passed to pbts may be able to execute arbitrary shell commands with the privileges of the process running pbts.

This affects the protobufjs CLI tooling path. The protobufjs runtime APIs for encoding, decoding, parsing, and loading protobuf messages are not directly affected by this issue.

Preconditions

  • The application or user must invoke pbts on file paths influenced by an attacker.
  • The attacker must be able to supply or create a path containing shell-significant characters.
  • The vulnerable pbts version must execute the generated JSDoc command through a shell.

Workarounds

Do not run affected versions of pbts on attacker-controlled file names or paths. If this cannot be avoided, sanitize or rename input files before invoking pbts, or run the CLI in an isolated environment with minimal privileges.

Database specific
{
    "cwe_ids":  [
        "CWE-78"
    ],
    "github_reviewed":  true,
    "github_reviewed_at":  "2026-05-12T14:59:45Z",
    "nvd_published_at":  "2026-05-13T16:16:47Z",
    "severity":  "HIGH"
}
References

Affected packages

npm / protobufjs-cli

Package

Name
protobufjs-cli
View open source insights on deps.dev
Purl
pkg:npm/protobufjs-cli

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
1.2.1

Database specific

last_known_affected_version_range
"<= 1.2.0"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/05/GHSA-f84p-cvgm-xgjj/GHSA-f84p-cvgm-xgjj.json"

npm / protobufjs-cli

Package

Name
protobufjs-cli
View open source insights on deps.dev
Purl
pkg:npm/protobufjs-cli

Affected ranges

Type
SEMVER
Events
Introduced
2.0.0
Fixed
2.0.2

Database specific

last_known_affected_version_range
"<= 2.0.1"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/05/GHSA-f84p-cvgm-xgjj/GHSA-f84p-cvgm-xgjj.json"