p PatchFirst

CVE-2022-24795

CVE-2022-24795 · Buffer Overflow and Integer Overflow in yajl-ruby

This page contains facts from public vulnerability sources. Check the original advisory before updating.

This page shows selected source facts. See the linked advisories for the complete description and affected versions.

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.

CVSS 5.9 · Medium · EPSS 3.5% · Fix available

Published
Updated

Stack: system

Affected products and versions

  • yajl-ruby

    Versions
    • <= 1.4.1: Affected

    No fix published

  • burp Debian:12

    Versions
    • 3.1.4-1
    • 3.1.4-3
    • 3.1.4-3.1
    • 3.1.4-4
    • 3.1.4-5
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • burp Debian:13

    Affected ranges
    • ECOSYSTEM: < 3.1.4-2

    Update to 3.1.4-2

  • r-cran-jsonlite Debian:12

    Versions
    • 1.8.4+dfsg-1
    • 1.8.5+dfsg-1
    • 1.8.7+dfsg-1
    • 1.8.8+dfsg-1
    • 1.8.9+dfsg-1
    • 1.9.1+dfsg-1
    • 2.0.0+dfsg-1
    • 2.0.0+dfsg-2
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • r-cran-jsonlite Debian:13

    Affected ranges
    • ECOSYSTEM: < 1.8.8+dfsg-1

    Update to 1.8.8+dfsg-1

  • r-cran-jsonlite Debian:14

    Affected ranges
    • ECOSYSTEM: < 1.8.8+dfsg-1

    Update to 1.8.8+dfsg-1

  • ruby-yajl Debian:12

    Affected ranges
    • ECOSYSTEM: < 1.4.3-1

    Update to 1.4.3-1

  • ruby-yajl Debian:13

    Affected ranges
    • ECOSYSTEM: < 1.4.3-1

    Update to 1.4.3-1

  • ruby-yajl Debian:14

    Affected ranges
    • ECOSYSTEM: < 1.4.3-1

    Update to 1.4.3-1

  • yajl Debian:12

    Versions
    • 2.1.0-3
    • 2.1.0-3+deb12u1
    Affected ranges
    • ECOSYSTEM: < 2.1.0-3+deb12u2

    Update to 2.1.0-3+deb12u2

  • yajl Debian:13

    Affected ranges
    • ECOSYSTEM: < 2.1.0-4

    Update to 2.1.0-4

  • yajl Debian:14

    Affected ranges
    • ECOSYSTEM: < 2.1.0-4

    Update to 2.1.0-4

  • yajl Ubuntu:Pro:14.04:LTS

    Versions
    • 2.0.4-4
    Affected ranges
    • ECOSYSTEM: < 2.0.4-4ubuntu0.1~esm1

    Update to 2.0.4-4ubuntu0.1~esm1

  • yajl Ubuntu:Pro:16.04:LTS

    Versions
    • 2.1.0-2
    Affected ranges
    • ECOSYSTEM: < 2.1.0-2ubuntu0.16.04.1~esm1

    Update to 2.1.0-2ubuntu0.16.04.1~esm1

  • argyll Ubuntu:16.04:LTS

    Versions
    • 1.7.0+repack-4
    • 1.8.2+repack-1
    • 1.8.3+repack-1
    • 1.8.3+repack-2
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • burp Ubuntu:16.04:LTS

    Versions
    • 1.3.48-4.1
    • 1.3.48-4.1build1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • collada2gltf Ubuntu:16.04:LTS

    Versions
    • 20140924-3
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • icinga2 Ubuntu:16.04:LTS

    Versions
    • 2.3.8-1build1
    • 2.3.11-1
    • 2.4.0-1
    • 2.4.1-1
    • 2.4.1-2
    • 2.4.1-2ubuntu1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • libbson Ubuntu:Pro:16.04:LTS

    Versions
    • 1.3.1-1
    • 1.3.1-1ubuntu0.1~esm1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • lnav Ubuntu:16.04:LTS

    Versions
    • 0.7.0-3build1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • php-mongodb Ubuntu:16.04:LTS

    Versions
    • 1.1.2-2~ubuntu1
    • 1.1.5-1~build1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • r-cran-jsonlite Ubuntu:16.04:LTS

    Versions
    • 0.9.19-1
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • ruby-yajl Ubuntu:16.04:LTS

    Versions
    • 1.2.0-3build1
    • 1.2.0-3build2
    • 1.2.0-3build3
    • 1.2.0-3build4
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

  • tulip Ubuntu:16.04:LTS

    Versions
    • 4.7.0dfsg-1ubuntu1
    • 4.7.0dfsg-1ubuntu2
    • 4.7.0dfsg-2ubuntu1
    • 4.7.0dfsg-2ubuntu2
    • 4.8.0dfsg-1
    • 4.8.0dfsg-1build1
    • 4.8.0dfsg-2
    • 4.8.0dfsg-2build1
    • 4.8.0dfsg-2build2
    Affected ranges
    • ECOSYSTEM: (−∞, +∞)

    No fix published

Original sources

Check your server →