CVE-2021-32687

Source
https://nvd.nist.gov/vuln/detail/CVE-2021-32687
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-32687.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2021-32687
Aliases
Downstream
Related
Published
2021-10-04T18:15:08Z
Modified
2025-10-21T06:23:00.152779Z
Severity
  • 7.5 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H CVSS Calculator
Summary
[none]
Details

Redis is an open source, in-memory database that persists on disk. An integer overflow bug affecting all versions of Redis can be exploited to corrupt the heap and potentially be used to leak arbitrary contents of the heap or trigger remote code execution. The vulnerability involves changing the default set-max-intset-entries configuration parameter to a very large value and constructing specially crafted commands to manipulate sets. The problem is fixed in Redis versions 6.2.6, 6.0.16 and 5.0.14. An additional workaround to mitigate the problem without patching the redis-server executable is to prevent users from modifying the set-max-intset-entries configuration parameter. This can be done using ACL to restrict unprivileged users from using the CONFIG SET command.

References

Affected packages

Git / github.com/redis/redis

Affected ranges

Type
GIT
Repo
https://github.com/redis/redis
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed

Affected versions

1.*

1.3.6

2.*

2.2-alpha0
2.2-alpha1
2.2-alpha2
2.2-alpha3
2.2-alpha4
2.2-alpha5
2.2-alpha6
2.2.0-rc1
2.3-alpha0

3.*

3.0-alpha0

6.*

6.0-rc1
6.0-rc2
6.0-rc3
6.0-rc4
6.0.0
6.0.1
6.0.10
6.0.11
6.0.12
6.0.13
6.0.14
6.0.15
6.0.2
6.0.3
6.0.4
6.0.5
6.0.6
6.0.7
6.0.8
6.0.9

v1.*

v1.3.10
v1.3.11
v1.3.12
v1.3.7
v1.3.8
v1.3.9

v2.*

v2.0.0-rc1
v2.1.1-watch

Other

vm-playpen
with-deprecated-diskstore

Database specific

vanir_signatures

[
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "function_hash": "163374385307919996169603807566722008298",
            "length": 796.0
        },
        "target": {
            "function": "setTypeAdd",
            "file": "src/t_set.c"
        },
        "id": "CVE-2021-32687-09ba254e",
        "signature_version": "v1",
        "signature_type": "Function"
    },
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "function_hash": "217063412695412142447083598775486453418",
            "length": 181.0
        },
        "target": {
            "function": "intsetResize",
            "file": "src/intset.c"
        },
        "id": "CVE-2021-32687-0e358c91",
        "signature_version": "v1",
        "signature_type": "Function"
    },
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "line_hashes": [
                "140849402641415107276920796326342243538",
                "333118168896657835652472093189441187232",
                "177324244873274311681210084292119202060",
                "308065048512062839392776920498412187852",
                "310703842695805511237573896521209319241",
                "331168296259049404326064170252063855112",
                "269902090033988468564013793944401229956",
                "100237252929914813264200488194405682217"
            ],
            "threshold": 0.9
        },
        "target": {
            "file": "src/intset.c"
        },
        "id": "CVE-2021-32687-17de4435",
        "signature_version": "v1",
        "signature_type": "Line"
    },
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "function_hash": "276374166453835116410816728935794231984",
            "length": 12233.0
        },
        "target": {
            "function": "rdbLoadObject",
            "file": "src/rdb.c"
        },
        "id": "CVE-2021-32687-77d15c7b",
        "signature_version": "v1",
        "signature_type": "Function"
    },
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "line_hashes": [
                "106521085850135694835085511936269110113",
                "199585812136464185892049582304248925649",
                "283358587199406723104373641907616742524",
                "310658462356237403657528470863930625417"
            ],
            "threshold": 0.9
        },
        "target": {
            "file": "src/rdb.c"
        },
        "id": "CVE-2021-32687-aa835a9d",
        "signature_version": "v1",
        "signature_type": "Line"
    },
    {
        "source": "https://github.com/redis/redis/commit/a30d367a71b7017581cf1ca104242a3c644dec0f",
        "deprecated": false,
        "digest": {
            "line_hashes": [
                "42972112153381367478724153702700649638",
                "122192708489737370840450715535837563512",
                "46113033731694472795238659054787843228",
                "313031480431835061739073001623099059075"
            ],
            "threshold": 0.9
        },
        "target": {
            "file": "src/t_set.c"
        },
        "id": "CVE-2021-32687-e538c15f",
        "signature_version": "v1",
        "signature_type": "Line"
    }
]