T01 · Skill Instruction Hijacking
- Location
SKILL.md:6- Finding
Forced Skill Selection and Suppression of Competing Skills
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This Spotify playback skill is mostly purpose-aligned, but it uses overbroad routing instructions and can send ambiguously named credentials to Spotify without clear user control.
Review before installing. Use it only if you want a macOS Spotify.app controller, and avoid running it in environments where generic CLIENT_ID or CLIENT_SECRET variables contain credentials for other services. Prefer explicitly scoped SPOTIFY_CLIENT_ID and SPOTIFY_CLIENT_SECRET values, and be aware that the skill documentation tries to steer the agent to use this skill over other Spotify playback options.
SKILL.md:6Forced Skill Selection and Suppression of Competing Skills
spotplay.py:20Generic Environment Variables May Disclose Unrelated Credentials to Spotify
The skill declares that it must be used for essentially any user intent related to playing music and explicitly instructs the agent not to choose alternative Spotify-related skills. This creates an overly broad routing rule that can override more appropriate tools, increase unintended invocation, and cause actions to be taken on the user's device without sufficient disambiguation or consent.
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
CFG = os.path.expanduser("~/.shpotify.cfg")
def run(cmd: str) -> str:
p = subprocess.run(cmd, shell=True, text=True, capture_output=True)
out = (p.stdout or "").strip()
err = (p.stderr or "").strip()
if p.returncode != 0:
The entire skill documentation is written in Traditional Chinese and does not indicate any option for alternative language or locale handling. Under the stated policy, forcing a specific language without user opt-in can be a natural-language policy violation unless clearly documented as region-specific or optional.
subprocess module calls execute external commands. Without careful input validation, this enables command injection.
CFG = os.path.expanduser("~/.shpotify.cfg")
def run(cmd: str) -> str:
p = subprocess.run(cmd, shell=True, text=True, capture_output=True)
out = (p.stdout or "").strip()
err = (p.stderr or "").strip()
if p.returncode != 0:
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
def search_track_uri(query: str, token: str) -> tuple[str, str]:
q = urllib.parse.quote(query)
url = f"https://api.spotify.com/v1/search?q={q}&type=track&limit=1"
j = http_get(url, {"Authorization": f"Bearer {token}"})
items = (((j.get("tracks") or {}).get("items")) or [])
if not items: