Advisory Database
  • Advisories
  • Dependency Scanning
  1. golang
  2. ›
  3. github.com/gohugoio/hugo
  4. ›
  5. CVE-2020-26284

CVE-2020-26284: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

June 23, 2021

Hugo is a fast and Flexible Static Site Generator built in Go. Hugo depends on Go’s os/exec for certain features, e.g. for rendering of Pandoc documents if these binaries are found in the system %PATH% on Windows. In Hugo before version 0.79.1, if a malicious file with the same name (exe or bat) is found in the current working directory at the time of running hugo, the malicious command will be invoked instead of the system one. Windows users who run hugo inside untrusted Hugo sites are affected. Users should upgrade to Hugo v0.79.1. Other than avoiding untrusted Hugo sites, there is no workaround.

References

  • github.com/advisories/GHSA-8j34-9876-pvfq
  • github.com/gohugoio/hugo/security/advisories/GHSA-8j34-9876-pvfq
  • github.com/golang/go/issues/38736
  • nvd.nist.gov/vuln/detail/CVE-2020-26284

Code Behaviors & Features

Detect and mitigate CVE-2020-26284 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 0.79.1

Fixed versions

  • 0.79.1

Solution

Upgrade to version 0.79.1 or above.

Impact 8.5 HIGH

CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
  • CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

Source file

go/github.com/gohugoio/hugo/CVE-2020-26284.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:00 +0000.