T09 · Insecure Skill Coding Practices
Warning
- Location
- skill.md:78
- Finding
- TLS Certificate Verification Disabled for FlyAI Requests## Vulnerability Details **File Location**: `skill.md`, lines 73 and 78–125 **Vulnerability Type**: TLS certificate validation bypass **Risk Level**: Medium The skill explicitly recommends setting `NODE_TLS_REJECT_UNAUTHORIZED=0` and includes this setting in every FlyAI command example. ```bash NODE_TLS_REJECT_UNAUTHORIZED=0 flyai search-hotels \ --dest-name "[destination]" \ --check-in-date [check-in date] \ --check-out-date [check-out date] \ --max-price [budget limit] \ --sort rate_desc ``` The same environment variable is applied to the documented `search-poi` and `search-flight` commands at lines 101–125. ### Technical Analysis `NODE_TLS_REJECT_UNAUTHORIZED=0` instructs Node.js to accept TLS certificates without validating their trust chain or hostname. Consequently, the client cannot reliably authenticate the remote FlyAI endpoint. Although the surrounding documentation describes this as a workaround for certificate errors, the bypass is embedded directly into every example and is therefore presented as the normal execution path. Disabling verification affects the confidentiality and integrity guarantees normally supplied by TLS. Encryption may still occur, but it can terminate at an attacker-controlled endpoint presenting an arbitrary certificate. ### Attack Path 1. A user asks the agent to search for a hotel, attraction, or flight. 2. The agent executes the documented command with `NODE_TLS_REJECT_UNAUTHORIZED=0`. 3. An attacker with a network interception position, malicious proxy, compromised DNS path, or control of a relevant network gateway redirects the connection. 4. The attacker presents an untrusted certificate, which the Node.js client accepts. 5. The attacker observes travel-search parameters or modifies API responses. 6. The agent may present manipulated prices, availability, flight details, hotel data, or attraction results as legitimate FlyAI output. ### Impact Assessment ...[truncated 538 chars]
- Remediation
- ## Remediation Suggestions - Remove `NODE_TLS_REJECT_UNAUTHORIZED=0` from every command example. - Treat certificate validation failures as fatal rather than silently bypassing them. - Repair the host's CA trust store or configure the legitimate service CA through an appropriately scoped mechanism such as `NODE_EXTRA_CA_CERTS`. - Do not disable TLS verification globally for the process. - If a private certificate authority is required, pin or explicitly trust only the intended CA certificate after securely verifying it. - Log certificate failures without exposing request secrets, and instruct the user or operator to correct the trust configuration before retrying.
