CVE-2024-23656: Dex 2.37.0 is discarding TLSconfig and always serves deprecated TLS 1.0/1.1 and insecure ciphers

Published Jan 25, 2024
·
Updated

Summary

Dex 2.37.0 is serving HTTPS with insecure TLS 1.0 and TLS 1.1.

Details While working on https://github.com/dexidp/dex/issues/2848 and implementing configurable TLS support, I noticed my changes did not have any effect in TLS config, so I started investigating.

https://github.com/dexidp/dex/blob/70d7a2c7c1bb2646b1a540e49616cbc39622fb83/cmd/dex/serve.go#L425 is seemingly setting TLS 1.2 as minimum version, but the whole tlsConfig is ignored after "TLS cert reloader" was introduced in https://github.com/dexidp/dex/pull/2964. Configured cipher suites are not respected either, as seen on the output.

PoC Build Dex, generate certs with gencert.sh, modify config.dev.yaml to run on https, using generated certs.

console issuer: http://127.0.0.1:5556/dex

storage: type: sqlite3 config: file: dex.db

web: https: 127.0.0.1:5556 tlsCert: examples/k8s/ssl/cert.pem tlsKey: examples/k8s/ssl/key.pem

<rest as default>

Run dex bin/dex serve config.dev.yaml.

Install sslyze, easy to use SSL connection analyzer:

console pip3 install sslyze sslyze 127.0.0.1:5556

In Dex 2.37.0, TLS 1.0 and TLS 1.1 are enabled in addition to expected TLS 1.2 and TLS 1.3. console TLS 1.0 Cipher Suites: Attempted to connect using 80 cipher suites.

The server accepted the following 6 cipher suites: TLSRSAWITHAES256CBCSHA 256 TLSRSAWITHAES128CBCSHA 128 TLSRSAWITH3DESEDECBCSHA 168 TLSECDHERSAWITHAES256CBCSHA 256 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES128CBCSHA 128 ECDH: prime256v1 (256 bits) TLSECDHERSAWITH3DESEDECBCSHA 168 ECDH: prime256v1 (256 bits)

The group of cipher suites supported by the server has the following properties: Forward Secrecy OK - Supported Legacy RC4 Algorithm OK - Not Supported

TLS 1.1 Cipher Suites: Attempted to connect using 80 cipher suites.

The server accepted the following 6 cipher suites: TLSRSAWITHAES256CBCSHA 256 TLSRSAWITHAES128CBCSHA 128 TLSRSAWITH3DESEDECBCSHA 168 TLSECDHERSAWITHAES256CBCSHA 256 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES128CBCSHA 128 ECDH: prime256v1 (256 bits) TLSECDHERSAWITH3DESEDECBCSHA 168 ECDH: prime256v1 (256 bits)

The group of cipher suites supported by the server has the following properties: Forward Secrecy OK - Supported Legacy RC4 Algorithm OK - Not Supported

TLS 1.2 Cipher Suites: Attempted to connect using 156 cipher suites.

The server accepted the following 11 cipher suites: TLSRSAWITHAES256GCMSHA384 256 TLSRSAWITHAES256CBCSHA 256 TLSRSAWITHAES128GCMSHA256 128 TLSRSAWITHAES128CBCSHA 128 TLSRSAWITH3DESEDECBCSHA 168 TLSECDHERSAWITHCHACHA20POLY1305SHA256 256 ECDH: X25519 (253 bits) TLSECDHERSAWITHAES256GCMSHA384 256 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES256CBCSHA 256 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES128GCMSHA256 128 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES128CBCSHA 128 ECDH: prime256v1 (256 bits) TLSECDHERSAWITH3DESEDECBCSHA 168 ECDH: prime256v1 (256 bits)

The group of cipher suites supported by the server has the following properties: Forward Secrecy OK - Supported Legacy RC4 Algorithm OK - Not Supported

TLS 1.3 Cipher Suites: Attempted to connect using 5 cipher suites.

The server accepted the following 3 cipher suites: TLSCHACHA20POLY1305SHA256 256 ECDH: X25519 (253 bits) TLSAES256GCMSHA384 256 ECDH: X25519 (253 bits) TLSAES128GCMSHA256 128 ECDH: X25519 (253 bits)

In Dex 2.36.0, TLS 1.0 and TLS 1.1 are disabled as expected. console TLS 1.0 Cipher Suites: Attempted to connect using 80 cipher suites; the server rejected all cipher suites.

TLS 1.1 Cipher Suites: Attempted to connect using 80 cipher suites; the server rejected all cipher suites.

TLS 1.2 Cipher Suites: Attempted to connect using 156 cipher suites.

The server accepted the following 5 cipher suites: TLSRSAWITHAES256GCMSHA384 256 TLSRSAWITHAES128GCMSHA256 128 TLSECDHERSAWITHCHACHA20POLY1305SHA256 256 ECDH: X25519 (253 bits) TLSECDHERSAWITHAES256GCMSHA384 256 ECDH: prime256v1 (256 bits) TLSECDHERSAWITHAES128GCMSHA256 128 ECDH: prime256v1 (256 bits)

The group of cipher suites supported by the server has the following properties: Forward Secrecy OK - Supported Legacy RC4 Algorithm OK - Not Supported

TLS 1.3 Cipher Suites: Attempted to connect using 5 cipher suites.

The server accepted the following 3 cipher suites: TLSCHACHA20POLY1305SHA256 256 ECDH: X25519 (253 bits) TLSAES256GCMSHA384 256 ECDH: X25519 (253 bits)

Impact TLS 1.0 and TLS 1.1 connections can be decrypted by the attacker, and hence decrypt the traffic to Dex.

Other sources

Dex is an identity service that uses OpenID Connect to drive authentication for other apps. Dex 2.37.0 serves HTTPS with insecure TLS 1.0 and TLS 1.1. cmd/dex/serve.go line 425 seemingly sets TLS 1.2 as minimum version, but the whole tlsConfig is ignored after TLS cert reloader was introduced in v2.37.0. Configured cipher suites are not respected either. This issue is fixed in Dex 2.38.0.

MITRE

Affected Software

3 affected componentsFixes available
linuxfoundation Dex=2.37.0
go/github.com/dexidp/dex<0.0.0-20240125115555-5bbdb4420254
0.0.0-20240125115555-5bbdb4420254
go/github.com/dexidp/dex=2.37.0
2.38.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade go/github.com/dexidp/dex to a version that resolves this vulnerability.

    Fixed in 0.0.0-20240125115555-5bbdb4420254
  2. Upgrade

    Upgrade go/github.com/dexidp/dex to a version that resolves this vulnerability.

    Fixed in 2.38.0
  3. Upgrade

    Upgrade dexidp/dex to a version that resolves this vulnerability.

    Fixed in 2.38.0

Event History

Jan 25, 2024
CVE Published
via MITRE·07:45 PM
Data Sourced
via MITRE·07:45 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·08:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Jan 26, 2024
Advisory Published
via GitHub·01:57 AM

Frequently Asked Questions

1

What is the severity of CVE-2024-23656?

CVE-2024-23656 has been classified as a moderate severity vulnerability due to the usage of outdated TLS protocols.

2

How do I fix CVE-2024-23656?

To fix CVE-2024-23656, upgrade your Dex version to 2.38.0 or later to ensure secure TLS configurations.

3

What versions of Dex are affected by CVE-2024-23656?

CVE-2024-23656 affects Dex version 2.37.0 specifically.

4

What is the issue in CVE-2024-23656?

The issue in CVE-2024-23656 is the serving of HTTPS with insecure TLS 1.0 and TLS 1.1 protocols.

5

Is upgrading Dex the only solution for CVE-2024-23656?

Yes, upgrading to Dex version 2.38.0 is the recommended solution to address CVE-2024-23656.

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