T09 · Insecure Skill Coding Practices
- Location
scripts/utils/api_util.py:156- Finding
API Key Exposure Through Command-Line Arguments
- Content
View full analysis
str | None: """Resolve API Key in order: CLI argument > TUNEE_API_KEY.""" for key in (cli_key, os.environ.get("TUNEE_API_KEY")): if not key: continue key = key.strip() if not key: continue if key != "your-access-key-here": return key ``` It also instructs users to place a literal key in a command: ```python def print_api_key_help() -> None: """Print API Key configuration guide to stderr.""" print("Error: No API Key detected.", file=sys.stderr) print("", file=sys.stderr) print("Configure via one of:", file=sys.stderr ...[truncated 2834 chars]- Remediation
View remediation
