T09 · Insecure Skill Coding Practices
- Location
scripts/client.py:6- Finding
Credentials and authenticated traffic can be transmitted over plaintext HTTP
- Content
View full analysis
Vulnerability Details
File Location:
scripts/client.py, lines 6-9 and 74-79
Vulnerability Type: Plaintext transmission of credentials and insecure default credentials
Risk Level: HighVulnerable Code
python MUMU_API_URL = os.getenv("MUMU_API_URL", "http://localhost:8000").rstrip("/") MUMU_USERNAME = os.getenv("MUMU_USERNAME", "admin") MUMU_PASSWORD = os.getenv("MUMU_PASSWORD", "admin123") DEFAULT_TIMEOUT = float(os.getenv("MUMU_HTTP_TIMEOUT", "60"))python def login(self): url = f"{MUMU_API_URL}/api/auth/local/login" data = { "username": MUMU_USERNAME, "password": MUMU_PASSWORD } resp = self.session.post(url, json=data, timeout=DEFAULT_TIMEOUT)Technical Analysis
The API URL is fully controlled through
MUMU_API_URL, but the client does not validate its scheme or restrict plaintext HTTP to loopback addresses. The login function sends the configured username and password directly to that destination as JSON.Although the default URL points to localhost, an operator may configure a remote HTTP endpoint. In that configuration, credentials, session cookies, project content, chapter rewrites, lore, and other API traffic lack transport confidentiality and integrity. A network-positioned attacker can observe or alter the traffic.
The hardcoded fallback credentials (
admin/admin123) are an additional insecure default. If the corresponding server retains these credentials, an attacker may authenticate without learning an operator-defined secret.This network communication is necessary for the declared MuMu API integration, but permitting unencrypted remote authentication and supplying predictable fallback credentials exceed safe minimum requirements.
Attack Path
- The Skill is deployed with a remote plaintext URL such as
MUMU_API_URL=http://api.example.test:8000. - The operator invokes any script that constructs
MumuClient. - The client first checks `/api/users/m ...[truncated 1151 chars]
- The Skill is deployed with a remote plaintext URL such as
- Remediation
View remediation
Remediation Suggestions
- Require
https://for every non-loopback API endpoint. - Permit
http://only for explicit loopback destinations such aslocalhost,127.0.0.1, and::1. - Reject unsupported schemes, embedded URL credentials, and malformed destinations before creating a client.
- Remove the
adminandadmin123fallbacks. Fail closed when credentials are not explicitly configured. - Prefer short-lived API tokens or scoped service credentials over reusable account passwords.
- Preserve TLS certificate verification and do not add a configuration option that silently disables it.
- Document that the Skill transmits novel content and authentication information to the configured MuMu API.
- Rotate any credentials that may already have been used over plaintext HTTP.
- Require
