Ecosyste.ms: Advisories

An open API service providing security vulnerability metadata for many open source software ecosystems.

Security Advisories: GSA_kwCzR0hTQS13anc2LTJjcXItajRxcs0WmQ

Client metadata path-traversal

Impact

In both clients (tuf/client and tuf/ngclient), there is a path traversal vulnerability that in the worst case can overwrite files ending in .json anywhere on the client system on a call to get_one_valid_targetinfo(). It occurs because the rolename is used to form the filename, and may contain path traversal characters (ie ../../name.json).

The impact is mitigated by a few facts:

Patches

A fix is available in version 0.19 or newer.

Workarounds

None that do not require code changes. Clients can restrict the allowed character set for rolenames, or they can store metadata in files named in a way that is not vulnerable: neither of these approaches is possible without modifying python-tuf.

References

For more information

If you have any questions or comments about this advisory:

Permalink: https://github.com/advisories/GHSA-wjw6-2cqr-j4qr
JSON: https://advisories.ecosyste.ms/api/v1/advisories/GSA_kwCzR0hTQS13anc2LTJjcXItajRxcs0WmQ
Source: GitHub Advisory Database
Origin: Unspecified
Severity: High
Classification: General
Published: over 2 years ago
Updated: about 1 year ago


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

Identifiers: GHSA-wjw6-2cqr-j4qr, CVE-2021-41131
References: Repository: https://github.com/theupdateframework/python-tuf
Blast Radius: 11.9

Affected Packages

pypi:tuf
Dependent packages: 2
Dependent repositories: 39
Downloads: 167,367 last month
Affected Version Ranges: < 0.19
Fixed in: 0.19
All affected versions: 0.7.5, 0.9.8, 0.9.9, 0.10.0, 0.10.1, 0.10.2, 0.11.0, 0.11.1, 0.12.0, 0.12.1, 0.12.2, 0.13.0, 0.14.0, 0.15.0, 0.16.0, 0.17.0, 0.18.0, 0.18.1
All unaffected versions: 0.19.0, 0.20.0, 1.0.0, 1.1.0, 2.0.0, 2.1.0, 3.0.0, 3.1.0, 3.1.1, 4.0.0