T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:303- Finding
GCP Metadata Service Instructions Expose Temporary Credentials and Sensitive Instance Data
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This documentation-only skill is not hiding executable code, but it promotes high-risk OpenClaw and GCP operations that can expose credentials, disable authentication, and grant full host access.
Treat this as Review-only material for experienced OpenClaw/GCP operators, not as a general agent skill. Do not run the auth-bypass, /elevated full, OPENCLAW_SHOW_SECRETS, full-payload logging, debug proxy, or GCP metadata token/SSH-key commands on real systems unless you are in an isolated, authorized diagnostic environment with short retention and secret cleanup. Keep device auth enabled, avoid broad trusted-proxy ranges, and pin/review MCP packages before use.
SKILL.md:303GCP Metadata Service Instructions Expose Temporary Credentials and Sensitive Instance Data
SKILL.md:47Skill Promotes Full Host Execution Through Elevated Agent Mode
SKILL.md:124Authentication Bypass and Elevated-Scope Configuration Weaken Gateway Access Controls
SKILL.md:155Debug Configuration Intentionally Exposes Secrets, Environment Variables, Conversations, and Network Traffic
SKILL.md:260Unpinned Third-Party MCP Packages Are Downloaded and Executed Through npx
The documented environment variable explicitly enables unredacted secret display in output, alongside high-verbosity/debug options. This creates a direct path to plaintext credential exposure in terminals, logs, screenshots, CI output, or shared support artifacts.
The 'ultimate cheat code' intentionally combines settings for unredacted secrets, full model payload logging, cache tracing, and maximum verbosity. This is an explicit recipe for comprehensive exposure of credentials, prompts, responses, and potentially regulated data, making compromise or leakage highly likely.
The memory preload and verbose/history-related features increase the amount of prior context and potentially sensitive content automatically surfaced to future sessions. In an agent skill, this raises the risk of inadvertent disclosure, over-retention, and propagation of secrets or private user data beyond the original context.
The skill describes device-auth bypass and privileged control options as usable configuration guidance, including a statement that bypass is already enabled on the node. Presenting authentication disablement and elevated scopes without prominent safety constraints increases the chance of unauthorized administrative access.
This section documents settings that explicitly expose secrets and sensitive model payloads, but does not consistently frame them as dangerous, temporary diagnostics-only features with strict handling requirements. In a skill context, such guidance can normalize unsafe operation and lead users or agents to disclose credentials, prompts, or private data in logs and output.
Trajectory and raw-stream capture to disk can record full user prompts, model outputs, tool arguments, tokens, and other sensitive interaction contents. Without strict safeguards, this creates durable local exfiltration and privacy risks well beyond transient debugging.
This section gives direct instructions for querying the GCP metadata service to obtain access tokens, startup scripts, and SSH keys, while marketing it as a 'god key' and minimizing sensitivity. In practice, this is credential-access guidance that can enable cloud compromise and lateral movement if followed from a privileged VM.
The skill explicitly instructs readers to obtain a live GCP access token from the instance metadata service. That is direct credential-access guidance and can immediately enable unauthorized API access under the VM's service account privileges.
On any GCP VM, this API gives you:
# Get a live, auto-rotating access token — NO KEY FILE NEEDED
curl -s -H "Metadata-Flavor: Google" \
http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/token
This is explicit guidance to access the cloud metadata endpoint for a service-account token, a classic high-impact SSRF target. In any agent or tool-capable environment, such instructions materially increase the risk of credential theft via internal request capabilities.
# Get a live, auto-rotating access token — NO KEY FILE NEEDED
curl -s -H "Metadata-Flavor: Google" \
http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/token
# Get the service account email
curl -s -H "Metadata-Flavor: Google" \
The metadata email lookup reveals the active service account identity, which supports privilege enumeration and targeted follow-on abuse. While less severe than token retrieval, it is still sensitive internal metadata that should not be promoted in a general skill.
# Get the service account email
curl -s -H "Metadata-Flavor: Google" \
http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/email
# Get scopes (what this SA can do)
curl -s -H "Metadata-Flavor: Google" \
Querying metadata scopes aids attackers in understanding what the attached service account can access, enabling efficient privilege exploitation. In combination with token retrieval guidance in the same section, this materially supports cloud compromise.
# Get scopes (what this SA can do)
curl -s -H "Metadata-Flavor: Google" \
http://metadata.google.internal/computeMetadata/v1/instance/service-accounts/default/scopes
# Get startup script (may contain secrets)
curl -s -H "Metadata-Flavor: Google" \
The startup-script metadata path may expose embedded secrets, bootstrap credentials, or sensitive infrastructure logic. Documenting this as a cheat code directly encourages secret harvesting from privileged cloud instances.
# Get startup script (may contain secrets)
curl -s -H "Metadata-Flavor: Google" \
http://metadata.google.internal/computeMetadata/v1/instance/attributes/startup-script
# Get SSH keys
curl -s -H "Metadata-Flavor: Google" \
The project SSH keys metadata path can reveal credentials or authorized access material for broader infrastructure access. Including it in an offensive-style cheat-sheet context substantially increases risk of unauthorized access and lateral movement.
curl -s -H "Metadata-Flavor: Google"
http://metadata.google.internal/computeMetadata/v1/project/attributes/sshKeys
**This is the biggest cheat code in GCP.** Every VM has this. The token auto-rotates every hour. No key files. No secrets manager. Just the metadata service.
The documentation encourages direct use of short-lived access tokens in shell commands without sufficient warnings about handling, exposure in shell history, process listings, or logs. While legitimate in some admin workflows, presenting it casually in this skill increases the chance of credential leakage.
# Get a 1-hour access token (no JSON key file needed)
gcloud auth print-access-token
# Use it directly
The non-interactive repair command with auto-approval enables autonomous configuration changes without human review. In a powerful system-management skill, this can amplify mistakes or malicious prompting into unauthorized or destructive reconfiguration.
openclaw crestodian --json # Full system state as JSON openclaw crestodian -m "fix my config" --yes # Non-interactive repair
The meta-controller that can reconfigure the entire system. `--yes` auto-approves config writes.
### Doctor Deep Scan
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
Enable these and any node (or external service) can call the gateway like an OpenAI-compatible API:
```bash
curl http://127.0.0.1:18789/v1/chat/completions \
-H "Authorization: Bearer <gateway-token>" \
-H "Content-Type: application/json" \
-d '{"model":"openclaw","messages":[{"role":"user","content":"hello"}]}'
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
openclaw sandbox list # List containers
openclaw sandbox explain # Explain effective policy
openclaw sandbox recreate # Force container rebuild
This cross-node chat example normalizes sending authenticated requests across sibling IPs in the mesh, expanding the trust boundary and creating opportunities for token misuse, interception, or lateral movement if network segmentation is weak. In this skill's broader 'mesh' context, cross-node invocation is more dangerous than a local loopback example.
curl http://<sibling-ip>:18789/v1/chat/completions \
-H "Authorization: Bearer <gateway-token>" \
-H "Content-Type: application/json" \
-d '{"model":"openclaw","messages":[{"role":"user","content":"ping"}]}'
No suspicious patterns detected.