Back to skill

Security audit

Flashforge 3D Print

Security checks for vulnerabilities and agentic risk

Overview

The skill is purpose-aligned for controlling a 3D printer, but it exposes a real device credential and gives high-impact printer and camera instructions without enough safety or privacy scoping.

Review before installing. Do not use this as published with a real printer check code; rotate the exposed check code if it belongs to an actual device, replace device values with local configuration or secrets, restrict camera/control ports to trusted hosts, and require explicit confirmation before start, pause, stop, or slice-print operations.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:18
Finding

Hardcoded Printer Authentication and Connection Data

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 18–25
Vulnerability Type: Hardcoded sensitive configuration and authentication material
Risk Level: Medium

Vulnerable Code Snippet:

markdown
## Printer Configuration

- **Name:** Ralph Wiggum
- **IP:** 10.0.0.41
- **Serial:** SNMSRE9704441
- **Check Code:** a31d9729
- **Camera:** Port 8080 (web interface)
- **Control:** Port 8899 (G-code)

Technical Analysis

The Skill embeds a specific printer's private IP address, serial number, check code, camera port, and G-code control port directly in distributable documentation. The check code appears to be authentication or pairing material associated with the printer. Even if the private IP address is not directly reachable from the public Internet, these values reduce the information and authentication barriers for an attacker who has access to the same network.

The documented control interface supports commands that start, pause, stop, or otherwise manipulate physical printer operations. The camera endpoint may also expose images from the printer's environment. Secrets and device-specific identifiers should not be committed to a Skill package because users, logs, source repositories, archives, and package distribution systems may retain them.

Attack Path

  1. An attacker obtains the Skill package or reads its repository contents.
  2. The attacker extracts the printer IP address, control port, camera port, serial number, and check code from SKILL.md.
  3. The attacker obtains network access to 10.0.0.41, such as through the same LAN, a compromised local host, an exposed VPN, or an incorrectly routed private network.
  4. The attacker connects to port 8899 or uses a compatible Flashforge client with the disclosed device information.
  5. If the check code is accepted as authentication, the attacker issues printer-control operations, including selecting, starting, pausing, stopping, or ot ...[truncated 939 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove all real device identifiers and authentication values from the Skill documentation.
  2. Immediately rotate or regenerate the disclosed printer check code.
  3. Replace concrete values with placeholders, for example:
    markdown
    - **IP:** `${PRINTER_HOST}`
    - **Serial:** `${PRINTER_SERIAL}`
    - **Check Code:** loaded from a protected secret store
    
  4. Load the check code at runtime from an environment variable, operating-system credential manager, or dedicated secrets manager.
  5. Ensure secrets are excluded from source control, logs, command histories, generated documentation, and diagnostic output.
  6. Restrict ports 8080 and 8899 using network segmentation and firewall rules so only explicitly authorized management hosts can connect.
  7. Require device-side authentication for both camera and control interfaces where supported.
  8. Add automated secret scanning to the repository and distribution pipeline.

T08 · Insecure Dependencies

Warning
Location
SKILL.md:27
Finding

Unpinned Third-Party Python Dependencies

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 27–34
Vulnerability Type: Unpinned dependency installation
Risk Level: Medium

Vulnerable Code Snippet:

markdown
## Installation

```bash
# Install dependencies
pip install flashforge-python-api requests

# Or use virtual environment
source ~/.openclaw/workspace/.venv/bin/activate
text

### Technical Analysis

The installation command retrieves the latest versions of `flashforge-python-api`, `requests`, and their transitive dependencies without version constraints or integrity hashes. Consequently, the code installed by the command can change after the Skill has been reviewed.

This creates a supply-chain weakness: a compromised package release, compromised maintainer account, malicious transitive dependency, dependency-resolution change, or untrusted package index configuration could introduce attacker-controlled code. Python packages may execute code during installation, and imported dependencies execute within the privileges of the process using them.

The documentation mentions a virtual environment but does not require one, pin package versions, identify a trusted index, verify hashes, or provide a reviewed lock file.

### Attack Path

1. An attacker compromises a named dependency, one of its transitive dependencies, or an account authorized to publish package releases.
2. Alternatively, the attacker influences the user's Python package index or mirror configuration so that an unsafe package artifact is selected.
3. The attacker publishes a malicious version that remains compatible with the unconstrained installation command.
4. A user follows the documented `pip install flashforge-python-api requests` instruction.
5. `pip` resolves and downloads the attacker-controlled artifact because no version or hash is enforced.
6. Malicious code executes during installation or when the package is imported by the printer controller.
7. The
...[truncated 879 chars]
Remediation
View remediation

Remediation Suggestions

  1. Pin every direct dependency to a reviewed version in a requirements or lock file.
  2. Record transitive dependencies and use cryptographic hashes, for example with a hash-locked requirements.txt and pip install --require-hashes -r requirements.txt.
  3. Configure an explicit trusted package index or an internally controlled package mirror.
  4. Require installation inside a dedicated, least-privileged virtual environment.
  5. Review package provenance, maintainers, release history, and dependency trees before updating locked versions.
  6. Add automated dependency vulnerability and integrity scanning to the release process.
  7. Test dependency updates in an isolated environment before promoting them to systems that can control physical hardware.
  8. Do not run package installation or the printer controller with administrator privileges unless strictly necessary.
Vulnerability Patterns
  • 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
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (4)

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- `SKILL.md` - This file

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The documentation advertises the ability to start, pause, and stop physical 3D printer jobs but does not warn users that these actions can waste material, damage prints, interrupt in-progress jobs, or create equipment/safety risks if used at the wrong time. Because this skill targets a real network-connected device and promotes full automation, the lack of safety framing materially increases the chance of harmful or unauthorized physical actions.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The documentation gives direct instructions for accessing a live camera endpoint on a private LAN device, including a concrete IP and port, without treating the feed as sensitive data. This normalizes retrieval of potentially private visual information and could enable unauthorized observation if the skill is used in a shared or insufficiently trusted environment.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill exposes camera snapshot functionality without warning that images may capture the user's workspace, nearby people, or other sensitive environmental details. Even if the feature is intended for printer monitoring, presenting it as a simple convenience action downplays privacy implications of collecting visual data from a private device.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.