CVE-2021-32785
Format string bug in the Redis cache implementation
Reported by github_m · Published July 22, 2021
mod_auth_openidc is an authentication/authorization module for the Apache 2.x HTTP server that functions as an OpenID Connect Relying Party, authenticating users against an OpenID Connect Provider. When mod_auth_openidc versions prior to 2.4.9 are configured to use an unencrypted Redis cache (`OIDCCacheEncrypt off`, `OIDCSessionType server-cache`, `OIDCCacheType redis`), `mod_auth_openidc` wrongly performed argument interpolation before passing Redis requests to `hiredis`, which would perform it again and lead to an uncontrolled format string bug. Initial assessment shows that this bug does not appear to allow gaining arbitrary code execution, but can reliably provoke a denial of service by repeatedly crashing the Apache workers. This bug has been corrected in version 2.4.9 by performing argument interpolation only once, using the `hiredis` API. As a workaround, this vulnerability can be mitigated by setting `OIDCCacheEncrypt` to `on`, as cache keys are cryptographically hashed before use when this option is enabled.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| mod_auth_openidc | openidc | 2.4.9 |
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| zmartzone | mod_auth_openidc | < 2.4.9 |
| zmartzone | mod_auth_openidc | 0 |
Timeline
- Jul 22, 2021 CVE Published
- Jul 23, 2021 EPSS Score (30 in total, the first dated here)
- Aug 3, 2024 CVE Updated
- Aug 1, 2026 Coalition ESS Score
- Sep 21, 2026 Security Advisory (2 in total, the first dated here)
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2021-32785
vulnetix vdb fixes CVE-2021-32785
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2021-32785/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart