Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
CriticalPublic exploit

Insecure GitHub Actions pull_request_target workflow in Spotipy

IdentifiersCVE-2025-47928CWE-829

CVE-2025-47928 affects Spotipy, a Python library for the Spotify Web API. The issue was introduced in commit 4f5759dbfb4506c7b6280572a4db1aabc1ac778d in .github/workflows/integration_tests.yml, where a GitHub Actions workflow used the pull_request_target trigger and then checked out attacker-controlled code from the forked pull request head (head.ref/head.sha). Because pull_request_target executes in the security context of the base repository, the workflow had access to repository secrets and a privileged GITHUB_TOKEN. The workflow then executed attacker-controlled code via pip install ., allowing arbitrary code execution during CI. According to the provided context, this enabled exfiltration of GITHUB_TOKEN, SPOTIPY_CLIENT_ID, and SPOTIPY_CLIENT_SECRET. The issue was fixed by reverting the vulnerable change in commit 9dfb7177b8d7bb98a5a6014f8e6436812a47576f.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation allows arbitrary code from a forked pull request to run inside the repository's GitHub Actions environment with access to base-repository secrets. The reported impact includes exfiltration of SPOTIPY_CLIENT_ID, SPOTIPY_CLIENT_SECRET, and especially a high-privilege GITHUB_TOKEN with content write permissions. With that token, an attacker could completely compromise or take over the repository, including modifying contents and potentially abusing CI/CD trust relationships.

Mitigation

If you can’t patch tonight, do this now.

If immediate remediation is not possible, avoid exposing secrets to workflows triggered from fork-originated pull requests, minimize GITHUB_TOKEN permissions to the least required, and separate unprivileged PR testing from privileged post-validation workflows, for example by using pull_request for initial checks and workflow_run for trusted follow-on actions. Additional hardening includes preventing execution of attacker-controlled build/install steps in privileged jobs and monitoring CI runners for secret access, memory scraping, or outbound exfiltration behavior.

Remediation

Patch, then assume compromise.

Remove the unsafe pattern of combining pull_request_target with checkout and execution of untrusted pull request code. In Spotipy, the vulnerable change was reverted in commit 9dfb7177b8d7bb98a5a6014f8e6436812a47576f, which fixed the issue. More generally, workflows handling code from forks should use pull_request for untrusted validation, avoid checking out head.ref or head.sha from forked PRs in privileged contexts, and avoid executing attacker-controlled package installation steps such as pip install . when secrets are available.
PUBLIC EXPLOITS

Exploits

No public exploits tracked yet. Mallory keeps watching.

VALID 0 / 0 TOTALView more in app

No public exploit code observed for this vulnerability.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence

Every observed campaign linking this CVE to a named adversary.

Associated malware

Malware families riding this exploit, with evidence and IOCs.

Detection signatures

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity1

Community discussion across Reddit, Mastodon, and other social sources.