T09 · Insecure Skill Coding Practices
- Location
scripts/delete_listings_item.py:40- Finding
Unvalidated endpoint overrides can disclose API credentials and seller data
- Content
View full analysis
dict: api_key = get_api_key() data = json.dumps(params).encode("utf-8") req = Request( endpoint, data=data, headers={ "Authorization": api_key, "Content-Type": "application/json", "User-Agent": "LinkFox-Skill/1.0", "SESSION_ID": os.environ.get("SESSION_ID", ""), "MESSAGE_ID": os.environ.get("MESSAGE_ID", ""), "MODE_ID": os.environ.get("MODE_ID", ""), "APP_NAME": os.environ.get("APP_NAME", ""), }, method="POST", ) try: with urlopen(req, timeout=150) as response: return json.loads(response.read().decode("utf-8")) ``` Onboarding uses the same trust model for more sensitive authentication material: ```python def _agent_base() -> str: return _env_base("LINKFOX_AGENT_API_URL", "ht ...[truncated 3001 chars]- Remediation
View remediation
