Back to skill

Security audit

commit

Security checks for vulnerabilities and agentic risk

Overview

This skill does exactly what it advertises, but it can automatically commit and push all repository changes, including unreviewed new files, to a remote.

Install only if you want an agent to publish the current repository branch for you. Before using it, manually check untracked files, secrets, generated artifacts, and the target remote/branch, because the skill does not require a final approval step before pushing.

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
SKILL.md:9
Finding

Unreviewed untracked files may be committed and pushed to a remote repository

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 9-20
Vulnerability Type: Unsafe bulk staging and remote publication of unreviewed files
Risk Level: Medium

Vulnerable Code Snippet:

markdown
- Current git status: !`git status`
- Current git diff (staged and unstaged changes): !`git diff HEAD`
- Current branch: !`git branch --show-current`
- Recent commits: !`git log --oneline -10`

## Your task

Based on the above changes, stage everything, create one commit with a contextual message, and push the current branch.

Required sequence:
1. Stage changes.
2. Create a single commit.
3. Push the current branch to origin (use `--set-upstream origin <branch>` if needed).

Technical Analysis

The Skill directs the agent to stage every working-tree change and push the resulting commit to origin. Its review context uses git diff HEAD, which displays tracked changes but does not show the contents of untracked files. Although git status identifies untracked paths, it does not provide enough information to determine whether those files contain credentials, private data, generated artifacts, or unrelated content.

As a result, untracked files can be added to the commit without a content-level security review. The mandatory push then publishes those files using the invoking user's existing Git credentials. The behavior violates least-change principles and creates a potential data-exposure path. This finding does not represent privilege escalation: its scope is limited to repositories and remotes that the current user is already authorized to modify.

Attack Path

  1. An attacker, compromised development tool, or accidental local operation places an untracked file in the repository.
  2. The file contains sensitive information or other content that should not be published, such as an API key, environment file, private certificate, database export, or generated artifact.
  3. The Skill eva ...[truncated 1136 chars]
Remediation
View remediation

Remediation Suggestions

  1. Replace bulk staging with explicit staging of individually reviewed paths.
  2. Enumerate all candidate files using a machine-readable command such as git status --porcelain=v1 -z.
  3. Inspect tracked changes and the contents of every untracked file before staging. Do not rely solely on git diff HEAD.
  4. Reject or require explicit approval for files commonly associated with secrets or private data, including .env files, private keys, credential stores, database dumps, and cloud configuration files.
  5. Run an approved secret scanner against the exact staged snapshot before creating the commit.
  6. Review the staged result with git diff --cached and verify the staged file list before committing.
  7. Require user confirmation before pushing, particularly when new files, binary files, sensitive paths, or upstream-branch changes are involved.
  8. Ensure generated artifacts and local configuration files are covered by an appropriate .gitignore.
  9. If sensitive material has already been pushed, revoke and rotate affected credentials, remove the material from repository history where appropriate, and assess remote clones, forks, caches, and CI logs for further exposure.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (1)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill instructs the agent to stage all changes, create a commit, and push to origin automatically, which can modify repository state and publish code or secrets without an explicit user confirmation step. Because it uses full-repo context (git diff HEAD) and stage everything, it increases the risk of unintentionally committing unrelated, sensitive, or unsafe files and exfiltrating them to a remote.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.