GHSA-68c2-4mpx-qh95: @sentry/react native Potential Leakage Of Sentry Auth Vulnerability

LOW
CWE-200
Published
Advisory Summary

GHSA-68c2-4mpx-qh95 is a LOW potential leakage of sentry auth vulnerability (CWE-200: Exposure of Sensitive Information to an Unauthorized Actor) affecting @sentry/react native libraries in the npm ecosystem. The issue involves potential leakage of sentry auth tokens by react native sdk with expo plugin. Remediation is available by upgrading affected packages to version 5.19.1.

GHSA-68c2-4mpx-qh95 at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-68c2-4mpx-qh95
Severity LOW
CVSS v3.1 Base Score N/A
CWE Classification CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
Affected Product @sentry/react native
Package Ecosystem npm
Published Date
Last Updated

How to Fix GHSA-68c2-4mpx-qh95

To remediate this vulnerability, upgrade all affected @sentry/react native dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@sentry/react-native fixed: 5.19.1
npm install @sentry/react-native@5.19.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @sentry/react-native

How to Check if You Are Affected

To determine whether your Node.js application is affected by GHSA-68c2-4mpx-qh95, inspect your project dependencies using npm:

npm ls @sentry/react-native

Analyze the terminal output to locate any version of @sentry/react native in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 5.19.1), your application is affected.

Note: The npm ls @sentry/react-native command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor, where the product exposes sensitive information to an actor that is not explicitly authorized to have access to that information. In @sentry/react native, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact SDK versions between and including 5.16.0 and 5.19.0 allowed Sentry auth tokens to be set in the optional authToken configuration parameter, for debugging purposes. Doing so would result in the auth token being built into the application bundle, and therefore the auth token could be potentially exposed in case the application bundle is subsequently published. You may ignore this notification if you are not using `authToken` configuration parameter in your React Native SDK configuration or did not publish apps using this way of configuring the `authToken`. If you had set the `authToken` in the plugin config previously, and built and published an app with that config, you should [rotate your token](https://docs.sentry.io/product/accounts/auth-tokens/). ### Patches The behavior that allowed setting an `authToken` parameter was fixed in SDK version 5.19.1 where, if this parameter was set, you will see a warning and the `authToken` would be removed before bundling the application. ### Workarounds 1. Remove `authToken` from the plugin configuration. 2. If you had set the `authToken` in the plugin config previously, and built and published an app with that config, you should [rotate your token](https://docs.sentry.io/product/accounts/auth-tokens/). ### References * [sentry-react-native 5.19.1 release notes](https://github.com/getsentry/sentry-react-native/releases/tag/5.19.1) * https://github.com/getsentry/sentry-docs/pull/9244

GHSA-68c2-4mpx-qh95 Affected @sentry/react native Versions

1 component(s)
Fixed Versions:
5.19.1
Product / Package Ecosystem Affected Versions Fixed Version
@sentry/react-native
npm
≥ 5.16.0
< 5.19.1
5.19.1

References

Frequently Asked Questions

What is GHSA-68c2-4mpx-qh95?
GHSA-68c2-4mpx-qh95 is a security vulnerability in @sentry/react native involving Potential leakage of Sentry auth tokens by React Native SDK with Expo plugin under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor.
Which @sentry/react native versions are affected?
Affected versions include releases prior to 5.19.1 across affected packages: @sentry/react-native.
What version fixes GHSA-68c2-4mpx-qh95?
Upgrading to 5.19.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @sentry/react-native affected?
Yes, @sentry/react-native is affected in releases prior to 5.19.1. Upgrade your dependency to 5.19.1 or later.
What CWE is associated with GHSA-68c2-4mpx-qh95?
GHSA-68c2-4mpx-qh95 is classified under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor (The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.).
How can I check npm dependencies for GHSA-68c2-4mpx-qh95?
Run the dependency tree command: 'npm ls @sentry/react-native'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-68c2-4mpx-qh95",
  "modified" : "2024-03-01T16:57:56Z",
  "published" : "2024-03-01T16:57:56Z",
  "aliases" : [ ],
  "summary" : "Potential leakage of Sentry auth tokens by React Native SDK with Expo plugin",
  "details" : "### Impact\nSDK versions between and including 5.16.0 and 5.19.0 allowed Sentry auth tokens to be set in the optional authToken configuration parameter, for debugging purposes. Doing so would result in the auth token being built into the application bundle, and therefore the auth token could be potentially exposed in case the application bundle is subsequently published.\n\nYou may ignore this notification if you are not using `authToken` configuration parameter in your React Native SDK configuration or did not publish apps using this way of configuring the `authToken`.\n\nIf you had set the `authToken` in the plugin config previously, and built and published an app with that config, you should [rotate your token](https://docs.sentry.io/product/accounts/auth-tokens/).\n\n### Patches\nThe behavior that allowed setting an `authToken` parameter was fixed in SDK version 5.19.1 where, if this parameter was set, you will see a warning and the `authToken` would be removed before bundling the application.\n\n### Workarounds\n1. Remove `authToken` from the plugin configuration.\n2. If you had set the `authToken` in the plugin config previously, and built and published an app with that config, you should [rotate your token](https://docs.sentry.io/product/accounts/auth-tokens/).\n\n### References\n* [sentry-react-native 5.19.1 release notes](https://github.com/getsentry/sentry-react-native/releases/tag/5.19.1)\n* https://github.com/getsentry/sentry-docs/pull/9244",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@sentry/react-native"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "5.16.0"
      }, {
        "fixed" : "5.19.1"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 5.19.0"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/getsentry/sentry-react-native/security/advisories/GHSA-68c2-4mpx-qh95"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/getsentry/sentry-react-native/commit/9148964a50d2ea1de830854c95f3649f6cb94b1b"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/getsentry/sentry-react-native"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/getsentry/sentry-react-native/releases/tag/5.19.1"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-200" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-03-01T16:57:56Z",
    "nvd_published_at" : null
  }
}