CVE-2024-49380: Github.com/plentico/plenti Plenti Arbitrary File Write Vulnerability Vulnerability

HIGH
Advisory Identifier: GHSA-2p96-p7qh-4rgr
CWE-78 CWE-74
Published
Advisory Summary

CVE-2024-49380 is a HIGH plenti arbitrary file write vulnerability vulnerability (CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')) affecting Github.com/plentico/plenti libraries in the Go ecosystem. The issue involves plenti arbitrary file write vulnerability. Remediation is available by upgrading affected packages to version 0.7.2.

CVE-2024-49380 at a Glance

CVE Identifier CVE-2024-49380
GHSA Identifier GHSA-2p96-p7qh-4rgr
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
Affected Product Github.com/plentico/plenti
Package Ecosystem Go
Published Date
Last Updated

How to Fix CVE-2024-49380

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

github.com/plentico/plenti fixed: 0.7.2
Upgrade github.com/plentico/plenti to 0.7.2
Verify Direct and Transitive Dependencies

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

inspect dependencies for github.com/plentico/plenti

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-49380, inspect your project dependencies for Github.com/plentico/plenti:

inspect dependencies for github.com/plentico/plenti

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

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection'), where the product constructs all or part of an os command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended os command when it is sent to a downstream component. In Github.com/plentico/plenti, 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

Plenti, a static site generator, has an arbitrary file write vulnerability in versions prior to 0.7.2. The `/postLocal` endpoint is vulnerable to an arbitrary file write vulnerability when a plenti user serves their website. This issue may lead to Remote Code Execution. Version 0.7.2 fixes the vulnerability.

CVE-2024-49380 Affected Github.com/plentico/plenti Versions

1 component(s)
Fixed Versions:
0.7.2
Product / Package Ecosystem Affected Versions Fixed Version
github.com/plentico/plenti
Go
< 0.7.2
0.7.2

References

Frequently Asked Questions

What is CVE-2024-49380?
CVE-2024-49380 is a security vulnerability in Github.com/plentico/plenti involving Plenti arbitrary file write vulnerability under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection').
Which Github.com/plentico/plenti versions are affected?
Affected versions include releases prior to 0.7.2 across affected packages: github.com/plentico/plenti.
What version fixes CVE-2024-49380?
Upgrading to 0.7.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/plentico/plenti affected?
Yes, github.com/plentico/plenti is affected in releases prior to 0.7.2. Upgrade your dependency to 0.7.2 or later.
What CWE is associated with CVE-2024-49380?
CVE-2024-49380 is classified under CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') (The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.).
How can I check Go dependencies for CVE-2024-49380?
Run the dependency tree command: 'inspect dependencies for github.com/plentico/plenti'. 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-2p96-p7qh-4rgr",
  "modified" : "2024-10-31T21:48:53Z",
  "published" : "2024-10-31T21:48:53Z",
  "aliases" : [ "CVE-2024-49380" ],
  "summary" : "Plenti arbitrary file write vulnerability",
  "details" : "Plenti, a static site generator, has an arbitrary file write vulnerability in versions prior to 0.7.2. The `/postLocal` endpoint is vulnerable to an arbitrary file write vulnerability when a plenti user serves their website. This issue may lead to Remote Code Execution. Version 0.7.2 fixes the vulnerability.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:P"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/plentico/plenti"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.7.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-49380"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/plentico/plenti"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/plentico/plenti/blob/01825e0dcd3505fac57adc2edf29f772d585c008/cmd/serve.go#L205"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/plentico/plenti/releases/tag/v0.7.2"
  }, {
    "type" : "ADVISORY",
    "url" : "https://securitylab.github.com/advisories/GHSL-2024-297_GHSL-2024-298_plenti"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-74", "CWE-78" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-10-31T21:48:53Z",
    "nvd_published_at" : "2024-10-25T14:15:12Z"
  }
}