Back to skill

Security audit

Aj Gog

Security checks for vulnerabilities and agentic risk

Overview

This skill is a coherent Google Workspace CLI helper, but it asks users to install a mutable third-party CLI and grant broad account access that can read and modify sensitive Google data.

Review the Homebrew tap and gog project before installing, grant only the Google services you actually need, protect the OAuth client secret and generated tokens, and be especially careful with commands that send email or modify/clear Sheets data.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:5
Finding

Unpinned CLI Installation from a Third-Party Homebrew Tap

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, line 5
Vulnerability Type: Unpinned third-party dependency from a mutable package source
Risk Level: Medium

Vulnerable Code:

yaml
metadata: {"clawdbot":{"emoji":"🎮","requires":{"bins":["gog"]},"install":[{"id":"brew","kind":"brew","formula":"steipete/tap/gogcli","bins":["gog"],"label":"Install gog (brew)"}]}}

Technical Analysis

The skill directs installation of gogcli from the third-party Homebrew tap steipete/tap without pinning an immutable version, source commit, checksum, or cryptographic signature. The behavior of future installations therefore depends on mutable content maintained outside this project.

This creates a supply-chain trust boundary that cannot be validated from the audited files. A compromise of the tap, formula, upstream release location, or maintainer account could cause a modified executable to be installed under the expected gog command name.

The resulting exposure is elevated because the documented setup instructs users to provide OAuth client credentials and authorize access to Gmail, Calendar, Drive, Contacts, Sheets, and Docs. The project itself contains no bundled malicious code, and exploitation requires compromise or malicious modification of the external dependency source.

Attack Path

  1. An attacker compromises the third-party Homebrew tap, its maintainer account, the formula's upstream artifact location, or another component of its release pipeline.
  2. The attacker modifies the formula or referenced artifact so that it installs a malicious executable as gog.
  3. A user installs or upgrades the dependency through the skill's declared Homebrew installation entry.
  4. Following the documented setup, the user supplies an OAuth client-secret file and authorizes one or more Google Workspace services.
  5. The malicious executable captures authorization material or abuses the granted API permissions while appea ...[truncated 726 chars]
Remediation
View remediation

Remediation Suggestions

  • Pin the CLI to a reviewed, immutable release version rather than accepting the latest formula state.
  • Verify downloaded artifacts using a trusted cryptographic signature or a SHA-256 checksum obtained through an independent trusted channel.
  • Document the exact source repository, release artifact, expected digest, and verification procedure.
  • Prefer an official or reproducible distribution channel when one is available.
  • Review the Homebrew formula and upstream source before approving installation or upgrades.
  • Apply least privilege to OAuth authorization by requesting only the services and scopes required for the intended operation.
  • Use a dedicated Google account or restricted organizational account for automation where practical.
  • Protect OAuth credential and token files with restrictive filesystem permissions, and revoke tokens immediately if dependency compromise is suspected.
  • Require explicit review before dependency upgrades so that a mutable upstream release cannot be introduced automatically.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (3)

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

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

Content

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

md
Use `gog` for Gmail/Calendar/Drive/Contacts/Sheets/Docs. Requires OAuth setup.

Setup (once)
- `gog auth credentials /path/to/client_secret.json`
- `gog auth add you@gmail.com --services gmail,calendar,drive,contacts,sheets,docs`
- `gog auth list`

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

This markdown file instructs the user to supply a client_secret.json file and authorize broad Google Workspace services, which affects account privacy and access. While the file notes that OAuth setup is required, it does not warn users that the credentials file is sensitive or that the authorization grants access across Gmail, Calendar, Drive, Contacts, Sheets, and Docs.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The skill documentation includes commands that send email, update/append/clear Sheets data, and export documents to local files. Although L36 mentions confirming before sending mail or creating events, there is no warning covering sheet modifications, file output, or the broader impact of these commands on user data and system state.

Content

No source excerpt is available for this finding.