T01 · Skill Instruction Hijacking
- Location
SKILL.md:256- Finding
Mandatory Agent Response Manipulation Through Skill Instructions
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill appears to be a coherent pyFAI diffraction/scattering helper, with expected local data processing and installation behavior but some scoping and output-format caveats users should notice.
Before installing, be aware that the helper may install Python packages into a local virtual environment. Use the default pyFAI-related packages or trusted package names only, avoid running it with administrator privileges, and expect the skill to read user-selected diffraction data and write derived outputs to the chosen output directory.
SKILL.md:256Mandatory Agent Response Manipulation Through Skill Instructions
lib/install_env.py:32Unrestricted Third-Party Package Installation Through User-Controlled Extras
Suspicious Unicode normalization or mixed-script content
The skill instructs execution of local Python scripts, shell commands, file inspection, and writing outputs, but declares no explicit tool scope or permission boundaries. In an agent environment, this can lead to overbroad file access and shell execution beyond user expectations, increasing the chance of unintended command execution or unsafe handling of local data.
subprocess module calls execute external commands. Without careful input validation, this enables command injection.
print(json.dumps({"event": "command", "argv": command}, ensure_ascii=False), flush=True)
if dry_run:
return
subprocess.run(command, check=True)
def main() -> int:
Suspicious Unicode normalization or mixed-script content
This markdown file defines activation conditions, so vague-trigger checks apply. The phrase 'Installing or using pyFAI' is broad and lacks boundaries or exclusion conditions, which may cause the skill to activate for generic pyFAI questions not specifically tied to diffraction/scattering data processing workflows.
Lines L038-L039 state the skill is for work only after the user already has a .poni geometry file. However, lines L050-L075 explicitly direct the skill to handle missing .poni cases by guiding installation and calibration, which contradicts the earlier scope statement rather than merely adding detail.
The activation examples '1D integration' and 'GIWAXS, sector, cake, HDF5, Eiger' are short keyword-style triggers without context or negative examples. In a markdown skill description, such broad terms can overlap with unrelated discussions and make it unclear when the skill should activate versus when it should not.
The top-level docstring presents the skill description in English and Chinese, indicating a fixed language choice embedded in the file rather than a user-selectable locale. Under the stated policy, forcing a specific language or locale without opt-in can be a natural-language policy concern.
The documentation states that this quick start applies only when the user already has a .poni file and is not doing calibration. The manifest, however, explicitly says calibration is part of the full workflow and that having a .poni file is not a prerequisite for using the skill, so these lines actively narrow the stated intent in a contradictory way.
This Python file contains natural-language documentation in both English and Chinese, including a non-default locale string, but does not indicate that language selection is optional or justified by a region-specific requirement. Under the policy rule for language or locale constraints, this can be treated as a potential locale-policy issue because the file embeds multilingual guidance without clarifying user opt-in or scope.