Back to skill

Security audit

Fork Manager

Security checks for vulnerabilities and agentic risk

Overview

This is a coherent fork-management skill, but it grants high-impact automation over Git branches and permits configurable post-sync commands that users should review carefully.

Install only for repositories where you are comfortable giving an agent authority to fetch, rebase, merge, push, rewrite branches with --force-with-lease, and use your GitHub CLI credentials. Review each repo config before use, avoid enabling persistent autoResolveConflicts unless you accept automatic branch rewrites, and do not use postSyncHooks from untrusted configs.

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 (2)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:747
Finding

Unrestricted Execution of Repository-Defined Post-Sync Hooks

Content
View full analysis
/config.json`. 2. The attacker adds a malicious command to `post ...[truncated 1303 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:533
Finding

Semantic AI Conflict Resolutions Are Force-Pushed Before Human Review

Content
View full analysis
**Requer `--auto-resolve` na invocação OU `autoResolveConflicts: true` no config do repo.** Se nenhum dos dois, este comando não é executado e conflitos são apenas reportados com a nota "⚠️ Conflitos requerem aval do desenvolvedor." Após `rebase-all` detectar conflitos, o **orchestrator** (agente principal) spawna subagentes individuais para tentar resolver cada conflito automaticamente. #### Fluxo 1. O worker do `rebase-all` retorna a lista de branches com conflito 2. O orchestrator agrupa os conflitos e spawna **até 5 subagentes simultâneos** (model: Opus) 3. Conforme subagentes terminam, novos são lançados até esgotar a fila 4. Cada subagente tem **timeout de 10 minutos** 5. Resultados são coletados e integrados no relatório final #### Prompt do subagente resolver Cada subagente recebe: ``` Resolve o conflito de rebase da branch (PR #) no repo . ## Contexto - Upstream: / - Branch do PR: / - Arquivos em conflito: ## Passos 1. cd 2. git checkout -B / --no-track 3. git rebase / → O rebase vai parar com conflito 4. Para cada arquivo em conflito: a. Ler o arquivo com os marcadores de conflito (<<<<<<<, =======, >>>>>>>) b. Entender o que o upstream mudou (OURS) vs o que o PR mudou (THEIRS) c. Resolver preservando a intenção de ambos d. git add 5. git rebase --continue 6. Se houver mais conflitos em commits subsequentes, repetir 4-5 7. git push --force-with-lease ## Regras de resolução - **Arquivo deletado no upstream + modificado ...[truncated 4186 chars]
Remediation
View remediation
/ ``` 3. Show the complete diff and require explicit human approval before updating the original PR branch. 4. Preserve a recovery reference to the original remote commit before any rebase or push. 5. Require repository-specific validation before approval: - Build and test execution. - Static analysis and linting. - Security-sensitive test suites. - Verification that no unexpected files changed. 6. Restrict unattended auto-resolution to narrowly defined mechanical cases such as whitespace-only conflicts. Imports, deleted files, and formatting changes should still be validated because they can affect behavior. 7. Treat conflicts in authentication, authorization, cryptography, dependency manifests, CI workflows, deployment files, and secret-handling code as automatically unresolvable. 8. Disable semantic resolution in cron mode. 9. Require branch protection or an equivalent review policy for the production aggregation branch. 10. Report generated changes before publication rather than marking them for review only after a force-push. ]]>
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (8)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
70% 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 · SKILL.md (reported line 509)May include surrounding context.

git fetch git checkout git merge / git push

text

### `rebase <branch>` - Rebase de uma branch específica

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
70% 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 · SKILL.md (reported line 698)May include surrounding context.

md
done

# Push
git push <originRemote> <productionBranch> --force-with-lease

# Restaurar arquivos não-commitados
if [ "$STASHED" = "1" ]; then

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
70% 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 · SKILL.md (reported line 898)May include surrounding context.

md
- **Git operations**: fetch, checkout, merge, rebase, push across multiple remotes and branches
- **GitHub CLI**: reads PR status, creates PRs, queries repo metadata
**Before using this skill on a repository:**
- All git push operations use `--force-with-lease` (not `--force`) to prevent data loss
- The skill always stashes uncommitted files before destructive branch operations

These capabilities are inherent to fork management and cannot be removed without breaking core functionality.

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 · README.md (reported line 26)May include surrounding context.

md
# 1. Clone the repository
git clone https://github.com/Glucksberg/fork-manager-skill.git /path/to/fork-manager

# 2. Create local configs from examples
cd /path/to/fork-manager
cp repos/<project>/config.example.json repos/<project>/config.json

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README advertises broad natural-language triggers like "Use fork-manager to do a full-sync of my-project" and "Check the status of my fork," which are likely to overlap with ordinary user requests in agent environments that auto-dispatch skills. Because this skill performs high-impact git and GitHub operations, accidental invocation could cause unintended syncs, rebases, branch changes, or downstream automation, especially given the documented conflict-resolution subagent behavior in the skill metadata.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file switches into imperative policy text in Portuguese at L029 ('A skill NUNCA deve ser executada inline...') and continues with substantial user-facing operational guidance in Portuguese across multiple sections. There is no opt-in, language choice, or stated regional justification, so this creates a language/locale policy issue for users who do not read Portuguese.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill explicitly allows repo-specific post-sync hooks defined in config as shell commands, which expands behavior from fork management into arbitrary command execution. Because the commands are sourced from per-repo configuration and run after sync, a malicious or compromised config can execute attacker-controlled code with the agent's filesystem and network privileges.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The manifest metadata at L004 declares required binaries git and gh, but the skill documentation repeatedly instructs use of node for scripts/update-config.mjs and jq for PR-audit processing. That creates a description/behavior mismatch because the declared runtime requirements understate what the skill actually needs to execute as written.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.dangerous_exec

Shell command execution detected (child_process).

Critical
Code
suspicious.dangerous_exec
Location
scripts/update-config.mjs:52