{"id":"CVE-2021-21425","published":"2021-04-07T18:20:13Z","modified":"2024-08-03T18:09:16Z","title":"Unauthenticated Arbitrary YAML Write/Update leads to Code Execution","vendor":"getgrav","product":"grav-plugin-admin","tier":"core","eol":null,"affectedVersions":[{"vendor":"getgrav","product":"grav-plugin-admin","versions":["<= 1.10.7"]}],"description":{"text":"Grav Admin Plugin is an HTML user interface that provides a way to configure Grav and create and modify pages. In versions 1.10.7 and earlier, an unauthenticated user can execute some methods of administrator controller without needing any credentials. Particular method execution will result in arbitrary YAML file creation or content change of existing YAML files on the system. Successfully exploitation of that vulnerability results in configuration changes, such as general site information change, custom scheduler job definition, etc. Due to the nature of the vulnerability, an adversary can change some part of the webpage, or hijack an administrator account, or execute operating system command under the context of the web-server user. This vulnerability is fixed in version 1.10.8. Blocking access to the `/admin` path from untrusted sources can be applied as a workaround.","provenance":"source","from":"CVE.org"},"summary":{"text":"The Grav Admin Plugin (grav-plugin-admin) by getgrav contains an improper access control flaw in its administrator controller, which can be reached without credentials. An unauthenticated remote attacker over the network can trigger this by calling certain controller methods, creating or modifying YAML files on the server, which can lead to configuration changes, page tampering, administrator account hijacking, or operating system command execution as the web-server user.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-10-29T07:12:40Z"},"cvss":{"score":9.3,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:H/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.806,"percentile":0.99744,"date":"2026-11-25","provenance":"source"},"kev":null,"vulncheckKev":null,"exploited":false,"otx":{"pulseCount":0,"pulses":[],"provenance":"machine"},"cwes":[{"id":"CWE-284","name":"Improper Access Control"}],"references":[{"url":"https://pentest.blog/unexpected-journey-7-gravcms-unauthenticated-arbitrary-yaml-write-update-leads-to-code-execution/","tags":["x_refsource_MISC"]},{"url":"https://github.com/getgrav/grav-plugin-admin/security/advisories/GHSA-6f53-6qgv-39pj","tags":["x_refsource_CONFIRM"]},{"url":"http://packetstormsecurity.com/files/162283/GravCMS-1.10.7-Remote-Command-Execution.html","tags":["x_refsource_MISC"]},{"url":"http://packetstormsecurity.com/files/162457/GravCMS-1.10.7-Remote-Command-Execution.html","tags":["x_refsource_MISC"]}],"techniques":[],"reports":[],"affected":[],"advisories":[],"euvd":{"id":"EUVD-2021-8706","url":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2021-8706","exploited":false,"exploitedSince":null,"provenance":"source"},"exploits":[{"id":49788,"url":"https://www.exploit-db.com/exploits/49788","title":"Getgrav GravCMS 1.10.7 - Unauthenticated Arbitrary File Write (Metasploit)","type":"webapps","platform":"php","date":"2021-04-21","verified":true,"provenance":"source"}],"exploitSources":{"exploitdb":{"count":1,"earliest":"2021-04-21"},"pocGithub":{"count":4,"skipped":2,"earliest":"2021-06-24","earliestUrl":"https://github.com/CsEnox/CVE-2021-21425","repos":[{"name":"CsEnox/CVE-2021-21425","url":"https://github.com/CsEnox/CVE-2021-21425","stars":12,"created":"2021-06-24"},{"name":"bluetoothStrawberry/cve-2021-21425","url":"https://github.com/bluetoothStrawberry/cve-2021-21425","stars":2,"created":"2024-11-13"},{"name":"d4ytox/CVE-2021-21425","url":"https://github.com/d4ytox/CVE-2021-21425","stars":2,"created":"2026-06-13"},{"name":"grey-master-a/GravCMS_Nmap_Script","url":"https://github.com/grey-master-a/GravCMS_Nmap_Script","stars":0,"created":"2022-01-19"}]},"metasploit":[{"name":"GravCMS Remote Command Execution","module":"exploit/linux/http/gravcms_exec","type":"exploit","disclosureDate":"2021-03-29","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/gravcms_exec.rb"}],"first":{"date":"2021-03-29","source":"Metasploit","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/gravcms_exec.rb"},"provenance":"source"},"exploitRefs":["http://packetstormsecurity.com/files/162283/GravCMS-1.10.7-Remote-Command-Execution.html","http://packetstormsecurity.com/files/162457/GravCMS-1.10.7-Remote-Command-Execution.html"],"flow":[],"timeline":[{"date":"2021-03-29","kind":"exploit-public","label":"First public exploit: Metasploit; later: Exploit-DB 2021-04-21, PoC-in-GitHub 2021-06-24","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/gravcms_exec.rb","provenance":"source"},{"date":"2021-04-07","kind":"published","label":"Published (CVE.org)","url":"https://www.cve.org/CVERecord?id=CVE-2021-21425","provenance":"source"}],"speed":{"daysToPublicExploit":null,"firstExploitFrom":"Metasploit","daysToKev":null},"priority":{"score":31.5,"factors":[{"name":"In a KEV catalog","points":0.0,"detail":"not listed"},{"name":"Recent KEV listing","points":0.0,"detail":"not listed"},{"name":"Known ransomware use","points":0.0,"detail":"not known"},{"name":"EPSS percentile","points":19.95,"detail":"percentile 0.9974"},{"name":"Named in threat reports","points":0.0,"detail":"0 reports"},{"name":"Public exploit code","points":5.0,"detail":"1 Exploit-DB entry; 2 NVD exploit links; 4 PoC-in-GitHub repos; 1 Metasploit module"},{"name":"Mentioned in OTX pulses","points":0.0,"detail":"0 pulses"},{"name":"CVSS severity","points":6.51,"detail":"base score 9.3"},{"name":"End-of-life product","points":0.0,"detail":"supported or unknown"}]}}