Back to skill

Security audit

Ekybot Connector

Security checks for vulnerabilities and agentic risk

Overview

This connector mostly matches its remote-agent-management purpose, but it gives Ekybot broad background control over local agents and contains consent and deletion-safety issues that require review before use.

Install only if you are comfortable giving Ekybot background access to manage local OpenClaw agents and relay prompts into them. Use a low-privilege account, back up OpenClaw workspaces, avoid running the daemon with sudo, restrict tools available to remotely reachable agents, review memory files before enabling sync, and verify/disable background services after setup.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • System PersistenceInstalls backdoors, hooks, services, or scheduled tasks that survive the run
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
Findings (4)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
runtime/src/config-manager.js:413
Finding

Cloud-Controlled Recursive Workspace Deletion Uses an Insufficient Path Boundary Check

Content
View full analysis
Remediation
View remediation

T01 · Skill Instruction Hijacking

Error
Location
runtime/src/companion-relay-processor.js:105
Finding

Untrusted Cloud Relay Messages Are Injected Directly into Local Agent Prompts

Content
View full analysis
Remediation
View remediation

T06 · System Persistence

Warning
Location
scripts/setup.sh:151
Finding

Setup Starts a Background Daemon After the User Declines Daemon Installation

Content
View full analysis
&1 echo "✅ macOS LaunchAgent installed" else echo " Starting daemon in background..." mkdir -p "$HOME/.openclaw/logs" nohup npm run companion:daemon > "$HOME/.openclaw/logs/ekybot-companion.log" 2>&1 & echo "✅ Daemon started (PID: $!)" echo " Logs: $HOME/.openclaw/logs/ekybot-companion.log" fi ;; *) echo " Skipped daemon install. Start manually with:" echo " cd $CONNECTOR_DIR && npm run companion:daemon" ;; esac # ── Step 7: Verify daemon is running ───────────────────────────────── echo "" echo "🔍 Verifying daemon is running..." sleep 3 if pgrep -f companion-daemon > /dev/null 2>&1; then echo "✅ Daemon is running (PID: $(pgrep -f companion-daemon | head -1))" else echo "⚠️ Daemon does NOT appear to be running!" echo " Starting it now..." mkdir -p "$HOME/.openclaw/logs" nohup node scripts/companion-daemon.js > "$HOME/.openclaw/logs/ekybot-companion.log" 2>&1 & sleep 3 if pgrep -f companion-daemon > /dev/null 2>&1; then echo "✅ Daemon started (PID: $(pgrep -f companion-daemon | head -1))" else echo "❌ Daemon failed to start. Check logs:" echo " tail -20 $HOME/.openclaw/logs/ekybot-companion.log" echo "" echo " ⛔ Installation is INCOMPLETE — the daemon must be running for Ekybot to work." exit 1 fi fi ``` ### Technical Analysis The setup script asks whether the user wants to install a background daemon. If the user answers negat ...[truncated 1688 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
runtime/scripts/companion-install-launchd.js:17
Finding

Unescaped Path Values Are Embedded in a LaunchAgent XML File

Content
View full analysis
Label com.ekybot.companion ProgramArguments ${nodePath} ${daemonScript} WorkingDirectory ${workingDirectory} EnvironmentVariables EKYBOT_COMPANION_ENV_FILE ${envFilePath} RunAtLoad KeepAlive StandardOutPath ${stdoutPath} StandardErrorPath ${stderrPath} `; } async function installLaunchdService() { const daemonScript = ensureSafePath( path.join(process.cwd(), 'scripts', 'companion-daemon.js'), 'daemon script path' ); const nodePath = ensureSafePath(process.execPath, 'node path'); const workingDirectory = ensureSafePath(process.cwd(), 'working directory'); const envFilePath = ensureSafePath(resolveEnvFilePath(), 'env file path'); const plistPath = path.join( os.homedir(), 'Library', 'LaunchAgents', 'com.ekybot.companion.plist' ); fs.mkdirSync(path ...[truncated 2153 chars]
Remediation
View remediation
`, `"`, and `'`. 3. Canonicalize all paths and validate that they are absolute where required. 4. Restrict `EKYBOT_COMPANION_ENV_FILE` to an expected connector-owned directory unless the user explicitly approves another location. 5. Validate the generated file using `plutil -lint` before instructing the user to load it. 6. Write the plist atomically with restrictive permissions. 7. Add tests using directory and environment-file names containing ampersands, angle brackets, quotes, spaces, and Unicode characters. ]]>
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Memory PoisoningPersistent Context Injection, Context Window Stuffing, Memory Manipulation
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
Findings (140)

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

If the packaged runtime creates agent workspaces, modifies OpenClaw configuration, restarts the gateway, and creates remote channels, those are materially broader and more invasive actions than a simple connector setup description implies. Such behavior can alter local agent topology and remote collaboration state, which increases blast radius beyond basic enrollment or health monitoring.

Content

No source excerpt is available for this finding.

Credential Access

High
Category
Privilege Escalation
Confidence
88% confidence
Finding

The code stores an API key in a project-local .env file under process.cwd(). Even with mode 0600, this is risky because project directories are commonly committed, copied, backed up, or exposed to other tooling, which can lead to credential disclosure and unauthorized remote control of the connected service.

Content

Scanner excerpt · runtime/src/auth.js (reported line 8)May include surrounding context.

js
class AuthManager {
  constructor() {
    this.tokenFile = path.join(process.cwd(), '.ekybot-token');
    this.configFile = path.join(process.cwd(), '.env');
  }

  // Load API token from environment or token file

Credential Access

High
Category
Privilege Escalation
Confidence
82% confidence
Finding

Reading credentials from a project .env file means any user or process with access to the working directory contents can recover the token. In this connector context, the token appears to enable remote agent control and memory sync, so exposure could let an attacker access or control external systems tied to the account.

Content

Scanner excerpt · runtime/src/auth.js (reported line 18)May include surrounding context.

js
return process.env.EKYBOT_API_KEY;
    }

    // Try .env file
    if (fs.existsSync(this.configFile)) {
      const envContent = fs.readFileSync(this.configFile, 'utf8');
      const match = envContent.match(/EKYBOT_API_KEY=(.+)/);

Credential Access

High
Category
Privilege Escalation
Confidence
91% confidence
Finding

The function explicitly saves the API token to .env, creating persistent plaintext credential storage in the current working directory. In a tool that connects to a remote control service, theft of this token could enable unauthorized access, impersonation, or manipulation of agent operations and synced project memory.

Content

Scanner excerpt · runtime/src/auth.js (reported line 35)May include surrounding context.

js
return null;
  }

  // Save API token to .env file
  saveToken(token) {
    try {
      let envContent = '';

Credential Access

High
Category
Privilege Escalation
Confidence
80% confidence
Finding

Reading and rewriting the entire .env file to manage the API key increases the chance that secrets remain in an insecure, broadly accessible project artifact. This also normalizes storing operational credentials alongside application configuration, which is dangerous in shared development environments and CI/CD workspaces.

Content

Scanner excerpt · runtime/src/auth.js (reported line 40)May include surrounding context.

js
try {
      let envContent = '';

      // Read existing .env if it exists
      if (fs.existsSync(this.configFile)) {
        envContent = fs.readFileSync(this.configFile, 'utf8');
      }

Self-Modification

High
Category
Rogue Agent
Confidence
85% confidence
Finding

Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.

Content

Scanner excerpt · scripts/configure-relay.sh (reported line 46)May include surrounding context.

sh
echo "  --agents <number>     Number of agents to setup (default: 2)"
    echo "  --preset <type>       Agent preset: personal|team|enterprise (default: personal)"
    echo "  --dry-run            Show what would be done without making changes"
    echo "  --force              Overwrite existing configuration"
    echo "  --help               Show this help"
}

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · scripts/configure-relay.sh (reported line 315)May include surrounding context.

sh
" > /tmp/agents_config.json
    
    agents_json=$(cat /tmp/agents_config.json)
    rm -f /tmp/agents_config.json
    
    # Create new configuration
    if [[ -f "$OPENCLAW_CONFIG" ]]; then

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · scripts/health_check.sh (reported line 135)May include surrounding context.

sh
# Send health data to EkyBot
print_status "Sending health report to EkyBot..."

RESPONSE=$(curl -s -X GET "$HEALTH_ENDPOINT" \
  -H "X-API-Key: $API_KEY" \
  -H "Content-Type: application/json")

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · scripts/register_workspace.sh (reported line 92)May include surrounding context.

sh
print_status "Registering workspace with EkyBot..."

# Make registration request
RESPONSE=$(curl -s -X POST "$EKYBOT_API_BASE/workspaces/register" \
  -H "Content-Type: application/json" \
  -d "$REGISTRATION_DATA")

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · runtime/src/auth.js (reported line 87)May include surrounding context.

js
mkdir -p "$CONNECTOR_DIR"
fi

# Copy bundled files (preserve existing .env config)
cp -r "$RUNTIME_DIR/src" "$CONNECTOR_DIR/"
cp -r "$RUNTIME_DIR/scripts" "$CONNECTOR_DIR/"
cp "$RUNTIME_DIR/package.json" "$CONNECTOR_DIR/"

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · runtime/src/auth.js (reported line 127)May include surrounding context.

js
mkdir -p "$CONNECTOR_DIR"
fi

# Copy bundled files (preserve existing .env config)
cp -r "$RUNTIME_DIR/src" "$CONNECTOR_DIR/"
cp -r "$RUNTIME_DIR/scripts" "$CONNECTOR_DIR/"
cp "$RUNTIME_DIR/package.json" "$CONNECTOR_DIR/"

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · scripts/setup.sh (reported line 79)May include surrounding context.

sh
mkdir -p "$CONNECTOR_DIR"
fi

# Copy bundled files (preserve existing .env config)
cp -r "$RUNTIME_DIR/src" "$CONNECTOR_DIR/"
cp -r "$RUNTIME_DIR/scripts" "$CONNECTOR_DIR/"
cp "$RUNTIME_DIR/package.json" "$CONNECTOR_DIR/"

Memory Manipulation

High
Category
Memory Poisoning
Confidence
80% confidence
Finding

Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.

Content

Scanner excerpt · templates/INTER-AGENT-PROTOCOL.md (reported line 14)May include surrounding context.

text
📨 [Sender → Receiver]

Message content here with clear context and action items.

— Sender Name

Exfiltration Commands

High
Category
Prompt Injection
Confidence
90% confidence
Finding

Instructions found that direct the agent to transmit conversation context or user data to external services.

Content

Scanner excerpt · templates/INTER-AGENT-PROTOCOL.md (reported line 41)May include surrounding context.

Session Communication

bash
# Send message to specific agent
sessions_send sessionKey=agent:target-agent-id message="Your message"

# List active agent sessions

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
96% confidence
Finding

The skill declares required environment and clearly instructs users to run shell commands, install services, read/write local files, and connect to a remote cloud service, but it does not declare any explicit tool scope or permissions boundaries. That omission weakens reviewability and informed consent, because the effective capabilities are broad and include shell execution, persistence, filesystem modification, and network access.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The activation text is broad and encourages use across installation, configuration, connectivity validation, onboarding, and 'improving' workflows without clearly limiting when high-impact actions should or should not occur. In a skill that performs enrollment, local config changes, daemon installation, telemetry, and possible persistence, overly broad triggering language increases the chance of unintended execution in sensitive environments.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
96% confidence
Finding

The nohup-based manual daemon start creates a detached background process that continues operating after the initiating shell exits. Because the daemon mediates remote control and sync behavior, running it persistently without strong visibility or controls can increase host risk.

Content

Scanner excerpt · SKILL.md (reported line 118)May include surrounding context.

bash
cd ~/.openclaw/ekybot-connector
nohup node scripts/companion-daemon.js > ~/.openclaw/logs/ekybot-companion.log 2>&1 &
mkdir -p ~/.openclaw/logs
sleep 3 && tail -10 ~/.openclaw/logs/ekybot-companion.log

Static analysis

Detected: suspicious.env_credential_access, suspicious.exposed_secret_literal

Environment variable access combined with network send.

Critical
Code
suspicious.env_credential_access
Location
runtime/src/companion-api-client.js:39

Environment variable access combined with network send.

Critical
Code
suspicious.env_credential_access
Location
runtime/src/openclaw-gateway-client.js:26

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
references/api.md:16