{"id":"CVE-2016-5394","aliases":["GHSA-xwf4-88xr-hx2j"],"kind":"cve","tier":"cold","status":"published","title":"Cross site scripting in Apache Sling","description":"In the XSS Protection API module before 1.0.12 in Apache Sling, the encoding done by the XSSAPI.encodeForJSString() method is not restrictive enough and for some input patterns allows script tags to pass through unencoded, leading to potential XSS vulnerabilities.","ai_summary":null,"severity":"medium","cvss":{"score":6.1,"version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","source":"NVD"},"scores":[{"score":6.1,"version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","source":"nvd"},{"score":4.3,"version":"2.0","vector":"AV:N/AC:M/Au:N/C:N/I:P/A:N","source":"nvd"}],"cwe":["CWE-79"],"remote":true,"remote_unauth":true,"epss":{"score":0.02604,"percentile":0.86133,"date":"2026-11-30"},"kev":{"listed":false,"added":null,"due":null,"ransomware":null},"exploit":{"public":false,"exploitdb_ids":[]},"affected":[{"ecosystem":"Maven","name":"org.apache.sling:org.apache.sling.xss","affected":"< 1.0.12","fixed":["1.0.12"],"source":"osv"},{"ecosystem":"Maven","name":"org.apache.sling:org.apache.sling.xss.compat","affected":"< 1.1.0","fixed":["1.1.0"],"source":"osv"}],"affected_products":[{"vendor":"Apache Software Foundation","product":"Apache Sling","versions":"prior to 1.0.12","source":"cvelist"}],"ai_versions":null,"mitigation":"Upgrade org.apache.sling:org.apache.sling.xss to 1.0.12 or later.\nUpgrade org.apache.sling:org.apache.sling.xss.compat to 1.1.0 or later.","technologies":[],"references":[{"url":"https://nvd.nist.gov/vuln/detail/CVE-2016-5394","kind":"vendor"},{"url":"https://github.com/apache/sling-org-apache-sling-xss/commit/de32b144ad2be3367559f6184d560db42a220529","kind":"patch"},{"url":"https://lists.apache.org/thread.html/332166037a54b97cf41e2b616aaed38439de94b19b204841478e4525%40%3Cdev.sling.apache.org%3E","kind":"other"},{"url":"http://www.securityfocus.com/bid/99870","kind":"other"},{"url":"https://github.com/jensdietrich/xshady-release/tree/main/CVE-2016-5394","kind":"other"},{"url":"https://lists.apache.org/thread.html/332166037a54b97cf41e2b616aaed38439de94b19b204841478e4525@%3Cdev.sling.apache.org%3E","kind":"other"}],"workarounds":null,"vendors":["apache","apache software foundation"],"products":["apache sling","sling"],"cpes":["cpe:2.3:a:apache:sling:*:*:*:*:*:*:*:*"],"published_at":"2017-07-19T15:00:00.000Z","modified_at":"2026-06-17T00:49:19.870Z","promoted_at":null,"attribution":[{"source":"CVE Program","text":"CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation.","url":"https://www.cve.org/Legal/TermsOfUse"},{"source":"NVD","text":"This product uses data from the NVD API but is not endorsed or certified by the NVD.","url":"https://nvd.nist.gov/vuln/detail/CVE-2016-5394"},{"source":"OSV","text":"CC-BY 4.0","url":"https://osv.dev/vulnerability/GHSA-xwf4-88xr-hx2j","license_url":"https://creativecommons.org/licenses/by/4.0/"}],"links":{"html":"https://flawdb.com/CVE-2016-5394","markdown":"https://flawdb.com/CVE-2016-5394.md","json":"https://flawdb.com/api/v1/entries/CVE-2016-5394"}}