T09 · Insecure Skill Coding Practices
- Location
scripts/auth.py:20- Finding
Sensitive credentials exposed through command-line arguments
- Content
View full analysis
") sys.exit(1) token_data = get_token(sys.argv[1], sys.argv[2]) ``` `scripts/get_self.py:18-22`: ```python if __name__ == "__main__": if len(sys.argv) < 2: print("Usage: get_self.py ") sys.exit(1) user = get_self(sys.argv[1]) ``` `scripts/get_balance.py:18-22`: ```python if __name__ == "__main__": if len(sys.argv) < 3: print("Usage: get_balance.py ") sys.exit(1) balance = get_balance(sys.argv[1], sys.argv[2]) ``` `scripts/list_items.py:18-22`: ```python if __name__ == "__main__": if len(sys.argv) < 2: print("Usage: list_items.py ") sys.exit(1) items = list_items(sys.argv[1]) ``` `scripts/list_chats.py:18-22`: ```python if __name__ == "__main__": if len(sys.argv) < 3: print("Usage: list_chats.py ") sys.exit(1) chats = list_chats(sys.argv[1], sys.argv[2]) ``` The corresponding usage documented in `SKILL.md` instructs users to place secrets directly on the command line: ```bash python3 scripts/auth.py python3 scripts/get_self.py python3 scripts/get_balance.py python3 scripts/list_items.py python3 scripts/list_chats.py ``` ### Technical Analysis The scripts retrieve the Avito client secret and bearer access tokens from `sys.argv`. Command-line arguments are not an app ...[truncated 2457 chars]- Remediation
View remediation
