Back to skill

Security audit

Ps7 Toolkit

Security checks for vulnerabilities and agentic risk

Overview

This toolkit needs review because it runs unverified downloads from third-party proxies and can erase existing shell configuration during setup.

Start with -CheckOnly. Prefer a separately verified installation using [Microsoft's installation guide](https://learn.microsoft.com/en-us/powershell/scripting/install/install-powershell-on-windows). Back up both PowerShell profiles and terminal/editor settings before setup. -SkipDefaults avoids configuration changes but still installs executable files and does not disable proxy downloads. Avoid the README's unrestricted deletion example; seek fixes for download verification and configuration preservation before using default setup.

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

Error
Location
scripts/install.ps1
Finding

Third-party proxy responses are trusted as executable releases

Content
View full analysis

Impact

A proxy serving substituted binaries can obtain arbitrary code execution as the current user. With defaults enabled, the substituted PowerShell executable can also become the user's configured shell.

Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Output HandlingUnvalidated Output Injection, Cross-Context Output, Unbounded Output
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (12)

Incomplete referenced artifact analysis

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
assets/icon.png 512x512 图标

Incomplete referenced artifact analysis

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
scripts/install.ps1 主安装器(幂等,跨机器)

Incomplete referenced artifact analysis

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
scripts/setup-defaults.ps1 默认化(profile/注册表/文件关联/快捷方式/终端/VSCode)

Incomplete referenced artifact analysis

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
scripts/wt-config.ps1 WT/VSCode 配置的文本级改写(保留注释,可被测试单独调用)

Incomplete referenced artifact analysis

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
scripts/smoke-test.ps1 40 项回归测试(隔离沙箱,不碰系统配置,退出码可接 CI)

The fd usage example deletes matching files without warning that it is destructive.

Medium
Category
Output Handling
Confidence
95% confidence
Finding

The example fd -x rm {} executes a deletion command for every discovered result without a search restriction, preview, or explicit warning. Where an external rm executable is available, copying this example can delete files recursively discovered under the current directory; presenting it as routine usage in an agent-oriented toolkit increases the risk of accidental execution.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · README.md (reported line 205)May include surrounding context.

jq —— 处理 JSON

powershell
curl.exe -s https://api.github.com/repos/PowerShell/PowerShell | jq .tag_name
Get-Content data.json | jq ".[] | .name"

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/install.ps1 (reported line 134)May include surrounding context.

text
function Get-LatestTag {
    param([string]$Repo)
    try {
        $r = Invoke-RestMethod -Uri "https://api.github.com/repos/$Repo/releases/latest" `
             -Headers @{ 'User-Agent'='ps7-toolkit' } -TimeoutSec 25
        return $r.tag_name
    } catch { return $null }

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/install.ps1 (reported line 145)May include surrounding context.

text
function Resolve-ReleaseAssetUrl {
    param([string]$Repo, [string]$Tag, [string]$Pattern, [string]$FallbackAsset)
    try {
        $r = Invoke-RestMethod -Uri "https://api.github.com/repos/$Repo/releases/tags/$Tag" `
             -Headers @{ 'User-Agent'='ps7-toolkit' } -TimeoutSec 25
        $a = $r.assets | Where-Object {
            $_.name -like "*$Pattern*" -and $_.name -notmatch '\.(sha256|sig|asc)$'

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: shell.

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

UTF-8 setup replaces existing PowerShell profiles instead of updating only toolkit-related settings.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

When an existing profile lacks the 'ps7-toolkit' marker, the script replaces its entire contents rather than preserving unrelated configuration. This can remove user-defined security checks, logging setup, and essential initialization from both PowerShell profiles; the backup reduces recovery costs but does not prevent disruption. Encoding configuration is appropriate for this toolkit, but wholesale replacement exceeds that purpose and is especially risky when invoked automatically to troubleshoot shell problems.

Content

No source excerpt is available for this finding.

The VSCode updater can discard existing profile fields despite explicitly promising to preserve them.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

If an existing PowerShell 7 profile lacks a string-valued path, the fallback replaces the entire profile object with a generated object, discarding fields such as args, env, and source. This can remove user-defined execution constraints or environment settings while also making that profile the default terminal; JSON syntax validation will not detect this semantic loss. The behavior contradicts the updater's preservation guarantee, although there is no evidence of malicious intent or direct attacker-controlled execution in this finding.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.