Summary
OpenShot Video Editor can deserialize non-JSON project files with Python's unrestricted pickle loader. If a user opens a crafted .osp file, embedded behavior may execute code with that user's privileges.
Affected context
The vulnerability occurs in OpenShot's project-loading paths, including ProjectDataStore.load() and read_legacy_project_file(). These paths pass non-JSON project data to pickle.load() without restriction, so the issue becomes risky when a crafted project file is opened.
Exploit preconditions
- Attack surface: Project-file loading in the OpenShot desktop application
- Required access: An attacker must get a crafted project file to a user; the description does not indicate that the attacker needs access to the victim's system
- Trigger point: The user opens the crafted
.ospproject file - Why exploitation is possible: Unrestricted pickle deserialization can invoke attacker-controlled object behavior while loading the file
Why this happens
The underlying bug is deserializing untrusted project data with a mechanism that can reconstruct arbitrary Python objects. Pickle can invoke object-specific behavior during loading, rather than merely parsing inert data. This maps to CWE-502: Deserialization of Untrusted Data.
Potential impact
- Arbitrary code may execute with the privileges of the user opening the project
- An attacker could access or alter files available to that user
- The application or user session could be compromised
- Further impact may be possible depending on the user's permissions and environment
General mitigation guidance
Defensive patterns focus on avoiding executable deserialization for files that may be untrusted.
- Prefer data-only formats and parsers that do not instantiate arbitrary objects
- Treat project files from external sources as untrusted, regardless of their extension
- Apply strict schema and type validation after parsing with a safe parser
- Run desktop applications with only the permissions needed for their tasks
- Where legacy formats must be supported, isolate their parsing from sensitive resources
How teams detect issues like this
- Use static analysis to identify unrestricted
pickle.load()or equivalent deserialization of file contents - Review project-import paths for format checks that occur after deserialization rather than before it
- Add code-review checks for executable serialization formats at trust boundaries
- Enforce policies that prohibit unsafe deserialization of user-supplied files
- Use automated security review tools as a supplementary way to flag risky parser patterns

