Summary
Jellyfin media server versions prior to 10.11.7 contain an unauthenticated arbitrary file read vulnerability caused by unsafe injection of user-controlled query parameters into ffmpeg command-line arguments.
By abusing the StreamOptions parsing logic on the /Videos/{itemId}/stream endpoint, an attacker can cause ffmpeg to load and render contents of arbitrary server files into the video stream response.
Affected context
The vulnerability manifests in Jellyfin's HTTP video streaming pipeline, specifically in the /Videos/{itemId}/stream endpoint.
The ParseStreamOptions method in StreamingHelpers.cs accepts arbitrary lowercase query parameters and places them into a dictionary that feeds ffmpeg arguments.
Because this endpoint lacks an Authorize attribute, it is technically reachable without authentication; however, exploitation still depends on an attacker learning a valid media itemId/GUID, which is typically obtained via an authenticated session or other information leakage.
Exploit preconditions
- Attack surface: HTTP access to the
/Videos/{itemId}/streamendpoint on a vulnerable Jellyfin instance. - Required access: Network access to the server; no HTTP-level authentication is enforced on this endpoint, but a valid
itemIdis needed. - Trigger point: Supplying crafted query parameters (e.g., via
StreamOptions) that are interpreted as ffmpeg filters and injected into the command line. - Why exploitation is possible: The stream options parser:
- Accepts arbitrary lowercase query parameters into an internal options dictionary.
- Bypasses controller-level
RegularExpressionvalidation by populating options before validation is applied. - Concatenates these unsanitized values directly into the ffmpeg command string without escaping, allowing attackers to inject a
drawtextfilter referencing arbitrarytextfilepaths on the server.
Why this happens
The core issue falls under CWE-88: Argument Injection or Modification.
Jellyfin constructs an ffmpeg command line by directly concatenating user-supplied option values without proper escaping or validation.
The ParseStreamOptions method treats any lowercase query parameter as a trusted stream option, bypassing the RegularExpression-guarded controller parameters.
Because ffmpeg filters such as drawtext can load text from files via a textfile parameter, any injected filter chain that is appended to the command line can cause ffmpeg to read arbitrary files from the server's filesystem.
Additionally, the missing Authorize attribute on the streaming endpoint (related to CWE-862: Missing Authorization) broadens the exposure by allowing untrusted clients to invoke this flawed downstream behavior.
Potential impact
- Arbitrary file read of sensitive system files (e.g.,
/etc/shadow, configuration files, application secrets). - Disclosure of user data stored on the same filesystem as Jellyfin, depending on process file-system permissions.
- Exposure of authentication credentials, API keys, or tokens stored in readable configuration files.
- Assistance to further attacks such as privilege escalation, lateral movement, or targeted credential compromise.
General mitigation guidance
Effective mitigation focuses on tightening both argument handling and authorization boundaries:
- Treat all query parameters feeding into command execution as untrusted and apply strict whitelisting of allowed options and values.
- Use structured argument construction APIs rather than raw string concatenation when building ffmpeg command lines, ensuring all user-controlled content is properly escaped.
- Enforce server-side validation for stream options at a single, centralized layer, and avoid any parsing paths that bypass framework-level validation attributes.
- Restrict the capabilities of the media processing component by limiting file-system access (e.g., via chroot, containers, or sandboxing) to reduce the blast radius if arguments are misused.
- Apply least-privilege to the Jellyfin process, ensuring it only has read access to the minimal set of directories required for normal operation.
- Require authorization for media streaming endpoints, especially where they can influence backend tooling like ffmpeg.
How teams detect issues like this
Organizations can detect similar issues by combining code-level and operational monitoring:
- Static analysis and reviews:
- Flag any use of string concatenation or interpolation when constructing process execution commands, especially for multimedia tools like ffmpeg.
- Search for helper functions (such as
ParseStreamOptions) that ingest arbitrary query parameters and pass them downstream without normalization or validation. - Highlight endpoints lacking explicit authorization decorators where they interact with privileged backend components.
- Policy and configuration checks:
- Enforce rules requiring authorization on all endpoints that invoke external binaries.
- Mandate that command construction uses safe APIs or utility wrappers that encode and escape arguments correctly.
- Runtime monitoring:
- Monitor ffmpeg invocation logs or process command lines for anomalous filter chains or unexpected
textfilereferences. - Use WAF or API gateways to inspect query parameters for suspicious ffmpeg filter syntax, while recognizing that such inspection is a defense-in-depth measure rather than a primary control.

