{"id":"CVE-2022-24814","aliases":["CVE-2022-24814","GHSA-xmjj-3c76-5w84"],"related":[],"kind":"vulnerability","state":"published","title":"Cross-site Scripting in Directus","summary":"Directus is a real-time API and App dashboard for managing SQL database content. Prior to version 9.7.0, unauthorized JavaScript (JS) can be executed by inserting an iframe into the rich text html interface that links to a file uploaded HTML file that loads another uploaded JS file in its script tag. This satisfies the regular content security policy header, which in turn allows the file to run any arbitrary JS. This issue was resolved in version 9.7.0. As a workaround, disable the live embed in the what-you-see-is-what-you-get by adding `{ \"media_live_embeds\": false }` to the _Options Overrides_ option of the Rich Text HTML interface.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Directus is a real-time API and App dashboard for managing SQL database content. Prior to version 9.7.0, unauthorized JavaScript (JS) can be executed by inserting an iframe into the rich text html interface that links to a file uploaded HTML file that loads another uploaded JS file in its script tag. This satisfies the regular content security policy header, which in turn allows the file to run any arbitrary JS. This issue was resolved in version 9.7.0. As a workaround, disable the live embed in the what-you-see-is-what-you-get by adding `{ \"media_live_embeds\": false }` to the _Options Overrides_ option of the Rich Text HTML interface.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nUnauthorized JavaScript can be executed by inserting an iframe into the rich text html interface that links to a file uploaded HTML file that loads another uploaded JS file in its script tag. This satisfies the regular content security policy header, which in turn allows the file to run any arbitrary JS.\n\n### Patches\n\nThis was resolved in https://github.com/directus/directus/pull/12020 which is released in 9.7.0\n\n### Workarounds\n\nYou can disable the live embed in the WYSIWYG by adding `{ \"media_live_embeds\": false }` to the _Options Overrides_ option of the Rich Text HTML interface.\n\n### References\n\nhttps://github.com/directus/directus/pull/12020\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n* Open an issue in [directus/directus](https://github.com/directus/directus)\n* Email us at [security@directus.io](mailto:security@directus.io)","format":"markdown","source":"ghsa"},{"lang":"es","text":"Directus es una API y un panel de control de aplicaciones en tiempo real para administrar el contenido de las bases de datos SQL. En versiones anteriores a 9.7.0, podía ejecutarse JavaScript (JS) no autorizado mediante la inserción de un iframe en la interfaz html de texto enriquecido que enlaza con un archivo HTML cargado que carga otro archivo JS cargado en su etiqueta de script. Esto satisface el encabezado de la política de seguridad de contenido regular, que a su vez permite que el archivo ejecute cualquier JS arbitrario. Este problema fue resuelto en versión 9.7.0. Como medida de mitigación, deshabilite la inserción en vivo en \"what-you-see-is-what-you-get\" al añadir \"{ \"media_live_embeds\": false }\" a la opción _Options Overrides_ de la interfaz HTML de Texto Enriquecido","source":"nvd"}],"published":"2022-04-04T17:50:11.000Z","modified":"2026-06-17T04:32:34.783Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","score":6.1,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:N/I:P/A:N","score":4.3,"rating":"MEDIUM"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"version":"< 9.7.0","status":"affected"}],"vendor":"directus","product":"directus","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"9.7.0"}],"ecosystem":"npm","package":"directus","purl":"pkg:npm/directus","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"9.7.0"}],"vendor":"rangerstudio","product":"directus","cpe":"cpe:2.3:a:rangerstudio:directus:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/directus/directus/security/advisories/GHSA-xmjj-3c76-5w84","tags":["mitigation","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/directus/directus/pull/12020","tags":["issue-tracking","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/directus/directus/releases/tag/v9.7.0","tags":["release-notes","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24814","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/directus/directus","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2025-04-23T15:54:47.074Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-24814","url":"https://www.cve.org/CVERecord?id=CVE-2022-24814","licence":"CVE Terms of Use","modified":"2025-04-23T18:41:43.700Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-xmjj-3c76-5w84","url":"https://github.com/advisories/GHSA-xmjj-3c76-5w84","licence":"CC-BY-4.0","modified":"2023-11-08T04:08:37.325Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-24814","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24814","licence":"Public domain","modified":"2026-06-17T04:32:34.783Z"}],"updatedAt":"2026-11-25T22:58:10.399Z","epss":{"score":0.01034,"percentile":0.64785,"date":"2026-12-01T12:00:22.000Z"}}