T09 · Insecure Skill Coding Practices
- Location
scripts/handler.sh:35- Finding
TMDB API Key Stored in Plaintext and Exposed Through Process Arguments
- Content
View full analysis
/dev/null || echo "") ``` The key is then embedded in URLs passed to `curl`: ```bash local url="${TMDB_BASE}/search/${type}?api_key=${TMDB_API_KEY}&query=${encoded_query}&language=de-DE®ion=${REGION}" local result result=$(curl -s --max-time 10 "$url" 2>/dev/null || echo '{"results":[]}') ``` ```bash local url="${TMDB_BASE}/${type}/${id}?api_key=${TMDB_API_KEY}&language=de-DE&append_to_response=credits,keywords,watch/providers" local result result=$(curl -s --max-time 10 "$url" 2>/dev/null || echo '{}') ``` ```bash local url="${TMDB_BASE}/discover/${type}?api_key=${TMDB_API_KEY}&language=de-DE&watch_region=${REGION}&sort_by=${sort}&vote_count.gte=50" [[ -n "$providers" ]] && url="${url}&with_watch_providers=${providers// /%20}" [[ -n "$genres" ]] && url="${url}&with_genres=${genres// /%20}" local result result=$(curl -s --max-time 10 "$url" 2>/dev/null || echo '{"results":[]}') ``` ### Technical Analysis The TMDB API key is treated as ...[truncated 2155 chars]- Remediation
View remediation
