{"api_version":"1","generated_at":"2026-04-22T16:31:26+00:00","cve":"CVE-2021-31805","urls":{"html":"https://cve.report/CVE-2021-31805","api":"https://cve.report/api/cve/CVE-2021-31805.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2021-31805","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2021-31805"},"summary":{"title":"CVE-2021-31805","description":"The fix issued for CVE-2020-17530 was incomplete. So from Apache Struts 2.0.0 to 2.5.29, still some of the tag’s attributes could perform a double evaluation if a developer applied forced OGNL evaluation by using the %{...} syntax. Using forced OGNL evaluation on untrusted user input can lead to a Remote Code Execution and security degradation.","state":"PUBLIC","assigner":"security@apache.org","published_at":"2022-04-12 16:15:00","updated_at":"2022-07-25 18:15:00"},"problem_types":["CWE-917"],"metrics":[],"references":[{"url":"https://cwiki.apache.org/confluence/display/WW/S2-062","name":"https://cwiki.apache.org/confluence/display/WW/S2-062","refsource":"MISC","tags":[],"title":"S2-062 - Apache Struts 2 Wiki - Apache Software Foundation","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://security.netapp.com/advisory/ntap-20220420-0001/","name":"https://security.netapp.com/advisory/ntap-20220420-0001/","refsource":"CONFIRM","tags":[],"title":"CVE-2021-31805 Apache Struts Vulnerability in NetApp Products | NetApp Product Security","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"http://www.openwall.com/lists/oss-security/2022/04/12/6","name":"[oss-security] 20220412 CVE-2021-31805: Apache Struts: Forced OGNL evaluation, when evaluated on raw not validated user input in tag attributes, may lead to RCE.","refsource":"MLIST","tags":[],"title":"oss-security - CVE-2021-31805: Apache Struts: Forced OGNL evaluation, when\n evaluated on raw not validated user input in tag attributes, may lead to\n RCE.","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://www.oracle.com/security-alerts/cpujul2022.html","name":"N/A","refsource":"N/A","tags":[],"title":"Oracle Critical Patch Update Advisory - July 2022","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://www.cve.org/CVERecord?id=CVE-2021-31805","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-31805","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[{"source":"LEGACY","value":"Apache Struts would like to thank Chris McCown for reporting this issue!","lang":""}],"nvd_cpes":[{"cve_year":"2021","cve_id":"31805","vulnerable":"1","versionEndIncluding":"2.5.29","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"apache","cpe5":"struts","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"*","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[{"cve":"CVE-2021-31805","qid":"150504","title":"Apache Struts 2 Remote Code Execution Vulnerability (CVE-2021-31805)"},{"cve":"CVE-2021-31805","qid":"376539","title":"Apache Struts2 Remote Code Execution (RCE) Vulnerability (S2-062)"},{"cve":"CVE-2021-31805","qid":"376540","title":"Apache Struts2 Remote Code Execution (RCE) Vulnerability (S2-062) (Tomcat Server Authentication Record)"}]},"source_records":{"cve_program":{"CVE_data_meta":{"ASSIGNER":"security@apache.org","ID":"CVE-2021-31805","STATE":"PUBLIC","TITLE":"Forced OGNL evaluation, when evaluated on raw not validated user input in tag attributes, may lead to RCE."},"affects":{"vendor":{"vendor_data":[{"product":{"product_data":[{"product_name":"Apache Struts","version":{"version_data":[{"version_value":"2.0.0 to 2.5.29"}]}}]},"vendor_name":"Apache Software Foundation"}]}},"credit":[{"lang":"eng","value":"Apache Struts would like to thank Chris McCown for reporting this issue!"}],"data_format":"MITRE","data_type":"CVE","data_version":"4.0","description":{"description_data":[{"lang":"eng","value":"The fix issued for CVE-2020-17530 was incomplete. So from Apache Struts 2.0.0 to 2.5.29, still some of the tag’s attributes could perform a double evaluation if a developer applied forced OGNL evaluation by using the %{...} syntax. Using forced OGNL evaluation on untrusted user input can lead to a Remote Code Execution and security degradation."}]},"generator":{"engine":"Vulnogram 0.0.9"},"impact":[[]],"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-917 Improper Neutralization of Special Elements used in an Expression Language Statement ('Expression Language Injection')"}]}]},"references":{"reference_data":[{"refsource":"MISC","url":"https://cwiki.apache.org/confluence/display/WW/S2-062","name":"https://cwiki.apache.org/confluence/display/WW/S2-062"},{"refsource":"MLIST","name":"[oss-security] 20220412 CVE-2021-31805: Apache Struts: Forced OGNL evaluation, when evaluated on raw not validated user input in tag attributes, may lead to RCE.","url":"http://www.openwall.com/lists/oss-security/2022/04/12/6"},{"url":"https://www.oracle.com/security-alerts/cpujul2022.html","refsource":"MISC","name":"https://www.oracle.com/security-alerts/cpujul2022.html"},{"refsource":"CONFIRM","name":"https://security.netapp.com/advisory/ntap-20220420-0001/","url":"https://security.netapp.com/advisory/ntap-20220420-0001/"}]},"source":{"discovery":"UNKNOWN"},"work_around":[{"lang":"eng","value":"Avoid using forced OGNL evaluation on untrusted user input, and/or upgrade to Struts 2.5.30 which checks if expression evaluation won’t lead to the double evaluation.\n\nPlease read our Security Bulletin S2-062 for more details."}]},"nvd":{"publishedDate":"2022-04-12 16:15:00","lastModifiedDate":"2022-07-25 18:15:00","problem_types":["CWE-917"],"metrics":{"baseMetricV3":{"cvssV3":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"NONE","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"HIGH","integrityImpact":"HIGH","availabilityImpact":"HIGH","baseScore":9.8,"baseSeverity":"CRITICAL"},"exploitabilityScore":3.9,"impactScore":5.9},"baseMetricV2":{"cvssV2":{"version":"2.0","vectorString":"AV:N/AC:L/Au:N/C:P/I:P/A:P","accessVector":"NETWORK","accessComplexity":"LOW","authentication":"NONE","confidentialityImpact":"PARTIAL","integrityImpact":"PARTIAL","availabilityImpact":"PARTIAL","baseScore":7.5},"severity":"HIGH","exploitabilityScore":10,"impactScore":6.4,"acInsufInfo":false,"obtainAllPrivilege":false,"obtainUserPrivilege":false,"obtainOtherPrivilege":false,"userInteractionRequired":false}},"configurations":{"CVE_data_version":"4.0","nodes":[{"operator":"OR","children":[],"cpe_match":[{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:apache:struts:*:*:*:*:*:*:*:*","versionStartIncluding":"2.0.0","versionEndIncluding":"2.5.29","cpe_name":[]}]}]}},"legacy_mitre":{"record":{"CveYear":"2021","CveId":"31805","Ordinal":"207099","Title":"CVE-2021-31805","CVE":"CVE-2021-31805","Year":"2021"},"notes":[{"CveYear":"2021","CveId":"31805","Ordinal":"1","NoteData":"** RESERVED ** This candidate has been reserved by an organization or individual that will use it when announcing a new security problem. When the candidate has been publicized, the details for this candidate will be provided.","Type":"Description","Title":null}]}}}