T08 · Insecure Dependencies
Warning
- Location
- README.md:18
- Finding
- Unpinned Third-Party Executable Receives Reusable X/Twitter Session Credentials<![CDATA[ ## Vulnerability Details **File Location**: `README.md:18-33` **Vulnerability Type**: Unpinned third-party dependency with access to authentication credentials **Risk Level**: Medium ### Vulnerable Code ```markdown 1. **Install bird** — X/Twitter CLI tool (by founder of OpenClaw) ```bash # Via Homebrew (macOS/Linux) brew install steipete/tap/bird # Or download from releases (if brew doesn't work) # https://github.com/steipete/bird/releases ``` 2. **Get X credentials:** - Auth token (`X_AUTH_TOKEN`) - CT0 cookie (`X_CT0`) 3. **Verify access:** ```bash bird whoami --auth-token "$X_AUTH_TOKEN" --ct0 "$X_CT0" ``` ``` A corresponding credential invocation also appears at `SKILL.md:12-20`: ```markdown **Environment variables:** ```bash export X_AUTH_TOKEN="your_twitter_auth_token" export X_CT0="your_twitter_ct0_cookie" ``` **Verify:** ```bash bird whoami --auth-token "$X_AUTH_TOKEN" --ct0 "$X_CT0" ``` ``` ### Technical Analysis The installation instructions retrieve the current version of the external `bird` executable through a mutable Homebrew tap or a release-download page. They do not pin a reviewed version, require an immutable artifact digest, or instruct the user to verify a signature or checksum. The installed executable is subsequently provided with `X_AUTH_TOKEN` and `X_CT0`. These values represent reusable X/Twitter session credentials. Environment variables reduce accidental command-history exposure, but they do not protect credentials from the process receiving them. The invoked executable can read its arguments, process environment, and accessible account data. Consequently, compromise of the upstream repository, Homebrew tap, release artifact, maintainer account, or a future dependency version could convert the documented command into a credential-theft path. No malicious behavior was found in the project itself; the risk is introduced through the mutable external dependency and its privil ...[truncated 1360 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Pin the external CLI to a specific, reviewed release instead of installing the latest mutable version. 2. Publish the expected SHA-256 or stronger digest for each supported platform and require verification before execution. 3. Verify upstream release signatures where supported, and document the expected signing identity. 4. Prefer a trusted package source with reproducible builds and provenance attestations. 5. Record the reviewed dependency version in the project and define an explicit dependency-update review process. 6. Use the least-privileged authentication method supported by X/Twitter instead of reusable browser-session cookies where possible. 7. Use a dedicated account with minimal privileges for automated scanning. 8. Run the CLI in a restricted environment with minimal filesystem and network access. 9. Rotate `X_AUTH_TOKEN` and `X_CT0` after suspected dependency compromise, and document a credential-revocation procedure. 10. Avoid exposing credentials as command-line arguments if the CLI supports a protected credential file, operating-system key store, or restricted standard-input mechanism. ]]>
