twitch-ai-chatbot

Pass

Audited by Gen Agent Trust Hub on Jun 21, 2026

Risk Level: SAFECOMMAND_EXECUTIONEXTERNAL_DOWNLOADSPROMPT_INJECTION
Full Analysis
  • [COMMAND_EXECUTION]: The script scripts/chatbot.py uses os.system() to automatically install the aiohttp and websockets libraries if they are missing. While the commands are hardcoded to install known packages, runtime execution of shell commands for dependency management is a security best-practice violation.
  • [EXTERNAL_DOWNLOADS]: The skill downloads and installs standard Python packages from the official Python Package Index (PyPI). This behavior is intended for the bot's functionality but involves fetching code from an external repository at runtime.
  • [PROMPT_INJECTION]: The skill is susceptible to indirect prompt injection because it processes untrusted Twitch chat messages and includes them in the context for AI responses.
  • Ingestion points: Twitch chat messages are ingested in scripts/chatbot.py through the handle_raw and handle_message functions.
  • Boundary markers: The prompt template in trigger_handler uses text headers to separate chat history from the user's specific query.
  • Capability inventory: The bot can send data to the Anthropic API and write chat logs to a local JSONL file; there are no capabilities to execute system commands or access sensitive local files based on chat input.
  • Sanitization: The bot includes a _sanitize method that uses regular expressions to filter common injection phrases (e.g., 'ignore previous instructions') and removes hidden Unicode characters (e.g., zero-width spaces) from the chat input.
Audit Metadata
Risk Level
SAFE
Analyzed
Jun 21, 2026, 01:39 AM