{"id":"CVE-2021-29460","published":"2021-04-27T20:10:13Z","modified":"2024-08-03T22:02:51Z","title":"Cross-site scripting (XSS) from unsanitized uploaded SVG files","vendor":"getkirby","product":"kirby","tier":"tail","description":{"text":"Kirby is an open source CMS. An editor with write access to the Kirby Panel can upload an SVG file that contains harmful content like `<script>` tags. The direct link to that file can be sent to other users or visitors of the site. If the victim opens that link in a browser where they are logged in to Kirby, the script will run and can for example trigger requests to Kirby's API with the permissions of the victim. This vulnerability is critical if you might have potential attackers in your group of authenticated Panel users, as they can escalate their privileges if they get access to the Panel session of an admin user. Depending on your site, other JavaScript-powered attacks are possible. Visitors without Panel access can only use this attack vector if your site allows SVG file uploads in frontend forms and you don't already sanitize uploaded SVG files. The problem has been patched in Kirby 3.5.4. Please update to this or a later version to fix the vulnerability. Frontend upload forms need to be patched separately depending on how they store the uploaded file(s). If you use `File::create()`, you are protected by updating to 3.5.4+. As a work around you can disable the upload of SVG files in your file blueprints.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.6,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:L/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.03174,"percentile":0.88352,"provenance":"source"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"references":[{"url":"https://github.com/getkirby/kirby/security/advisories/GHSA-qgp4-5qx6-548g","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/getkirby/kirby/releases/tag/3.5.4","tags":["x_refsource_MISC"]},{"url":"http://packetstormsecurity.com/files/162359/Kirby-CMS-3.5.3.1-Cross-Site-Scripting.html","tags":["x_refsource_MISC"]}],"priority":{"score":28.0,"factors":[{"name":"EPSS percentile","points":17.67},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":5.32}]},"exploitSources":{"exploitdb":{"count":1,"earliest":"2021-04-28"},"first":{"date":"2021-04-28","source":"Exploit-DB","url":"https://www.exploit-db.com/exploits/49808"},"provenance":"source"},"vendorSlug":"getkirby","affectedVersions":[{"vendor":"getkirby","product":"kirby","versions":["< 3.5.4"]}],"affected":[{"ecosystem":"Packagist","package":"getkirby/cms","vulnerableRanges":["<3.5.4"],"patched":["3.5.4"],"from":["GHSA-qgp4-5qx6-548g"],"provenance":"source"}],"euvd":{"id":"EUVD-2021-0862","exploited":false,"provenance":"source"},"exploits":[{"id":49808,"url":"https://www.exploit-db.com/exploits/49808","title":"Kirby CMS 3.5.3.1 - 'file' Cross-Site Scripting (XSS)","date":"2021-04-28","verified":false,"provenance":"source"}],"exploitRefs":["http://packetstormsecurity.com/files/162359/Kirby-CMS-3.5.3.1-Cross-Site-Scripting.html"],"summary":{"text":"The flaw is cross-site scripting in Kirby, an open source CMS, caused by SVG files uploaded through the Kirby Panel or frontend upload forms that are not sanitized and can embed script content such as <script> tags. An attacker who can write to the Panel (or who can upload through a frontend form that accepts SVG) can have a victim open the direct link to the malicious file in a browser where they are logged in to Kirby, which executes the script with the victim's permissions, requiring user interaction (opening the link) and, for Panel-side uploads, an authenticated editor account.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-21T04:19:11Z"},"lineage":{"packageHistory":[{"cve":"CVE-2017-16807","published":"2017-11-13","fixed":"2.5.7","kev":false},{"cve":"CVE-2020-26253","published":"2020-12-08","fixed":"3.3.6","kev":false},{"cve":"CVE-2020-26255","published":"2020-12-08","fixed":"3.4.5","kev":false,"link":{"from":"CVE-2020-26255","to":"CVE-2021-29460","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:getkirby/cms","fromFixed":"3.4.5","toFixed":"3.5.4","daysApart":140}]}},{"cve":"CVE-2021-29460","published":"2021-04-27","fixed":"3.5.4","kev":false},{"cve":"CVE-2021-32735","published":"2021-07-02","fixed":"3.5.7","kev":false,"link":{"from":"CVE-2021-29460","to":"CVE-2021-32735","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:getkirby/cms","fromFixed":"3.5.4","toFixed":"3.5.7","daysApart":66}]}},{"cve":"CVE-2021-41252","published":"2021-11-16","fixed":"3.5.8","kev":false},{"cve":"CVE-2021-41258","published":"2021-11-16","fixed":"3.5.8","kev":false}],"package":"Packagist:getkirby/cms"}}