Arbitrary file existence check in file fingerprints in Jenkins
Moderate severity
GitHub Reviewed
Published
May 24, 2022
to the GitHub Advisory Database
•
Updated Dec 14, 2023
Package
Affected versions
< 2.263.2
>= 2.264, <= 2.274
Patched versions
2.263.2
2.275
Description
Published by the National Vulnerability Database
Jan 13, 2021
Published to the GitHub Advisory Database
May 24, 2022
Reviewed
Jun 23, 2022
Last updated
Dec 14, 2023
Jenkins provides a feature for jobs to store and track fingerprints of files used during a build. Jenkins 2.274 and earlier, LTS 2.263.1 and earlier provides a REST API to check where a given fingerprint was used by which builds. This endpoint does not fully validate that the provided fingerprint ID is properly formatted before checking for the XML metadata for that fingerprint on the controller file system.
This allows attackers with Overall/Read permission to check for the existence of XML files on the controller file system where the relative path can be constructed as 32 characters.
Jenkins 2.275, LTS 2.263.2 validates that a fingerprint ID is properly formatted before checking for its existence.
References