MODERATE 6.1

CVE-2021-21684

Stored XSS vulnerability in Jenkins Git Plugin

Description

Jenkins Git Plugin 4.8.2 and earlier does not escape the Git SHA-1 checksum parameters provided to commit notifications when displaying them in a build cause.

This results in a stored cross-site scripting (XSS) vulnerability exploitable by attackers able to submit crafted commit notifications to the /git/notifyCommit endpoint.

Jenkins Git Plugin 4.8.3 rejects Git SHA-1 checksum parameters that do not match the expected format. Existing values are sanitized when displayed on the UI.

This vulnerability is only exploitable in Jenkins 2.314 and earlier, LTS 2.303.1 and earlier. See the LTS upgrade guide.

Affected Maven artifacts (1)

ArtifactAffected versionsFixed in
org.jenkins-ci.plugins » git
< 4.8.3
4.8.3

Blast radius

1affected artifacts
1,036affected versions
177dependent artifacts (est.)
10,942dependent versions

53% of the dependent artifacts (95) still pull an affected version in their latest release.

DepthDependent versions
Direct
4,643
2 hops
6,060
3 hops
239

Most used dependents

Computed from the dependency graph of build 20261127.1117 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.

References

Advisorynvd.nist.gov
Packagegithub.com
Webgithub.com
Webjenkins.io
Webopenwall.com