Summary
Flyto2 Core contains file and data modules that can write to caller-controlled paths without consistently enforcing the configured sandbox boundary. A caller able to execute these modules or recipes may write files outside the sandbox, potentially enabling code execution if sensitive host files are overwritten.
Affected context
The issue affects Flyto2 Core versions before 2.26.8. The advisory names data.csv.write, data.json_to_csv, file.copy, and file.move, and also identifies unguarded modules across broader data.*, file.*, and report-writer families. Risk arises when these modules process caller-controlled output or destination paths without applying the sandbox confinement check.
Exploit preconditions
- Attack surface: Flyto2 Core modules that write, copy, or move files
- Required access: Ability to execute the affected modules or recipes and supply or influence their paths
- Trigger point: A module handles a caller-controlled output or destination path
- Why exploitation is possible: Some paths bypass the canonical sandbox guard; a
..substring denylist also does not block absolute paths
Why this happens
The underlying bug is insufficient restriction of file paths, mapping to CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal'). The sandbox validation guard was applied selectively rather than consistently across file-writing modules. Path checks based on substring denial are also insufficient: they do not reliably establish that a resolved path remains within the intended directory.
Potential impact
- An attacker may write or overwrite files outside the configured sandbox
- Application code, recipes, startup files, scheduled-task files, or authorization files could be altered
- Overwriting executable or startup content could lead to code execution on the host
- Sensitive files or application behavior could be compromised
General mitigation guidance
Defensive approaches focus on enforcing a consistent path boundary for every file operation.
- Resolve and canonicalize paths, then verify the resolved destination remains within the configured sandbox
- Apply the same validation to write, copy, move, and report-generation paths
- Prefer APIs that constrain file operations to an approved directory rather than relying on string deny lists
- Reduce trust in caller-supplied paths and restrict who can execute modules or recipes
- Run automation processes with least privilege and limit their access to sensitive host files
How teams detect issues like this
- Use static analysis to find file operations that accept caller-controlled paths without canonicalization and sandbox-boundary checks
- Review all
data.*,file.*, and report-writer modules for consistent path validation - Flag path checks based only on substring or prefix matching, including checks that do not account for absolute paths and resolved path segments
- Enforce code-review or CI policies requiring validated paths for file writes, copies, and moves

