CVE-2025-47928

Spotipy repo vulnerable to secrets exfiltration via `pull_request_target`

9.1 critical EPSS 0.64%

Published 15 May 2025 Updated 15 May 2025 CNA: GitHub_M

Check your servers for CVE-2025-47928

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2025-47928 affects spotipy, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

Spotipy is a Python library for the Spotify Web API. As of commit 4f5759dbfb4506c7b6280572a4db1aabc1ac778d, using `pull_request_target` on `.github/workflows/integration_tests.yml` followed by the checking out the head.sha of a forked PR can be exploited by attackers, since untrusted code can be executed having full access to secrets (from the base repo). By exploiting the vulnerability is possible to exfiltrate `GITHUB_TOKEN` and secrets `SPOTIPY_CLIENT_ID`, `SPOTIPY_CLIENT_SECRET`. In particular `GITHUB_TOKEN` which can be used to completely overtake the repo since the token has content write privileges. The `pull_request_target` in GitHub Actions is a major security concern—especially in public repositories—because it executes untrusted code from a PR, but with the context of the base repository, including access to its secrets. Commit 9dfb7177b8d7bb98a5a6014f8e6436812a47576f reverted the change that caused the issue.

Severity (CVSS)

9.1 critical CVSS 3.1 from GitHub_M (CNA)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
Attack vector
network: an attacker can reach the vulnerable part over the network, often from the internet
Attack complexity
low: an attack works without special conditions
Privileges required
none: the attacker does not need an account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality high, integrity high, availability none: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 0.64%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 51.9% of all scored CVEs. Scores of 1 Dec 2026.

The assessment of CISA (SSVC, 15 May 2025):

Exploitation
poc: a proof of concept is public
Automatable
yes: an attacker can automate the attack across many targets
Technical impact
total: full control of the component or of its data

Weakness

  • CWE-488 Exposure of Data Element to Wrong Session

Affected products

As the CNA lists them.

ProductVersions
spotipy
affected = 4f5759dbfb4506c7b6280572a4db1aabc1ac778d

Is my server affected?

Find the installed version of spotipy and compare it with the fixed version of your distribution. Distributions often fix a CVE in a package version of their own, so the version number of the upstream project can mislead.

Debian, Ubuntu

dpkg -l | grep -i spotipy
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2025-47928 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2025-47928

RHEL, Rocky, Alma, Fedora

rpm -q spotipy
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2025-47928

Alpine

apk list --installed | grep -i spotipy

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2025-47928
trivy image --scanners vuln IMAGE | grep CVE-2025-47928

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Advisories

Other references

Source: the record CVE-2025-47928 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.