{"api_version":"1","generated_at":"2026-07-23T14:07:06+00:00","cve":"CVE-2022-24795","urls":{"html":"https://cve.report/CVE-2022-24795","api":"https://cve.report/api/cve/CVE-2022-24795.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2022-24795","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2022-24795"},"summary":{"title":"CVE-2022-24795","description":"yajl-ruby is a C binding to the YAJL JSON parsing and generation library. The 1.x branch and the 2.x branch of `yajl` contain an integer overflow which leads to subsequent heap memory corruption when dealing with large (~2GB) inputs. The reallocation logic at `yajl_buf.c#L64` may result in the `need` 32bit integer wrapping to 0 when `need` approaches a value of 0x80000000 (i.e. ~2GB of data), which results in a reallocation of buf->alloc into a small heap chunk. These integers are declared as `size_t` in the 2.x branch of `yajl`, which practically prevents the issue from triggering on 64bit platforms, however this does not preclude this issue triggering on 32bit builds on which `size_t` is a 32bit integer. Subsequent population of this under-allocated heap chunk is based on the original buffer size, leading to heap memory corruption. This vulnerability mostly impacts process availability. Maintainers believe exploitation for arbitrary code execution is unlikely. A patch is available and anticipated to be part of yajl-ruby version 1.4.2. As a workaround, avoid passing large inputs to YAJL.","state":"PUBLIC","assigner":"security-advisories@github.com","published_at":"2022-04-05 16:15:00","updated_at":"2023-11-07 03:44:00"},"problem_types":["CWE-190","CWE-122"],"metrics":[],"references":[{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/KLE3C4CECEJ4EUYI56KXI6OWACWXX7WN/","name":"FEDORA-2023-00572178e1","refsource":"FEDORA","tags":[],"title":"[SECURITY] Fedora 38 Update: yajl-2.1.0-21.fc38 - package-announce - Fedora Mailing-Lists","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/KLE3C4CECEJ4EUYI56KXI6OWACWXX7WN/","name":"FEDORA-2023-00572178e1","refsource":"","tags":[],"title":"[SECURITY] Fedora 38 Update: yajl-2.1.0-21.fc38 - package-announce - Fedora Mailing-Lists","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/YO32YDJ74DADC7CMJNLSLBVWN5EXGF5J/","name":"FEDORA-2023-852b377773","refsource":"","tags":[],"title":"[SECURITY] Fedora 37 Update: yajl-2.1.0-21.fc37 - package-announce - Fedora Mailing-Lists","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/brianmario/yajl-ruby/commit/7168bd79b888900aa94523301126f968a93eb3a6","name":"https://github.com/brianmario/yajl-ruby/commit/7168bd79b888900aa94523301126f968a93eb3a6","refsource":"MISC","tags":[],"title":"Merge pull request #204 from eileencodes/fix-c-warnings · brianmario/yajl-ruby@7168bd7 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/brianmario/yajl-ruby/security/advisories/GHSA-jj47-x69x-mxrm","name":"https://github.com/brianmario/yajl-ruby/security/advisories/GHSA-jj47-x69x-mxrm","refsource":"CONFIRM","tags":[],"title":"Reallocation bug can trigger heap memory corruption · Advisory · brianmario/yajl-ruby · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/YO32YDJ74DADC7CMJNLSLBVWN5EXGF5J/","name":"FEDORA-2023-852b377773","refsource":"FEDORA","tags":[],"title":"[SECURITY] Fedora 37 Update: yajl-2.1.0-21.fc37 - package-announce - Fedora Mailing-Lists","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://lists.debian.org/debian-lts-announce/2023/07/msg00013.html","name":"[debian-lts-announce] 20230711 [SECURITY] [DLA 3492-1] yajl security update","refsource":"MLIST","tags":[],"title":"[SECURITY] [DLA 3492-1] yajl security update","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://lists.debian.org/debian-lts-announce/2023/08/msg00003.html","name":"[debian-lts-announce] 20230805 [SECURITY] [DLA 3516-1] burp security update","refsource":"MLIST","tags":[],"title":"[SECURITY] [DLA 3516-1] burp security update","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/brianmario/yajl-ruby/blob/7168bd79b888900aa94523301126f968a93eb3a6/ext/yajl/yajl_buf.c#L64","name":"https://github.com/brianmario/yajl-ruby/blob/7168bd79b888900aa94523301126f968a93eb3a6/ext/yajl/yajl_buf.c#L64","refsource":"MISC","tags":[],"title":"yajl-ruby/yajl_buf.c at 7168bd79b888900aa94523301126f968a93eb3a6 · brianmario/yajl-ruby · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://www.cve.org/CVERecord?id=CVE-2022-24795","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24795","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[{"cve_year":"2022","cve_id":"24795","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"yajl-ruby_project","cpe5":"yajl-ruby","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"ruby","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[{"cve":"CVE-2022-24795","qid":"160247","title":"Oracle Enterprise Linux Security Update for yajl (ELSA-2022-7524)"},{"cve":"CVE-2022-24795","qid":"160291","title":"Oracle Enterprise Linux Security Update for yajl (ELSA-2022-8252)"},{"cve":"CVE-2022-24795","qid":"184196","title":"Debian Security Update for ruby-yajl (CVE-2022-24795)"},{"cve":"CVE-2022-24795","qid":"199554","title":"Ubuntu Security Notification for YAJL Vulnerabilities (USN-6233-1)"},{"cve":"CVE-2022-24795","qid":"200011","title":"Ubuntu Security Notification for YAJL Vulnerabilities (USN-6233-2)"},{"cve":"CVE-2022-24795","qid":"240836","title":"Red Hat Update for yajl (RHSA-2022:7524)"},{"cve":"CVE-2022-24795","qid":"240907","title":"Red Hat Update for yajl (RHSA-2022:8252)"},{"cve":"CVE-2022-24795","qid":"284318","title":"Fedora Security Update for yajl (FEDORA-2023-00572178e1)"},{"cve":"CVE-2022-24795","qid":"284354","title":"Fedora Security Update for yajl (FEDORA-2023-852b377773)"},{"cve":"CVE-2022-24795","qid":"355555","title":"Amazon Linux Security Advisory for yajl : ALAS2-2023-2101"},{"cve":"CVE-2022-24795","qid":"355644","title":"Amazon Linux Security Advisory for yajl : ALAS2023-2023-263"},{"cve":"CVE-2022-24795","qid":"6000034","title":"Debian Security Update for burp (DLA 3516-1)"},{"cve":"CVE-2022-24795","qid":"671722","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-1776)"},{"cve":"CVE-2022-24795","qid":"671834","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-1919)"},{"cve":"CVE-2022-24795","qid":"672332","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-2786)"},{"cve":"CVE-2022-24795","qid":"672357","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-2751)"},{"cve":"CVE-2022-24795","qid":"672420","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-2812)"},{"cve":"CVE-2022-24795","qid":"672433","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-2837)"},{"cve":"CVE-2022-24795","qid":"672449","title":"EulerOS Security Update for yajl (EulerOS-SA-2022-2863)"},{"cve":"CVE-2022-24795","qid":"752161","title":"SUSE Enterprise Linux Security Update for libyajl (SUSE-SU-2022:1746-1)"},{"cve":"CVE-2022-24795","qid":"752560","title":"SUSE Enterprise Linux Security Update for libyajl (SUSE-SU-2022:3162-1)"},{"cve":"CVE-2022-24795","qid":"900813","title":"Common Base Linux Mariner (CBL-Mariner) Security Update for rubygem-yajl-ruby (9344)"},{"cve":"CVE-2022-24795","qid":"901350","title":"Common Base Linux Mariner (CBL-Mariner) Security Update for rubygem-yajl-ruby (9344-1)"},{"cve":"CVE-2022-24795","qid":"902748","title":"Common Base Linux Mariner (CBL-Mariner) Security Update for rubygem-yajl-ruby (10552)"},{"cve":"CVE-2022-24795","qid":"903928","title":"Common Base Linux Mariner (CBL-Mariner) Security Update for rubygem-yajl-ruby (10552-1)"},{"cve":"CVE-2022-24795","qid":"940753","title":"AlmaLinux Security Update for yajl (ALSA-2022:7524)"},{"cve":"CVE-2022-24795","qid":"940835","title":"AlmaLinux Security Update for yajl (ALSA-2022:8252)"},{"cve":"CVE-2022-24795","qid":"960281","title":"Rocky Linux Security Update for yajl (RLSA-2022:7524)"},{"cve":"CVE-2022-24795","qid":"960497","title":"Rocky Linux Security Update for yajl (RLSA-2022:8252)"}]},"source_records":{"cve_program":{"CVE_data_meta":{"ASSIGNER":"security-advisories@github.com","ID":"CVE-2022-24795","STATE":"PUBLIC","TITLE":"Buffer Overflow and Integer Overflow in yajl-ruby"},"affects":{"vendor":{"vendor_data":[{"product":{"product_data":[{"product_name":"yajl-ruby","version":{"version_data":[{"version_value":"<= 1.4.1"}]}}]},"vendor_name":"brianmario"}]}},"data_format":"MITRE","data_type":"CVE","data_version":"4.0","description":{"description_data":[{"lang":"eng","value":"yajl-ruby is a C binding to the YAJL JSON parsing and generation library. The 1.x branch and the 2.x branch of `yajl` contain an integer overflow which leads to subsequent heap memory corruption when dealing with large (~2GB) inputs. The reallocation logic at `yajl_buf.c#L64` may result in the `need` 32bit integer wrapping to 0 when `need` approaches a value of 0x80000000 (i.e. ~2GB of data), which results in a reallocation of buf->alloc into a small heap chunk. These integers are declared as `size_t` in the 2.x branch of `yajl`, which practically prevents the issue from triggering on 64bit platforms, however this does not preclude this issue triggering on 32bit builds on which `size_t` is a 32bit integer. Subsequent population of this under-allocated heap chunk is based on the original buffer size, leading to heap memory corruption. This vulnerability mostly impacts process availability. Maintainers believe exploitation for arbitrary code execution is unlikely. A patch is available and anticipated to be part of yajl-ruby version 1.4.2. As a workaround, avoid passing large inputs to YAJL."}]},"impact":{"cvss":{"attackComplexity":"HIGH","attackVector":"NETWORK","availabilityImpact":"HIGH","baseScore":5.9,"baseSeverity":"MEDIUM","confidentialityImpact":"NONE","integrityImpact":"NONE","privilegesRequired":"NONE","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H","version":"3.1"}},"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-122: Heap-based Buffer Overflow"}]},{"description":[{"lang":"eng","value":"CWE-190: Integer Overflow or Wraparound"}]}]},"references":{"reference_data":[{"name":"https://github.com/brianmario/yajl-ruby/security/advisories/GHSA-jj47-x69x-mxrm","refsource":"CONFIRM","url":"https://github.com/brianmario/yajl-ruby/security/advisories/GHSA-jj47-x69x-mxrm"},{"name":"https://github.com/brianmario/yajl-ruby/commit/7168bd79b888900aa94523301126f968a93eb3a6","refsource":"MISC","url":"https://github.com/brianmario/yajl-ruby/commit/7168bd79b888900aa94523301126f968a93eb3a6"},{"name":"https://github.com/brianmario/yajl-ruby/blob/7168bd79b888900aa94523301126f968a93eb3a6/ext/yajl/yajl_buf.c#L64","refsource":"MISC","url":"https://github.com/brianmario/yajl-ruby/blob/7168bd79b888900aa94523301126f968a93eb3a6/ext/yajl/yajl_buf.c#L64"},{"refsource":"MLIST","name":"[debian-lts-announce] 20230711 [SECURITY] [DLA 3492-1] yajl security update","url":"https://lists.debian.org/debian-lts-announce/2023/07/msg00013.html"},{"refsource":"FEDORA","name":"FEDORA-2023-00572178e1","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/KLE3C4CECEJ4EUYI56KXI6OWACWXX7WN/"},{"refsource":"FEDORA","name":"FEDORA-2023-852b377773","url":"https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/YO32YDJ74DADC7CMJNLSLBVWN5EXGF5J/"},{"refsource":"MLIST","name":"[debian-lts-announce] 20230805 [SECURITY] [DLA 3516-1] burp security update","url":"https://lists.debian.org/debian-lts-announce/2023/08/msg00003.html"}]},"source":{"advisory":"GHSA-jj47-x69x-mxrm","discovery":"UNKNOWN"}},"nvd":{"publishedDate":"2022-04-05 16:15:00","lastModifiedDate":"2023-11-07 03:44:00","problem_types":["CWE-190","CWE-122"],"metrics":{"baseMetricV3":{"cvssV3":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"NONE","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"NONE","integrityImpact":"NONE","availabilityImpact":"HIGH","baseScore":7.5,"baseSeverity":"HIGH"},"exploitabilityScore":3.9,"impactScore":3.6},"baseMetricV2":{"cvssV2":{"version":"2.0","vectorString":"AV:N/AC:L/Au:N/C:P/I:N/A:N","accessVector":"NETWORK","accessComplexity":"LOW","authentication":"NONE","confidentialityImpact":"PARTIAL","integrityImpact":"NONE","availabilityImpact":"NONE","baseScore":5},"severity":"MEDIUM","exploitabilityScore":10,"impactScore":2.9,"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:yajl-ruby_project:yajl-ruby:*:*:*:*:*:ruby:*:*","versionEndExcluding":"1.4.2","cpe_name":[]}]}]}},"legacy_mitre":{"record":{"CveYear":"2022","CveId":"24795","Ordinal":"228204","Title":"CVE-2022-24795","CVE":"CVE-2022-24795","Year":"2022"},"notes":[{"CveYear":"2022","CveId":"24795","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}]}}}