Back to skill

Security audit

agent-desktop-ffi

Security checks for vulnerabilities and agentic risk

Overview

This skill is documentation for a desktop automation FFI, and its sensitive behaviors are disclosed and aligned with that purpose.

Install only if you intend to use an FFI that can observe and control desktop UI through the host process. Treat snapshots, error details, log callbacks, clipboard reads, screenshots, and optional trace files as sensitive; enable tracing deliberately and review or delete files under ~/.agent-desktop/sessions/<id>/trace when no longer needed.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (2)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill documents that session tracing can write JSONL activity logs to ~/.agent-desktop/sessions//trace when a session manifest enables tracing, but this privacy-relevant behavior is easy to miss in the main usage flow. Because traces may persist user activity and other sensitive automation metadata to disk, consumers embedding the FFI could enable or inherit tracing without giving end users an obvious warning, retention policy, or storage control.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
90% confidence
Finding

The documented behavior creates persistent per-session trace files under a stable directory in the user's home folder when tracing is active. Even though tracing is not enabled by ad_adapter_create_with_session alone, the session-based persistence can still retain sensitive command history, application context, and timing data across runs, increasing exposure to local attackers, shared accounts, backups, or accidental collection by other software.

Content

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

md
- **Structured session trace (no ABI change).** File-based JSONL tracing activates
  only when the session has a manifest with `trace: on` from `session start`
  (CLI) or equivalent on-disk setup. `ad_adapter_create_with_session` alone does
  **not** create trace files. When tracing is active, `command_context()`-backed
  commands append to one segment per OS process under
  `~/.agent-desktop/sessions/<id>/trace/<pid>-<procTs>.jsonl`. A long-lived host
  reuses the same segment filename for all calls in that process. For unstructured

Static analysis

No suspicious patterns detected.