llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Packagist · azuracast/azuracast

GHSA-MF65-HJ88-HVRW

AzuraCast OS command injection via incomplete backslash escaping in Liquidsoap annotation values

Sin parche publicado
Descargar PNG JSON
CVSS 3.1
8.8
Alta
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H Fuente: GitHub
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
ParcheSin parcheEl fabricante no ha publicado corrección
Exposición15 dDesde la divulgación, 5 nov 2026, 2:42 p. m.
Detección12 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Explotación
Remediación
Monitoreo
Detectada +1
5 nov 26
18 nov 26
20 nov 26
5 nov 26
9 nov 26
13 nov 26
17 nov 26
20 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-MF65-HJ88-HVRW divulgada · CVSS 8.8 (GitHub)
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

Summary

AzuraCast serializes track metadata into Liquidsoap annotation strings using a helper that escapes double quotes but not backslashes. A user holding the station-level Media permission can upload a media file whose ID3 title (or other annotated tag) ends a value with a backslash immediately before the closing quote. Because the backslash is not escaped, the serialized annotation breaks out of the quoted value, letting the attacker inject an arbitrary Liquidsoap resource URI. Using Liquidsoap's built-in `process:` protocol, this yields arbitrary OS command execution in the Liquidsoap container when the generated playlist is loaded. The attack needs no software beyond a default AzuraCast and Liquidsoap installation and triggers automatically during playback.

Root Cause

The annotation serializer neutralizes the double-quote delimiter (`"` becomes `\"`) and strips newline, tab, and carriage-return characters, but it does not neutralize the backslash character. In a context where backslash is itself the escape character, failing to escape it is unsafe: a value containing a trailing backslash followed by a quote is emitted as `\\"`, which the Liquidsoap lexer reads as an escaped backslash (a literal `\`) followed by an unescaped closing quote. The quoted value therefore terminates early, and the remaining attacker-controlled bytes are parsed as subsequent annotation syntax and, ultimately, as the resource URI.

backend/src/Radio/Backend/Liquidsoap/ConfigWriter.php:1418
    return str_replace(['"', "\n", "\t", "\r"], ['\"', '', '', ''], $strVal);
    // escapes the quote delimiter but not the backslash escape character

Vulnerable function: App\Radio\Backend\Liquidsoap\ConfigWriter::annotateValue

The tag value reaches this serializer unfiltered: the title is stored via `Types::stringOrNull()` with only a length truncation applied, and the annotation key allowlist filters by key name, never by value.

Impact

The attacker needs the station-scoped `StationPermissions::Media` permission (media manager, not global administrator). No additional software or non-default configuration is required: Liquidsoap and its built-in `process:` protocol are always present, and AzuraCast does not disable or restrict that protocol. The attacker achieves arbitrary command execution inside the Liquidsoap process context: reading container files and environment variables, writing or corrupting files, and disrupting the broadcast process. Execution occurs passively when the AutoDJ generates the playlist annotation and Liquidsoap loads the watched playlist file, making the attack persistent and easy to overlook.

Proof of Concept

Prerequisites:
- A default AzuraCast station running Liquidsoap (process: protocol enabled by default).
- An account with the station-level Media permission.
- A media file whose ID3 title tag is set to the payload below.
  1. Set the media file's ID3 title tag to the following value (35 bytes), then upload it through the station media management API and add it to a playlist:
\":process:wav,id>/tmp/pwned #
  1. When the AutoDJ builds the playlist annotation, the serializer emits the following line into the station's `.m3u` playlist file (the leading backslash is preserved, the quote is escaped, producing `\\"` which closes the title value early):
annotate:title="\\":process:wav,id>/tmp/pwned #",artist="Normal Artist",...:media:path/to/song.mp3
  1. Liquidsoap, watching the playlist file, parses `title` as the literal `\`, treats the following `:` as the end of the annotation block, and resolves the remainder as the URI `process:wav,id>/tmp/pwned #...`. The `process:` protocol runs the command portion through the shell:
# /tmp/pwned inside the Liquidsoap container now contains the output of `id`
# (the trailing `#` comments out the rest of the generated line)

Attack Chain

  1. Exposure: An authenticated media manager uploads a media file through the station media management API, guarded by `StationPermissions::Media`.
  2. Control: The ID3 title is stored by `StationMedia::fromMetadata()` at `backend/src/Entity/StationMedia.php:177` via `Types::stringOrNull()`, with only a 255-character truncation at `backend/src/Entity/Traits/HasSongFields.php:53`; backslash and quote survive.
  3. Path: On a `WriteLiquidsoapConfiguration` event, `PlaylistFileWriter` (`backend/src/Radio/Backend/Liquidsoap/PlaylistFileWriter.php:148-167`) dispatches `AnnotateNextSong`, whose `Annotations` subscriber adds the title (`backend/src/Radio/AutoDJ/Annotations.php:101-103`); `AnnotateNextSong::buildAnnotations()` calls `ConfigWriter::annotateArray()` which calls `annotateValue()`.
  4. Guard: `annotateValue()` at `backend/src/Radio/Backend/Liquidsoap/ConfigWriter.php:1418` escapes `"` to `\"` but leaves `\` untouched, so a trailing backslash before the quote produces `\\"` and the quoted value is terminated early. The annotation key allowlist filters keys, not values.
  5. Primitive: The broken-out bytes are written verbatim to the `.m3u` file and parsed by Liquidsoap's `playlist()` loader as a resource URI, reaching the built-in `process:` protocol.
  6. Result: The `process:` protocol executes the attacker's command through the shell, giving arbitrary OS command execution within the Liquidsoap container.

Bypass Evidence

The relevant protection is the quote escaping in `annotateValue()` (`ConfigWriter.php:1418`), intended to keep attacker text inside the quoted annotation value. It fails because the backslash escape character is not itself escaped. The strongest challenge to the finding was whether Liquidsoap's annotation lexer actually treats `\\` as an escape sequence; if it treated only `\"` as special, the sequence `\\"` would keep the value open. Inspection of Liquidsoap v2.4.5 (installed via `util/docker/stations/setup/liquidsoap.sh:21`) resolves this: the lexer's string reader consumes `\\` as a single escape unit producing a literal backslash, leaving the following `"` as an unescaped closing delimiter, so the value terminates and the remaining bytes are parsed as annotation/URI syntax. The `process:` protocol is registered by default in the Liquidsoap standard library and is not disabled or restricted by AzuraCast. The earlier remote-relay-password advisory addressed a different function (`cleanUpString`) and did not modify `annotateValue()`.

Affected Versions

  • Ecosystem: `composer`
  • Package: `azuracast/azuracast`
  • Confirmed affected range: `<= 0.23.8`
  • Latest release checked: `0.23.8` (Packagist https://packagist.org/packages/azuracast/azuracast)
  • Fix status: not fixed

The incomplete escaping in `annotateValue()` is present in the latest stable release (0.23.8). The earlier remote-relay-password fix (released in 0.23.6) did not modify this function, so the issue is independent of that advisory. The introduction boundary was not established from the available history.

Suggested Fix

Neutralize the backslash before (or together with) the double quote when serializing annotation values, so that a value's trailing backslash cannot terminate the quoted field. Escaping `\` to `\\` and `"` to `\"` (backslash first) makes the serialized value self-consistent with Liquidsoap's string lexer. The fix must cover every annotated field, not only the title, since any attacker-influenced tag reaches the same serializer. As an interim mitigation, operators can restrict the station Media permission; this reduces exposure but does not remove the underlying flaw.

---

Reported by zx.

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Vector CVSS 3.1

Desglose de métricas

Opción resaltada = valor del vector · izquierda = peor caso · GitHub
Vector de ataqueAV:N
RedAdyacenteLocalFísica
ComplejidadAC:L
BajaAlta
PrivilegiosPR:L
NingunoBajosAltos
InteracciónUI:N
NingunaRequerida
AlcanceS:U
CambiadoSin cambio
ConfidencialidadC:H
AltoBajoNinguno
IntegridadI:H
AltoBajoNinguno
DisponibilidadA:H
AltoBajoNinguno
Versiones

Rangos afectados

Afectada Corregida
azuracast/azuracast≤ 0.23.8
0.23.8
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
Packagistazuracast/azuracast
Sin parche — — —
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://github.com/AzuraCast/AzuraCast/security/advisories/GHSA-mf65-hj88-hvrw

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.