CVE-2025-27154

Spotipy's cache file, containing spotify auth token, is created with overly broad permissions

Published Feb 27, 2025 CVSS 4.0 · 8.4 High EPSS < 1% KEV · Not listed
Description
Spotipy is a lightweight Python library for the Spotify Web API. The `CacheHandler` class creates a cache file to store the auth token. Prior to version 2.25.1, the file created has `rw-r--r--` (644) permissions by default, when it could be locked down to `rw-------` (600) permissions. This leads to overly broad exposure of the spotify auth token. If this token can be read by an attacker (another user on the machine, or a process running as another user), it can be used to perform administrative actions on the Spotify account, depending on the scope granted to the token. Version 2.25.1 tightens the cache file permissions.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
EUVD EUVD EUVD-2025-5469 Spotipy's cache file, containing spotify auth token, is created with overly broad permissions
Github GHSA Github GHSA GHSA-pwhh-q4h6-w599 Spotipy's cache file, containing spotify auth token, is created with overly broad permissions
History
Type Values Removed Values Added
First Time appeared Spotipy Project
Spotipy Project spotipy
CPEs cpe:2.3:a:spotipy_project:spotipy:*:*:*:*:*:*:*:*
Vendors & Products Spotipy Project
Spotipy Project spotipy
Metrics cvssV3_1

{'score': 9.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H'}

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description Spotipy is a lightweight Python library for the Spotify Web API. The `CacheHandler` class creates a cache file to store the auth token. Prior to version 2.25.1, the file created has `rw-r--r--` (644) permissions by default, when it could be locked down to `rw-------` (600) permissions. This leads to overly broad exposure of the spotify auth token. If this token can be read by an attacker (another user on the machine, or a process running as another user), it can be used to perform administrative actions on the Spotify account, depending on the scope granted to the token. Version 2.25.1 tightens the cache file permissions.
Title Spotipy's cache file, containing spotify auth token, is created with overly broad permissions
Weaknesses CWE-276
References
Metrics cvssV4_0

{'score': 8.4, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Feb 27, 2025, 2:29 PM
Reserved
Feb 19, 2025, 4:30 PM
Status
Analyzed
Published
Feb 27, 2025, 2:15 PM
Modified
Jun 17, 2026, 9:03 AM