« Volver al listado

CVE-2026-39311

Estado: AplazadaMedia (6.8)—

Trilium Notes is a cross-platform, hierarchical note taking application focused on building large personal knowledge bases. Versions 0.102.1 and prior contain a critical security flaw where lack of SVG sanitization combined with a disabled Content Security Policy (CSP) and a publicly reachable backend execution API results in an unauthenticated Remote Code Execution (RCE).

Leer descripción completaMostrar menos

The vulnerability arises from an insecure-by-design architecture: Trilium serves SVG attachments with the image/svg+xml MIME type without any sanitization, and it explicitly disables Helmet's Content Security Policy middleware, removing the primary defense against script execution in served assets. Because the malicious SVG runs under the Same-Origin Policy, it can issue a fetch('/') to extract the csrfToken from the document body. With that token, it can send a signed request to /api/script/exec to execute arbitrary Node.js code on the server. An attacker can compromise the entire server instance simply by tricking an authenticated user into viewing a shared SVG attachment. The issue has been fixed in version 0.102.2.

CVSS

Probabilidad de explotación (EPSS)

EPSS (Exploit Prediction Scoring System, de FIRST) estima la probabilidad de que una vulnerabilidad sea explotada en 30 días. Complementa a CVSS (impacto) y a CISA KEV (explotación confirmada).

Tecnologías afectadas (1)

⚠ Inferidas por IA a partir de la descripción — NVD aún no ha analizado esta CVE; no son CPE verificados.

CWE

Referencias

JSON original (NVD)

Mostrar
{
  "id": "CVE-2026-39311",
  "cveTags": [],
  "metrics": {
    "ssvcV203": [
      {
        "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "ssvcData": {
          "id": "CVE-2026-39311",
          "role": "CISA Coordinator",
          "options": [
            {
              "exploitation": "poc"
            },
            {
              "automatable": "no"
            },
            {
              "technicalImpact": "partial"
            }
          ],
          "version": "2.0.3",
          "timestamp": "2026-05-20T19:26:55.817058Z"
        }
      }
    ],
    "cvssMetricV31": [
      {
        "type": "Secondary",
        "source": "security-advisories@github.com",
        "cvssData": {
          "scope": "CHANGED",
          "version": "3.1",
          "baseScore": 6.8,
          "attackVector": "NETWORK",
          "baseSeverity": "MEDIUM",
          "vectorString": "CVSS:3.1/AV:N/AC:H/PR:H/UI:R/S:C/C:L/I:L/A:H",
          "integrityImpact": "LOW",
          "userInteraction": "REQUIRED",
          "attackComplexity": "HIGH",
          "availabilityImpact": "HIGH",
          "privilegesRequired": "HIGH",
          "confidentialityImpact": "LOW"
        },
        "impactScore": 5.3,
        "exploitabilityScore": 1
      }
    ]
  },
  "affected": [
    {
      "source": "security-advisories@github.com",
      "affectedData": [
        {
          "vendor": "TriliumNext",
          "product": "Trilium",
          "versions": [
            {
              "status": "affected",
              "version": "< 0.102.2"
            }
          ]
        }
      ]
    }
  ],
  "published": "2026-05-20T20:16:39.363",
  "references": [
    {
      "url": "https://github.com/TriliumNext/Trilium/releases/tag/v0.102.2",
      "source": "security-advisories@github.com"
    },
    {
      "url": "https://github.com/TriliumNext/Trilium/security/advisories/GHSA-p837-cxw3-m964",
      "source": "security-advisories@github.com"
    },
    {
      "url": "https://github.com/TriliumNext/Trilium/security/advisories/GHSA-p837-cxw3-m964",
      "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0"
    }
  ],
  "vulnStatus": "Deferred",
  "weaknesses": [
    {
      "type": "Secondary",
      "source": "security-advisories@github.com",
      "description": [
        {
          "lang": "en",
          "value": "CWE-79"
        },
        {
          "lang": "en",
          "value": "CWE-94"
        }
      ]
    }
  ],
  "descriptions": [
    {
      "lang": "en",
      "value": "Trilium Notes is a cross-platform, hierarchical note taking application focused on building large personal knowledge bases. Versions 0.102.1 and prior contain a critical security flaw where lack of SVG sanitization combined with a disabled Content Security Policy (CSP) and a publicly reachable backend execution API results in an unauthenticated Remote Code Execution (RCE). The vulnerability arises from an insecure-by-design architecture: Trilium serves SVG attachments with the image/svg+xml MIME type without any sanitization, and it explicitly disables Helmet's Content Security Policy middleware, removing the primary defense against script execution in served assets. Because the malicious SVG runs under the Same-Origin Policy, it can issue a fetch('/') to extract the csrfToken from the document body. With that token, it can send a signed request to /api/script/exec to execute arbitrary Node.js code on the server. An attacker can compromise the entire server instance simply by tricking an authenticated user into viewing a shared SVG attachment. The issue has been fixed in version 0.102.2."
    },
    {
      "lang": "es",
      "value": "Trilium Notes es una aplicación multiplataforma y jerárquica para tomar notas, centrada en la construcción de grandes bases de conocimiento personales. Las versiones 0.102.1 y anteriores contienen una falla de seguridad crítica donde la falta de saneamiento de SVG combinada con una Política de Seguridad de Contenido (CSP) deshabilitada y una API de ejecución de backend accesible públicamente resulta en una ejecución remota de código (RCE) no autenticada. La vulnerabilidad surge de una arquitectura insegura por diseño: Trilium sirve archivos adjuntos SVG con el tipo MIME image/svg+xml sin ningún saneamiento, y deshabilita explícitamente el middleware de Política de Seguridad de Contenido de Helmet, eliminando la defensa principal contra la ejecución de scripts en los activos servidos. Debido a que el SVG malicioso se ejecuta bajo la Política del Mismo Origen, puede emitir un fetch('/') para extraer el csrfToken del cuerpo del documento. Con ese token, puede enviar una solicitud firmada a /api/script/exec para ejecutar código Node.js arbitrario en el servidor. Un atacante puede comprometer toda la instancia del servidor simplemente engañando a un usuario autenticado para que vea un archivo adjunto SVG compartido. El problema ha sido solucionado en la versión 0.102.2."
    }
  ],
  "lastModified": "2026-07-23T12:10:00.110",
  "sourceIdentifier": "security-advisories@github.com"
}