Skip to content

[SECURITY] [v0.1.0] Path traversal in extension installation allows arbitrary file writes #53522

Description

@R-Panic

Path Traversal in Extension Installation

Version: v0.1.0

Vulnerability Type: Path Traversal (CWE-22)

Issue:
Extension installation does not sanitize VSIX filenames. Attackers can embed ../ sequences to write files outside intended directory.

Impact:

  • Arbitrary file writes
  • System file replacement
  • Complete compromise

Proof of Concept:

Filename: ../../../etc/passwd
Writes to: /etc/passwd (overwrites!)

Actual PoC:

Base: /tmp/extensions/
Evil filename: ../../../etc/passwd
Result: /etc/passwd
ATTACK: Overwrites /etc/passwd!

Recommendation:

  1. Validate paths are within extraction dir
  2. Strip ../ sequences
  3. Use canonicalize() and verify

Severity: CRITICAL

Metadata

Metadata

Assignees

No one assigned

    Labels

    invalidThis doesn't seem right

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions