Vulnerabilities in pkg:pypi/api-res-py
PACKAGECVE-2022-31313 is a CRITICAL (CVSS 9.8) backdoor vulnerability (General Security Weakness) affecting Api res py libraries in the PyPI ecosystem. The issue involves backdoor in api-res-py. Remediation is available in the latest vendor maintenance releases.
pkg:pypi/api-res-py
Vulnerability advisories affecting package pkg:pypi/api-res-py. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-6978-4w92-428p | CVE-2022-31313 | CRITICAL | Backdoor in api-res-py |
CVE-2022-31313 at a Glance
Security Impact
CVSS: 9.8
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).
How to Fix CVE-2022-31313
To remediate this vulnerability, upgrade all affected Api res py dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install api-res-py>=Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show api-res-py
How to Check if You Are Affected
To determine whether your Python environment is affected by CVE-2022-31313, inspect your installed packages using pip:
pip show api-res-py
Analyze the terminal output to locate any version of Api res py in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The pip show api-res-py command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under General Security Weakness. In Api res py, 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
CVE-2022-31313 Affected Api res py Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
api-res-py
|
PyPI |
≤ 0.1
|
|
References
Frequently Asked Questions
What is CVE-2022-31313?
Which Api res py versions are affected?
What version fixes CVE-2022-31313?
Is api-res-py affected?
What is the CVSS score of CVE-2022-31313?
What CWE is associated with CVE-2022-31313?
How can I check PyPI dependencies for CVE-2022-31313?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-6978-4w92-428p",
"modified" : "2024-11-21T21:40:07Z",
"published" : "2022-06-09T00:00:16Z",
"aliases" : [ "CVE-2022-31313" ],
"summary" : "Backdoor in api-res-py",
"details" : "api-res-py package in PyPI 0.1 is vulnerable to a code execution backdoor in the request package.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "api-res-py"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"last_affected" : "0.1"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-31313"
}, {
"type" : "WEB",
"url" : "https://github.com/rakeshrkz7/as_api_res/issues/1"
}, {
"type" : "WEB",
"url" : "https://github.com/pypa/advisory-database/tree/main/vulns/api-res-py/PYSEC-2022-43071.yaml"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/rakeshrkz7/as_api_res"
}, {
"type" : "WEB",
"url" : "https://pypi.org/project/api-res-py"
}, {
"type" : "WEB",
"url" : "http://pypi.doubanio.com/simple/request"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2022-06-17T21:51:19Z",
"nvd_published_at" : "2022-06-08T20:15:00Z"
}
}