Skip to main content
CVE Vulnerability Database
Vulnerability Database/CVE-2025-46332

CVE-2025-46332: Flags SDK Information Disclosure Flaw

CVE-2025-46332 is an information disclosure vulnerability in Flags SDK for Next.js and SvelteKit that exposes feature flag details to attackers. This article covers technical details, affected versions, and mitigation.

Published:

CVE-2025-46332 Overview

CVE-2025-46332 is an information disclosure vulnerability in the Flags SDK, an open-source feature flags toolkit for Next.js and SvelteKit maintained by Vercel. Affected versions include flags 3.2.0 and prior, and @vercel/flags 3.1.1 and prior. Under certain circumstances, an attacker with detailed knowledge of the flaw can enumerate all feature flags returned by the discovery endpoint at .well-known/vercel/flags. Exposed data includes flag names, descriptions, available options, option labels, and default values. The issue is resolved in flags@4.0.0, and users of both packages should migrate to that release. The weakness is classified as [CWE-200].

Critical Impact

Attackers can enumerate internal feature flag configurations, revealing unreleased functionality, experiment structures, and application logic that should remain private.

Affected Products

  • flags package versions 3.2.0 and prior
  • @vercel/flags package versions 3.1.1 and prior
  • Next.js and SvelteKit applications using the Flags SDK discovery endpoint

Discovery Timeline

  • 2025-05-02 - CVE-2025-46332 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-46332

Vulnerability Analysis

The Flags SDK exposes a discovery endpoint at .well-known/vercel/flags intended for administrative and tooling use. In vulnerable versions, access controls on this endpoint fail under specific conditions, allowing unauthenticated callers with knowledge of the flaw to retrieve the full feature flag inventory. Returned data includes flag identifiers, human-readable descriptions, permitted option values such as true or false, option labels, and default values. Attackers gain visibility into unreleased features, A/B test structures, kill-switches, and business logic controlled by flags.

Root Cause

The vulnerability stems from insufficient authorization enforcement on the flags discovery endpoint [CWE-200]. The endpoint returns metadata that should be restricted to authenticated administrative contexts but becomes reachable by external requesters under exploitable conditions. Applications relying on flag secrecy for pre-release feature protection or as part of security-relevant gating logic are directly impacted.

Attack Vector

Exploitation requires network access to the target application and knowledge of the discovery endpoint path. No authentication, privileges, or user interaction are required. An attacker issues an HTTP request to .well-known/vercel/flags on a vulnerable deployment and parses the returned JSON payload to enumerate the complete flag catalog. The disclosed metadata can then inform further probing, such as manipulating client-side flag state to access hidden functionality.

For technical specifics, refer to the GitHub Security Advisory GHSA-892p-pqrr-hxqr and the Vercel Changelog for CVE-2025-46332.

Detection Methods for CVE-2025-46332

Indicators of Compromise

  • HTTP requests to /.well-known/vercel/flags from unexpected external clients or IP ranges
  • Requests to the discovery endpoint lacking expected administrative session headers or tokens
  • Successful 200 OK responses to the discovery endpoint containing full flag metadata payloads

Detection Strategies

  • Inspect web server, CDN, and edge logs for requests targeting .well-known/vercel/flags and correlate against source reputation
  • Audit deployed application dependencies for flags versions at or below 3.2.0 and @vercel/flags versions at or below 3.1.1
  • Baseline legitimate flag discovery traffic and alert on requests from non-approved user agents or origins

Monitoring Recommendations

  • Enable request logging at the edge or reverse proxy for all .well-known/* paths
  • Track response sizes for the flags endpoint to identify anomalous bulk enumeration
  • Alert on high-frequency access to feature flag routes from single source addresses

How to Mitigate CVE-2025-46332

Immediate Actions Required

  • Upgrade the flags package to version 4.0.0 or later in all affected Next.js and SvelteKit applications
  • Migrate any usage of the deprecated @vercel/flags package to flags@4.0.0
  • Rotate or reconsider any flag values that acted as security-sensitive gates and assume disclosed metadata is public

Patch Information

The fix is delivered in flags@4.0.0. Vercel published an upgrade guide on GitHub covering the migration path from both flags@3.x and @vercel/flags. Applications must redeploy after upgrading to ensure the patched discovery endpoint logic is active.

Workarounds

  • Block or restrict external access to /.well-known/vercel/flags at the CDN, WAF, or reverse proxy layer until the upgrade is completed
  • Require authentication headers or IP allow-listing on the discovery endpoint route
  • Remove sensitive descriptions and labels from flag definitions if immediate upgrade is not possible
bash
# Configuration example
npm install flags@4.0.0
npm uninstall @vercel/flags

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.