GHSA-wvh7-5p38-2qfc: Parse Storing Password Vulnerability

MODERATE
CWE-256
Published
Advisory Summary

GHSA-wvh7-5p38-2qfc is a MODERATE storing password vulnerability (CWE-256: Plaintext Storage of a Password) affecting Parse libraries in the npm ecosystem. The issue involves storing password in local storage. Remediation is available by upgrading affected packages to version 2.10.0.

GHSA-wvh7-5p38-2qfc at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-wvh7-5p38-2qfc
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-256: Plaintext Storage of a Password
Affected Product Parse
Package Ecosystem npm
Published Date
Last Updated

How to Fix GHSA-wvh7-5p38-2qfc

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

parse fixed: 2.10.0
npm install parse@2.10.0
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 parse

How to Check if You Are Affected

To determine whether your Node.js application is affected by GHSA-wvh7-5p38-2qfc, inspect your project dependencies using npm:

npm ls parse

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

Note: The npm ls parse 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-256: Plaintext Storage of a Password, where the product stores a password in plaintext within resources such as memory or files. In Parse, 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

The `setPassword` method (http://parseplatform.org/Parse-SDK-JS/api/2.9.1/Parse.User.html#setPassword) stores the user's password in localStorage as raw text making it vulnerable to anyone with access to your localStorage. We believe this is the only time that password is stored at all. In the documentation under Users > Signing Up, it clearly states, "We never store passwords in plaintext, nor will we ever transmit passwords back to the client in plaintext." Example Code: ```js async () => { const user = Parse.User.current() if (user) { user.setPassword('newpass') await user.save() } } ``` After running the above code, the new password will be stored in localStorage as a property named "password". Proposed Solution: Before saving anything to localStorage, Parse should strip out any properties named "password" that are attempting to be stored with a Parse.User type object. Configuration: Parse SDK: 2.9.1 Parse Server: 3.9.0

GHSA-wvh7-5p38-2qfc Affected Parse Versions

1 component(s)
Fixed Versions:
2.10.0
Product / Package Ecosystem Affected Versions Fixed Version
parse
npm
< 2.10.0
2.10.0

References

Frequently Asked Questions

What is GHSA-wvh7-5p38-2qfc?
GHSA-wvh7-5p38-2qfc is a security vulnerability in Parse involving Storing Password in Local Storage under CWE-256: Plaintext Storage of a Password.
Which Parse versions are affected?
Affected versions include releases prior to 2.10.0 across affected packages: parse.
What version fixes GHSA-wvh7-5p38-2qfc?
Upgrading to 2.10.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is parse affected?
Yes, parse is affected in releases prior to 2.10.0. Upgrade your dependency to 2.10.0 or later.
What CWE is associated with GHSA-wvh7-5p38-2qfc?
GHSA-wvh7-5p38-2qfc is classified under CWE-256: Plaintext Storage of a Password (The product stores a password in plaintext within resources such as memory or files.).
How can I check npm dependencies for GHSA-wvh7-5p38-2qfc?
Run the dependency tree command: 'npm ls parse'. 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-wvh7-5p38-2qfc",
  "modified" : "2021-09-22T21:05:43Z",
  "published" : "2020-07-23T18:20:10Z",
  "aliases" : [ ],
  "summary" : "Storing Password in Local Storage",
  "details" : "The `setPassword` method (http://parseplatform.org/Parse-SDK-JS/api/2.9.1/Parse.User.html#setPassword) stores the user's password in localStorage as raw text making it vulnerable to anyone with access to your localStorage. We believe this is the only time that password is stored at all. In the documentation under Users > Signing Up, it clearly states, \"We never store passwords in plaintext, nor will we ever transmit passwords back to the client in plaintext.\"\n\nExample Code:\n```js\nasync () => {\n    const user = Parse.User.current()\n    if (user) {\n        user.setPassword('newpass')\n        await user.save()\n    }\n}\n```\nAfter running the above code, the new password will be stored in localStorage as a property named \"password\".\n\nProposed Solution:\nBefore saving anything to localStorage, Parse should strip out any properties named \"password\" that are attempting to be stored with a Parse.User type object.\n\nConfiguration:\nParse SDK: 2.9.1\nParse Server: 3.9.0",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "parse"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.10.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/parse-community/Parse-SDK-JS/security/advisories/GHSA-wvh7-5p38-2qfc"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/parse-community/Parse-SDK-JS/commit/d1106174571b699f972929dd7cbb8e45b5283cbb"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/parse-community/Parse-SDK-JS"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-256" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-07-23T18:18:24Z",
    "nvd_published_at" : null
  }
}