Security Audit
dkyazzentwatwa/chatgpt-skills:image-filter-lab
github.com/dkyazzentwatwa/chatgpt-skillsTrust Assessment
dkyazzentwatwa/chatgpt-skills:image-filter-lab received a trust score of 65/100, placing it in the Caution category. This skill has some security considerations that users should review before deployment.
SkillShield's automated analysis identified 4 findings: 0 critical, 1 high, 3 medium, and 0 low severity. Key findings include Unpinned Python dependency version, Uncontrolled filesystem access via arbitrary file paths and method invocation.
The analysis covered 4 layers: Manifest Analysis, Static Code Analysis, Dependency Graph, LLM Behavioral Safety. All layers scored 70 or above, reflecting consistent security practices.
Last analyzed on February 24, 2026 (commit d4bad335). SkillShield performs automated 4-layer security analysis on AI skills and MCP servers.
Layer Breakdown
Behavioral Risk Signals
Security Findings4
| Severity | Finding | Layer | Location | |
|---|---|---|---|---|
| HIGH | Uncontrolled filesystem access via arbitrary file paths and method invocation The skill allows arbitrary file paths to be passed to critical filesystem operations, including `Image.open()` in `load()`, `Image.save()` in `save()`, `os.listdir()` in `batch_process()`, and `os.makedirs()` in `batch_process()`. These paths are derived directly from untrusted user input (CLI arguments like `--input`, `--output`, `--batch`, `--output-dir`, and parameters to filters invoked via `--filter`).
This enables:
1. **Data Exfiltration**: An attacker can attempt to read arbitrary files (e.g., `load:/etc/passwd` via `--filter` or `--input /etc/passwd`). While `PIL.Image.open` might fail for non-image files, the attempt to access sensitive files is a risk. For valid image files, sensitive data (e.g., EXIF metadata) could be loaded.
2. **Arbitrary File Write**: An attacker can write the current image content to arbitrary locations (e.g., `save:/tmp/malicious.sh:1` via `--filter` or `--output /tmp/malicious.sh`). If the image content is controlled (e.g., by loading a crafted image first), this can lead to overwriting system files or creating malicious scripts, potentially leading to command injection.
3. **Directory Traversal/Probing**: `os.listdir()` and `os.makedirs()` can be directed to arbitrary paths, allowing an attacker to probe directory structures or create directories outside the intended scope.
The `getattr` mechanism in `apply_filter_from_args` further exacerbates this by allowing invocation of `load` and `save` methods with arbitrary paths through a generic filter argument, effectively turning a filter parameter into a command injection vector for file operations. 1. **Path Validation**: Implement strict path validation for all file-related arguments (`filepath`, `input_dir`, `output_dir`). This should include disallowing absolute paths, preventing path traversal sequences (e.g., `../`), and restricting operations to a designated, sandboxed directory (e.g., a temporary directory or a user-specific upload directory). 2. **Method Whitelisting**: For the `apply_filter_from_args` function, replace the `getattr` call with a whitelist of explicitly allowed filter methods. This prevents invocation of unintended methods like `load` or `save` through the generic filter mechanism. | LLM | scripts/image_filter.py:40 | |
| MEDIUM | Unpinned Python dependency version Requirement 'pillow>=10.0.0' is not pinned to an exact version. Pin Python dependencies with '==<exact version>'. | Dependencies | image-filter-lab/scripts/requirements.txt:1 | |
| MEDIUM | Unpinned Python dependency version Requirement 'opencv-python>=4.8.0' is not pinned to an exact version. Pin Python dependencies with '==<exact version>'. | Dependencies | image-filter-lab/scripts/requirements.txt:2 | |
| MEDIUM | Unpinned Python dependency version Requirement 'numpy>=1.24.0' is not pinned to an exact version. Pin Python dependencies with '==<exact version>'. | Dependencies | image-filter-lab/scripts/requirements.txt:3 |
Scan History
Embed Code
[](https://skillshield.io/report/afc66451275c59c8)
Powered by SkillShield