CVE-2023-23612: Issue with whitespace in JWT roles in OpenSearch

Published Jan 24, 2023
·
Updated

Advisory title: Issue with whitespace in JWT roles

Affected versions: OpenSearch 1.0.0-1.3.7 and 2.0.0-2.4.1

Patched versions: OpenSearch 1.3.8 and 2.5.0

Impact: OpenSearch uses JWTs to store role claims obtained from the Identity Provider (IdP) when the authentication backend is SAML or OpenID Connect. There is an issue in how those claims are processed from the JWTs where the leading and trailing whitespace is trimmed, allowing users to potentially claim roles they are not assigned to if any role matches the whitespace-stripped version of the roles they are a member of.

This issue is only present for authenticated users, and it requires either the existence of roles that match, not considering leading/trailing whitespace, or the ability for users to create said matching roles. In addition, the Identity Provider must allow leading and trailing spaces in role names.

Patches: OpenSearch versions 1.3.8 and 2.5.0 contain a fix for this issue.

For more information: If you have any questions or comments about this advisory, please contact AWS/Amazon Security via our issue reporting page (https://aws.amazon.com/security/vulnerability-reporting/) or directly via email to aws-security@amazon.com. Please do not create a public GitHub issue.

Other sources

OpenSearch could allow a remote authenticated attacker to bypass security restrictions, caused by a flaw in with whitespace in JWT roles. By sending a specially-crafted request, an attacker could exploit this vulnerability to bypass authentication and obtain access.

IBM

OpenSearch is an open source distributed and RESTful search engine. OpenSearch uses JWTs to store role claims obtained from the Identity Provider (IdP) when the authentication backend is SAML or OpenID Connect. There is an issue in how those claims are processed from the JWTs where the leading and trailing whitespace is trimmed, allowing users to potentially claim roles they are not assigned to if any role matches the whitespace-stripped version of the roles they are a member of. This issue is only present for authenticated users, and it requires either the existence of roles that match, not considering leading/trailing whitespace, or the ability for users to create said matching roles. In addition, the Identity Provider must allow leading and trailing spaces in role names. OpenSearch 1.0.0-1.3.7 and 2.0.0-2.4.1 are affected. Users are advised to upgrade to OpenSearch 1.3.8 or 2.5.0. There are no known workarounds for this issue.

Affected Software

8 affected componentsFixes available
Amazon Opensearch>=1.0.0<1.3.8
Amazon Opensearch>=2.0.0<2.5.0
maven/org.opensearch.plugin:opensearch-security>=2.0.0<2.5.0
2.5.0
maven/org.opensearch.plugin:opensearch-security<1.3.8
1.3.8
IBM Cognos Dashboards on Cloud Pak for Data<=5.0.0
IBM Cognos Dashboards on Cloud Pak for Data<=4.8.0
Amazon OpenSearch Notifications>=1.0.0<1.3.8
Amazon OpenSearch Notifications>=2.0.0<2.5.0

Event History

Jan 24, 2023
CVE Published
via MITRE·08:36 PM
Data Sourced
via MITRE·08:36 PM
DescriptionSeverityWeakness
Advisory Published
via GitHub·08:47 PM

Parent advisories

This vulnerability appears in the following advisories.

Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is CVE-2023-23612?

CVE-2023-23612 is a vulnerability in OpenSearch where there is an issue in how role claims obtained from the Identity Provider (IdP) are processed.

2

What is OpenSearch?

OpenSearch is an open source distributed and RESTful search engine.

3

How does OpenSearch use JWTs?

OpenSearch uses JWTs to store role claims obtained from the Identity Provider (IdP) when the authentication backend is SAML or OpenID Connect.

4

What is the severity of CVE-2023-23612?

The severity of CVE-2023-23612 is classified as high, with a severity value of 8.8.

5

How can I fix CVE-2023-23612?

To fix CVE-2023-23612, update OpenSearch to version 2.5.0 or later.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203