Back to skill

Security audit

Hair Color & Style Advisor

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed YouCam-based hair recommendation and try-on workflow, with privacy and API-key cautions but no artifact-backed malicious behavior.

Install only if you are comfortable sending selfies, face-shape, skin-tone, and hair try-on data to YouCam/Perfect Corp and spending API credits. Store the API key securely, prefer an environment variable over credentials.json, use only user-approved images or trusted URLs, and keep analysis parameters limited to what the hair recommendation needs.

Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
Findings (32)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding
The instructions indicate support for reference-photo workflows and generic remote resource handling, which can extend beyond hair-specific try-on into broader image-processing capabilities. In context, that is dangerous because the stated restrictions ('not for skin, makeup, clothes') may be bypassed by the generic underlying execution path, causing misuse of credentials and APIs outside the reviewed purpose.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding
The instructions indicate support for reference-photo workflows and generic remote resource handling, which can extend beyond hair-specific try-on into broader image-processing capabilities. In context, that is dangerous because the stated restrictions ('not for skin, makeup, clothes') may be bypassed by the generic underlying execution path, causing misuse of credentials and APIs outside the reviewed purpose.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding
The instructions indicate support for reference-photo workflows and generic remote resource handling, which can extend beyond hair-specific try-on into broader image-processing capabilities. In context, that is dangerous because the stated restrictions ('not for skin, makeup, clothes') may be bypassed by the generic underlying execution path, causing misuse of credentials and APIs outside the reviewed purpose.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Credential Access

High
Category
Privilege Escalation
Content
requirements:
  credentials:
    - name: YOUCAM_API_KEY
      source: env | credentials.json (in the skill root, next to SKILL.md)
  network:
    - yce-api-01.makeupar.com
  apis:
Confidence
95% confidence
Finding
The skill explicitly accesses an API key from the environment or a local `credentials.json`, which is sensitive secret material. In an agent setting, any skill that reads credentials becomes high impact because prompt injection, path confusion, or misuse of helper scripts can turn a narrow content task into credential exposure or unauthorized API consumption.

Direct Prompt Extraction

High
Category
System Prompt Leakage
Content
(or custom pattern + palettes; ombre needs blend_strength / line_offset — see the doc).
5. The generation returns a result image URL in `data.results.url`.

## Output rules
* **Return the result image URL exactly as given** (hyperlink is OK; do not modify it).
* Explain the recommendation (face shape → style, skin tone → color).
* **Always end with this note:** "This preview image is AI-generated and for reference only;
Confidence
85% confidence
Finding
Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Context-Inappropriate Capability

High
Confidence
98% confidence
Finding
The metadata explicitly says the skill should not be used for skin-related purposes, yet the fallback config exposes a skin-tone-analysis endpoint. In this skill, skin tone is also part of the recommendation logic, so the mismatch creates ambiguity that can lead to unauthorized biometric processing, policy bypass, and collection of sensitive appearance data beyond the declared scope.

Context-Inappropriate Capability

High
Confidence
91% confidence
Finding
The manifest scopes this skill to recommending hairstyle and hair color and previewing them with YouCam, and explicitly says not to use it for hair health diagnostics, skin, makeup, or clothes. This module is a generic task runner for arbitrary YouCam features, with documentation and parameters referencing examples like skin-analysis, garment virtual try-on, and clothes try-on, enabling capabilities not justified by the stated purpose of this skill.

Lp3

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding
Without declared permissions the skill's intent is opaque and cannot be validated.

Description-Behavior Mismatch

Medium
Confidence
95% confidence
Finding
The manifest limits this skill to recommending hairstyles and hair colors based on face shape and skin tone, but this fallback configuration exposes a much broader face-analysis API surface. In addition to face shape and hair color, it includes age, gender, eye attributes, brows, lips, nose, cheekbones, and facial ratio analysis, which exceed the described purpose.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The config documents processing of face attributes, skin tone, hair color, age, and gender without any privacy, consent, retention, or biometric-data handling notice. Because these inputs are highly sensitive and closely tied to user identity, the lack of warning and governance language can lead to collection and transfer of biometric data without informed consent or appropriate safeguards.

Vague Triggers

Medium
Confidence
93% confidence
Finding
The API schema repeatedly instructs callers to provide publicly accessible image URLs for source and reference files, but gives no warning that user selfies may become exposed to third parties, logs, link-sharing, or unintended indexing. In a skill handling face images and other biometric characteristics, this omission materially increases the risk of privacy compromise and unauthorized access to sensitive data.

Description-Behavior Mismatch

Medium
Confidence
95% confidence
Finding
This file is a shared CLI for all YouCam features and its own docstring explicitly advertises unrelated capabilities such as skin-analysis, credits, and generic feature execution. In the context of a narrowly scoped hair-color/hairstyle advisor skill, exposing a generic backend materially expands capability beyond the declared purpose and can enable unauthorized or context-inappropriate API use.

Context-Inappropriate Capability

Medium
Confidence
97% confidence
Finding
The run and status paths accept arbitrary --feature values and pass them into run(), load_contract(), and poll() without validating that the requested feature is appropriate for this skill. That means a user or upstream agent can invoke any YouCam feature available to the API key, including unrelated analysis or try-on functions, bypassing the skill's stated scope restrictions.

subprocess module call

Medium
Category
Dangerous Code Execution
Content
print(f"[setup] virtual environment already exists at {_VENV_DIR}")
    else:
        print(f"[setup] creating virtual environment at {_VENV_DIR} ...")
        subprocess.run([sys.executable, "-m", "venv", _VENV_DIR], check=True)

    venv_python = _venv_python(_VENV_DIR)
    print(f"[setup] installing dependencies from {_REQUIREMENTS} ...")
Confidence
70% confidence
Finding
subprocess module calls execute external commands. Without careful input validation, this enables command injection.

subprocess module call

Medium
Category
Dangerous Code Execution
Content
venv_python = _venv_python(_VENV_DIR)
    print(f"[setup] installing dependencies from {_REQUIREMENTS} ...")
    subprocess.run([venv_python, "-m", "pip", "install", "--upgrade", "pip"], check=True)
    subprocess.run([venv_python, "-m", "pip", "install", "-r", _REQUIREMENTS], check=True)

    activate_hint = (
Confidence
70% confidence
Finding
subprocess module calls execute external commands. Without careful input validation, this enables command injection.

subprocess module call

Medium
Category
Dangerous Code Execution
Content
venv_python = _venv_python(_VENV_DIR)
    print(f"[setup] installing dependencies from {_REQUIREMENTS} ...")
    subprocess.run([venv_python, "-m", "pip", "install", "--upgrade", "pip"], check=True)
    subprocess.run([venv_python, "-m", "pip", "install", "-r", _REQUIREMENTS], check=True)

    activate_hint = (
        rf"{_VENV_DIR}\Scripts\activate" if os.name == "nt" else f"source {_VENV_DIR}/bin/activate"
Confidence
70% confidence
Finding
subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Missing User Warnings

Medium
Confidence
88% confidence
Finding
The upload path sends local file contents to a third-party API without any user-facing disclosure in this module. Given this skill processes personal photos for hair style/color preview, the privacy impact is meaningful because face images are sensitive personal data and are transmitted off-device.

Missing User Warnings

Medium
Confidence
92% confidence
Finding
The code fetches arbitrary remote URLs client-side and then re-uploads the content to an external API, which can transfer third-party or internal-network-accessible content without clear user disclosure. In this skill context, users may submit image URLs for hairstyle preview, so silent cross-service data movement increases privacy and SSRF-like exposure if internal URLs are ever reachable from the runtime.

Static analysis

No suspicious patterns detected.