Back to skill

Security audit

Antigravity Bridge

Security checks for vulnerabilities and agentic risk

Overview

The skill is a local Markdown sync bridge, but its custom path handling and recommended scheduled syncing create review-worthy risk around unintended indexing or writes outside the intended workspace.

Install only if you trust and control the YAML config. Use --dry-run first, keep destination as a simple workspace subfolder, avoid .. or unusual names in any path fields, and review every synced Markdown directory for secrets, prompts, private docs, or proprietary content before adding it to memorySearch.extraPaths or cron.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Warning
Location
sync.sh:182
Finding

Unvalidated Configuration Paths Permit Repository Read and Workspace Write Escapes

Content
View full analysis
/dev/null || echo 0) path_count="${path_count:-0}" local i=0 while [[ $i -lt $path_count ]]; do local rel_path rel_path=$(yq eval ".projects[] | select(.name == \"$name\") | .paths[$i]" "$CONFIG") i=$((i + 1)) local src="$repo/$rel_path" ``` Additional affected destination construction: ```bash local dst="$destination/$name" ``` ```bash local dest_rel dest_rel=$(yq eval '.destination // "antigravity"' "$CONFIG") local destination destination="$WORKSPACE_DIR/$(expand_path "$dest_rel")" ``` ### Technical Analysis The script obtains `destination`, project and knowledge `name` values, and project `paths` from a YAML configuration file and concatenates them directly into filesystem paths. It does not reject absolute values, `..` traversal components, or symlink-based escapes, and it does not canonicalize the resulting paths before using `mkdir` and `rsync`. Consequently: - A project path such as `../../outside.md` can resolve outside the configured repository and be copied if the resulting source is an existing Markdown file. - A project or knowledge name containing traversal components can cause the destination to escape its intended project directory. - A traversal value in `destination` can resolve outside the OpenClaw workspace. - Existing user-writable files at a resolved destination may be overwritten by `rsync`. Shell quoting prevents ordinary command injection through these values, but it does not prevent filesystem traversal. Exploitation requires control over, or modification of, the YAML configuration used by the script. ...[truncated 1597 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • YARA SignaturesMalware Match, Webshell Match, Cryptominer Match
Findings (16)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The documented purpose claims a narrowly scoped bridge for Antigravity project documentation, but the configuration explicitly supports syncing arbitrary markdown from additional 'knowledge' paths and user-specified directories. That mismatch matters because operators may trust the safety claims and accidentally ingest sensitive markdown from outside the intended scope, increasing data exposure within the indexed workspace.

Content

No source excerpt is available for this finding.

YARA rule 'backdoor_persistence': Backdoor persistence with malicious payloads (shell commands, SSH key injection, hidden root users) [malware]

High
Category
YARA Match
Confidence
75% confidence
Finding

YARA rule matched a known malware signature (reverse shell, backdoor, ransomware, C2 framework, or info stealer).

Content

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

be synced, without making changes --verbose Show rsync output and detailed progress --help Show this help

text

Examples:

```bash
# Sync everything
sync.sh

# Sync one project only
sync.sh --project acme-platform

# Preview without touching files
sync.sh --dry-run --verbose

# Use a custom config
sync.sh --config ~/my-bridge.yaml

Cron Integration

Add to crontab (crontab -e) for automatic syncing:

cron
# Antigravity Bridge — hourly during business hours (Mon-Fri, 08:00-18:00)
0 8-18 * * 1-5 ~/.openclaw/workspace/skills/antigravity-bridge/sync.sh >> ~/.openclaw/logs/antigravity-bridge.log 2>&1

# Nightly full sync (all days, 02:00)
0 2 * * * ~/.openclaw/workspace/skills/antigravity-bridge/sync.sh --verbose >> ~/.openclaw/logs/antigravity-bridge.log 2>&1

Create the log directory first:

bash
mkdir -p ~/.openclaw/logs

Troubleshooting

yq: command not found Install yq: brew install yq (macOS) or see https://git

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The destination is built as WORKSPACE_DIR/$(expand_path dest_rel), but expand_path can return absolute paths or values containing traversal segments, causing the sync target to escape the intended OpenClaw workspace. An attacker or untrusted config could redirect synced content to arbitrary filesystem locations, leading to unintended overwrite or placement of indexed files outside the declared boundary.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
85% confidence
Finding

The skill recommends persistence through cron, causing repeated unattended execution that continuously imports content into the OpenClaw workspace. In context this is not a classic malware backdoor, but it does create durable automated data ingestion, which can amplify accidental syncing of sensitive markdown and make misconfiguration persistent.

Content

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

Cron Integration

Add to crontab (crontab -e) for automatic syncing:

cron
# Antigravity Bridge — hourly during business hours (Mon-Fri, 08:00-18:00)

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

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.

Content

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

0 2 * * * ~/.openclaw/workspace/skills/antigravity-bridge/sync.sh --verbose >> ~/.openclaw/logs/antigravity-bridge.log 2>&1

text

Create the log directory first:

```bash
mkdir -p ~/.openclaw/logs

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

rsync version 2.6.9 protocol version 29

text

If missing: `brew install rsync` (macOS) or `sudo apt install rsync`

### 2. yq (YAML parser — required)

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · setup.md (reported line 18)May include surrounding context.

rsync version 2.6.9 protocol version 29

text

If missing: `brew install rsync` (macOS) or `sudo apt install rsync`

### 2. yq (YAML parser — required)

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

md
brew install yq

# Ubuntu/Debian
sudo apt install yq

# Ubuntu snap
snap install yq

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · setup.md (reported line 34)May include surrounding context.

md
brew install yq

# Ubuntu/Debian
sudo apt install yq

# Ubuntu snap
snap install yq

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · sync.sh (reported line 94)May include surrounding context.

sh
brew install yq

# Ubuntu/Debian
sudo apt install yq

# Ubuntu snap
snap install yq

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · sync.sh (reported line 102)May include surrounding context.

sh
brew install yq

# Ubuntu/Debian
sudo apt install yq

# Ubuntu snap
snap install yq

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The guide explicitly encourages syncing repository markdown into OpenClaw's indexed memory workspace and then querying it with memory_search, but it does not prominently warn that markdown may contain sensitive internal documentation, prompts, credentials accidentally committed to docs, or other proprietary content. This can lead users to expose more repository data to indexing and retrieval than intended, especially because the feature is framed as routine and recommended.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
85% confidence
Finding

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.

Content

Scanner excerpt · setup.md (reported line 164)May include surrounding context.

Step 7: Set up cron (optional but recommended)

For continuous sync, add to your crontab (crontab -e):

cron
# Antigravity Bridge — hourly during business hours (Mon-Fri, 08:00-18:00)

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

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.

Content

Scanner excerpt · setup.md (reported line 174)May include surrounding context.

0 2 * * * ~/.openclaw/workspace/skills/antigravity-bridge/sync.sh --verbose >> ~/.openclaw/logs/antigravity-bridge.log 2>&1

text

Create the log directory:

```bash
mkdir -p ~/.openclaw/logs

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script supports syncing arbitrary 'knowledge' sources in addition to Antigravity project repositories, which exceeds the stated purpose of a one-directional Antigravity-to-OpenClaw bridge. This broadens the ingestion surface and can pull unrelated local documentation into the indexing workspace, undermining the trust boundary implied by the skill description.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script permits arbitrary local directories to be ingested as 'knowledge' sources, which is not necessary for a narrowly scoped Antigravity bridge. Even though only .md files are synced, this can still ingest sensitive internal documentation from unrelated locations into OpenClaw's searchable workspace.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.