Security advisory
Drupal 8.4.x versions before 8.4.5 and Drupal 7.x versions before 7.57 has a Drupal.checkPlain() JavaScript function which is used to escape potentially dangerous text before outputting it to HTML (as JavaScript output does not typically go through Twig autoescaping). This function does not correctly handle all methods of injecting malicious HTML, leading to a cross-site scripting vulnerability under certain circumstances. The PHP functions which Drupal provides for HTML escaping are not affected.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2017-6927
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 07:32 UTC · Revision 1
Source evidence
Drupal 8.4.x versions before 8.4.5 and Drupal 7.x versions before 7.57 has a Drupal.checkPlain() JavaScript function which is used to escape potentially dangerous text before outputting it to HTML (as JavaScript output does not typically go through Twig autoescaping). This function does not correctly handle all methods of injecting malicious HTML, leading to a cross-site scripting vulnerability under certain circumstances. The PHP functions which Drupal provides for HTML escaping are not affected.
osv:CVE-2017-6927
Complete source record
{
"id": "9e382c492aae4a8aad1aa6df07688145d1c2fe5697c5f425ebb6dfbc031c3a14",
"url": "https://osv.dev/vulnerability/CVE-2017-6927",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "CVE-2017-6927",
"summary": "Drupal 8.4.x versions before 8.4.5 and Drupal 7.x versions before 7.57 has a Drupal.checkPlain() JavaScript function which is used to escape potentially dangerous text before outputting it to HTML (as JavaScript output does not typically go through Twig autoescaping). This function does not correctly handle all methods of injecting malicious HTML, leading to a cross-site scripting vulnerability under certain circumstances. The PHP functions which Drupal provides for HTML escaping are not affected.",
"evidence": "osv:CVE-2017-6927",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2017-6927",
"aliases": [
"CVE-2017-6927",
"GHSA-585j-5449-mf5m"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/drupal/drupal",
"type": "GIT",
"events": [
{
"introduced": "497914920385b7016ac9c9367e0198530787adf2"
},
{
"fixed": "bc929eb17c4f4eea83cb796b7c5bbb984bf288bd"
},
{
"introduced": "abfe77673a5a6194ef13600e05f1ca2c5dd59db8"
},
{
"fixed": "3347ff569787d2e659a8c4b5211ea0c76894aa8a"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:drupal:drupal:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "7.0"
},
{
"fixed": "7.57"
}
],
"source": "CPE_RANGE"
},
{
"cpe": "cpe:2.3:a:drupal:drupal:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "8.4.0"
},
{
"fixed": "8.4.5"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"versions": [
"7.56",
"8.4.4",
"8.4.3",
"8.4.1",
"8.4.0",
"7.55",
"7.54",
"7.51",
"7.50",
"7.43",
"7.42",
"7.40",
"7.37",
"7.36",
"7.33",
"7.30",
"7.28",
"7.25",
"7.23",
"7.22",
"7.17",
"7.15",
"7.14",
"7.12",
"7.10",
"7.9",
"7.8",
"7.7",
"7.6",
"7.4",
"7.0"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2017-6927.json"
}
}
],
"modified": "2026-10-24T10:30:54.645284313Z",
"provider": "osv",
"references": [
"https://lists.debian.org/debian-lts-announce/2018/02/msg00030.html",
"https://www.debian.org/security/2018/dsa-4123",
"https://www.drupal.org/sa-core-2018-001"
],
"provider_metadata": {
"unresolved_ranges": [
{
"cpes": [
"cpe:2.3:o:debian:debian_linux:7.0:*:*:*:*:*:*:*",
"cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:*",
"cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:*"
],
"vendor_product": "debian:debian_linux",
"extracted_events": [
{
"range": [
{
"introduced": "7.0"
},
{
"last_affected": "7.0"
},
{
"introduced": "8.0"
},
{
"last_affected": "8.0"
},
{
"introduced": "9.0"
},
{
"last_affected": "9.0"
}
],
"source": "CPE_STRING"
}
]
}
]
}
},
"related_cves": [
{
"value": "CVE-2017-6927",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 438246,
"published_at": "2018-03-01T23:29:00.297+00:00"
}