cve.bz

CVE-2022-21668 Year 2038 problem, Y2K38, Y2038, Epochalypse

8.6 highExploit referenceEPSS 3.9%Fix available

High (8.6). EPSS 3.9% estimated probability of exploitation activity in the next 30 days. Fixed in pipenv 2022.1.8.

On this page
pipenv is a Python development workflow tool. Starting with version 2018.10.9 and prior to version 2022.1.8, a flaw in pipenv's parsing of requirements files allows an attacker to insert a specially crafted string inside a comment anywhere within a requirements.txt file, which will cause victims who use pipenv to install the requirements file to download dependencies from a package index server controlled by the attacker. By embedding malicious code in packages served from their malicious index server, the attacker can trigger arbitrary remote code execution (RCE) on the victims' systems. If an attacker is able to hide a malicious `--index-url` option in a requirements file that a victim installs with pipenv, the attacker can embed arbitrary malicious code in packages served from their malicious index server that will be executed on the victim's host during installation (remote code execution/RCE). When pip installs from a source distribution, any code in the setup.py is executed by the install process. This issue is patched in version 2022.1.8. The GitHub Security Advisory contains more information about this vulnerability.

Severity

CVSS 3.1

8.6 high
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
EPSS
3.9% (unchanged from 3.9% a week ago; 3.8% 30 days ago) estimated probability of exploitation activity in the next 30 days; 91st percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CWEs
CWE-190 Integer Overflow or Wraparound (Year 2038 problem, Y2K38, Y2038, Epochalypse)
CWE-1284 Improper Validation of Specified Quantity in Input
CWE-20 Improper Input Validation
CWE-77 Improper Neutralization of Special Elements used in a Command
CWE-78 Improper Neutralization of Special Elements used in an OS Command (OS Command Injection)
CWE-427 Uncontrolled Search Path Element
CWE-791 Incomplete Filtering of Special Elements
OWASP Top 10
A05:2025 Injection, A08:2025 Software or Data Integrity Failures
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2022-21668 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2022-21668?via=ask-ai-copy and https://cve.bz/cve/CVE-2022-21668?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2022-21668 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
pypa:pipenvfrom 2018.10.9 before 2022.1.8
fedoraproject:fedora34
fedoraproject:fedora35
fedoraproject:fedora36

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-qc9x-gjcv-465wPyPIpipenv>=2018.10.9 <2022.1.82022.1.8
PYSEC-2022-6PyPIpipenv>=2018.10.9 <2022.1.82022.1.8

Linux distributions

DistributionReleasePackageFixed inAdvisory
Ubuntu20.04:LTS, 22.04:LTS, 24.04:LTS and 3 morepipenvno fix listedUBUNTU-CVE-2022-21668

From the distributions' data via OSV.dev: Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Ubuntu.

Attack patterns (CAPEC)

  • CAPEC-92 Forced Integer Overflow Likelihood: High · Severity: High
  • CAPEC-38 Leveraging/Manipulating Configuration File Search Paths Likelihood: High · Severity: Very High
  • CAPEC-471 Search Order Hijacking Severity: Medium
  • CAPEC-6 Argument Injection Likelihood: High · Severity: High
  • CAPEC-15 Command Delimiters Likelihood: High · Severity: High
  • CAPEC-43 Exploiting Multiple Input Interpretation Layers Likelihood: Medium · Severity: High
  • CAPEC-88 OS Command Injection Likelihood: High · Severity: High
  • CAPEC-108 Command Line Execution through SQL Injection Likelihood: Low · Severity: Very High
  • CAPEC-40 Manipulating Writeable Terminal Devices Likelihood: High · Severity: Very High
  • CAPEC-75 Manipulating Writeable Configuration Files Likelihood: High · Severity: Very High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits. More on the page of CWE-77, CWE-20 (51).

References

Check your stackJSON