T09 · Insecure Skill Coding Practices
- Location
src/clawback/config_loader.py:156- Finding
Broker credentials and OAuth tokens are stored in plaintext without enforced access controls
- Content
View full analysis
None: """Save tokens to file with metadata""" tokens['saved_at'] = datetime.now().isoformat() tokens['config_path'] = self.config_path os.makedirs(os.path.dirname(self.tokens_file), exist_ok=True) with open(self.tokens_file, 'w') as f: json.dump(tokens, f, indent=2) print(f"✅ Tokens saved to {self.tokens_file}") ``` ```python # src/clawback/database.py:92-105 CREATE TABLE IF NOT EXISTS broker_tokens ( id INTEGER PRIMARY KEY AUTOINCREMENT, broker TEXT NOT NULL, account_id TEXT, access_token TEXT NOT NULL, access_secret TEXT, refresh_token TEXT, token_type TEXT DEFAULT 'oauth1', expires_at TIMESTAMP, last_refreshed TIMESTAMP DEFAULT CURRENT_TIMESTAMP, ...[truncated 3154 chars]- Remediation
View remediation
