Back to skill

Security audit

png-lsb-skills

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed PNG analysis helper that reads a user-provided image and optionally writes a JSON report, with no evidence of hidden access, persistence, exfiltration, or destructive behavior.

Install only if you want a Chinese-language PNG/LSB analysis tool. Use it on PNGs from trusted or challenge contexts, avoid very large images, and write JSON output only to locations you intend to modify.

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
scripts/png_analyzer.py:41
Finding

Unbounded Processing of Attacker-Controlled PNG Files Enables Resource Exhaustion

Content
View full analysis
I', data[pos:pos+4])[0] chunk_type = data[pos+4:pos+8].decode('ascii', errors='replace') chunk_data = data[pos+8:pos+8+length] ``` ```python # Open and decompress the image img = Image.open(io.BytesIO(data)) ``` ```python # Process every column in as many as eight complete rows width, height = img.size pixels = img.load() # Extract LSBs from the first eight rows lsb_rows = {} for row in range(min(8, height)): R, G, B = [], [], [] for col in range(width): px = pixels[col, row] if isinstance(px, int): px = (px, px, px) r, g, b = px[:3] R.append(str(r & 1)) G.append(str(g & 1)) B.append(str(b & 1)) lsb_rows[row] = {'R': R, 'G': G, 'B': B} ``` ```python # Repeatedly expand and process row data under all 15 patterns for name, func in patterns: seq = func(R, G, B) binstr = ''.join(seq) # Decode into characters decs = [] chars = [] for i in range(0, len(binstr), 8): byte = binstr[i:i+8] if len(byte) == 8: dec = int(byte, 2) decs.append(dec) if 32 <= dec <= 126: chars.append(chr(dec)) else: chars.append('.') row_patterns.append({ 'name': name, 'binstr': binstr[:80] + ('...' if len(binstr) > 80 else ''), 'decs': decs[:20], 'chars': ''.join(chars) }) ``` ### Technical Analysis The analyzer accepts a user-selected PNG path and processes the f ...[truncated 2472 chars]
Remediation
View remediation
Vulnerability Patterns
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (2)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
83% confidence
Finding

The skill invokes a local Python script and explicitly supports an optional output path, which implies file-write capability, but it does not declare any tool scope or permissions boundaries. In an agent environment, missing scope declarations can allow broader-than-expected filesystem access or make it unclear to reviewers and policy engines that the skill may create or overwrite files.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This code file contains natural-language descriptions and CLI messages entirely in Chinese, including the module docstring and runtime output. Under the policy, forcing a specific language without user opt-in is a locale/language policy violation unless the constraint is documented and justified.

Content

No source excerpt is available for this finding.