Vulnerabilities in pkg:npm/restafary

PACKAGE
Advisory Identifier: GHSA-xg5r-8j97-2wrj
Advisory Summary

CVE-2016-10528 is a MODERATE path traversal vulnerability (CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')) affecting Restafary libraries in the npm ecosystem. The issue involves directory traversal in restafary. Remediation is available by upgrading affected packages to version 1.6.1.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:npm/restafary

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:npm/restafary. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-xg5r-8j97-2wrj CVE-2016-10528 MODERATE Directory Traversal in restafary

CVE-2016-10528 at a Glance

CVE Identifier CVE-2016-10528
GHSA Identifier GHSA-xg5r-8j97-2wrj
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
Affected Product Restafary
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2016-10528

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

restafary fixed: 1.6.1
npm install restafary@1.6.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 restafary

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2016-10528, inspect your project dependencies using npm:

npm ls restafary

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

Note: The npm ls restafary 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-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal'), where the product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory. In Restafary, 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

Affected versions of `restafary` are susceptible to a directory traversal vulnerability when a root path is specified in the configuration. Proof of Concept ``` curl -i -s -k -X 'GET' -H 'Authorization: Basic YWRtaW46cGFzc3dvcmQ=' 'http://localhost:8000/api/v1/fs/..%2f..%2fetc/passwd' ``` ## Recommendation Update to version 1.6.1 or later.

CVE-2016-10528 Affected Restafary Versions

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

References

Frequently Asked Questions

What is CVE-2016-10528?
CVE-2016-10528 is a security vulnerability in Restafary involving Directory Traversal in restafary under CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal').
Which Restafary versions are affected?
Affected versions include releases prior to 1.6.1 across affected packages: restafary.
What version fixes CVE-2016-10528?
Upgrading to 1.6.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is restafary affected?
Yes, restafary is affected in releases prior to 1.6.1. Upgrade your dependency to 1.6.1 or later.
What CWE is associated with CVE-2016-10528?
CVE-2016-10528 is classified under CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') (The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.).
How can I check npm dependencies for CVE-2016-10528?
Run the dependency tree command: 'npm ls restafary'. 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-xg5r-8j97-2wrj",
  "modified" : "2020-08-31T18:10:25Z",
  "published" : "2019-02-18T23:39:22Z",
  "aliases" : [ "CVE-2016-10528" ],
  "summary" : "Directory Traversal in restafary",
  "details" : "Affected versions of `restafary` are susceptible to a directory traversal vulnerability when a root path is specified in the configuration.\n\n\nProof of Concept\n\n```\ncurl -i -s -k  -X 'GET' -H 'Authorization: Basic YWRtaW46cGFzc3dvcmQ=' 'http://localhost:8000/api/v1/fs/..%2f..%2fetc/passwd'\n```\n\n\n## Recommendation\n\nUpdate to version 1.6.1 or later.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "restafary"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.6.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2016-10528"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-xg5r-8j97-2wrj"
  }, {
    "type" : "WEB",
    "url" : "https://www.npmjs.com/advisories/89"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-22" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T22:03:10Z",
    "nvd_published_at" : null
  }
}