Twitch API Keys

ID

twitch_key

Severity

low

Vendor

Twitch

Family

API Token

Description

Twitch is a video live streaming service that focuses on video game live streaming, including broadcasts of esports competitions, in addition to offering music broadcasts, creative content, and "in real life" streams. Its REST API allows to interact with various services on the platform.

A client_id and client_secret are associated to an application to authenticate this application when interacting with the API.

Security

Any hardcoded Twitch Key is a potential secret reported by this detector.

Accidentally checking-in the keys to source control repositories could compromise your Twitch account.

Examples

{
  "TWITCH_SECRET_TOKEN": "zcxbw4unqgtg9ah886mbunpgbvc8ck"
}

Mitigation / Fix

  1. Remove the Key from the source code or committed configuration file.

  2. Follow your policy for handling leaked secrets, which typically require revoking the secret in the target system(s). Secrets revocation can be handled from your Application Dashboard.

  3. If under a git repository, you may remove unwanted files from the repository history using tools like git filter-repo or BFG Repo-Cleaner. You may follow the procedure listed here for GitHub.

You should consider any sensitive data in commits with secrets as compromised.

Remember that secrets may be removed from history in your projects, but not in other users' cloned or forked repositories.