Advisory Database
  • Advisories
  • Dependency Scanning
  1. maven
  2. ›
  3. org.elasticsearch/elasticsearch
  4. ›
  5. CVE-2023-31417

CVE-2023-31417: Elasticsearch allows insertion of sensitive information into log files when using deprecated URIs

October 26, 2023 (updated February 13, 2025)

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.

The _xpack/security APIs have been deprecated in Elasticsearch 7.x and were entirely removed in 8.0.0 and later. The only way for a client to use them in Elasticsearch 8.0.0 and later is to provide the Accept: application/json; compatible-with=7 header. Elasticsearch official clients do not use these deprecated APIs.

The list of affected, deprecated APIs, is the following:

POST /_xpack/security/user/{username} PUT /_xpack/security/user/{username} PUT /_xpack/security/user/{username}/_password POST /_xpack/security/user/{username}/_password PUT /_xpack/security/user/_password POST /_xpack/security/user/_password POST /_xpack/security/oauth2/token DELETE /_xpack/security/oauth2/token POST /_xpack/security/saml/authenticate

References

  • discuss.elastic.co/t/elasticsearch-8-9-2-and-7-17-13-security-update/342479
  • github.com/advisories/GHSA-99pc-69q9-jxf2
  • nvd.nist.gov/vuln/detail/CVE-2023-31417
  • security.netapp.com/advisory/ntap-20231130-0006
  • www.elastic.co/community/security

Code Behaviors & Features

Detect and mitigate CVE-2023-31417 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions starting from 7.0.0 before 7.17.13, all versions starting from 8.0.0 before 8.9.2

Fixed versions

  • 7.17.13
  • 8.9.2

Solution

Upgrade to versions 7.17.13, 8.9.2 or above.

Impact 4.1 MEDIUM

CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:H/I:N/A:N

Learn more about CVSS

Weakness

  • CWE-532: Insertion of Sensitive Information into Log File

Source file

maven/org.elasticsearch/elasticsearch/CVE-2023-31417.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:40 +0000.