Executive brief
Fission is a framework for serverless functions on Kubernetes. A flaw in how it validates file paths allows a user to potentially read or write files in folders they should not have access to, provided they can control a folder with a similar name on the same system. This could lead to unauthorized data access or modification within the shared storage used by the Fission builder and fetcher components.
Technical details
The `SanitizeFilePath` function in `pkg/utils/utils.go` used a lexical prefix check (`strings.HasPrefix`) to validate that a path remained within a designated safe directory. Because it did not enforce a path-separator boundary, a path like `/packages-extra/` would be incorrectly validated against a safe directory of `/packages`. An attacker with the ability to control or pre-create sibling directories on the shared volume used by the builder or fetcher can exploit this to achieve arbitrary file reads or writes outside the intended scope. The vulnerability was addressed in version 1.25.0 by migrating to `os.Root` for directory confinement and removing the flawed `SanitizeFilePath` function.
Affected products
- fission fission <= 1.24.0
Timeline
- 2026-06-08: disclosed
- 2026-06-10: advisory: NVD publication
- 2026-07-28: patched: GitHub Advisory published/updated with fix version 1.25.0