ClickHouse Cloud: Ditch Passwords for JWT Auth
Alps Wang
Oct 8, 2026 · 1 views
Ephemeral Users, Eternal Security
The introduction of JWT authentication in ClickHouse Cloud marks a substantial leap forward in enhancing security and simplifying credential management for cloud-based database deployments. By shifting from long-lived, static database credentials to short-lived, dynamically issued JWT tokens, ClickHouse Cloud directly addresses the perennial challenges of credential sprawl, rotation, and revocation. The integration with existing OpenID Connect providers like Okta and Microsoft Entra is particularly noteworthy, allowing organizations to leverage their established identity management infrastructure. This move not only reduces the operational burden on security and platform teams but also significantly shrinks the attack surface by minimizing the window of opportunity for compromised credentials.
The concept of ephemeral users, generated in-memory based on validated JWTs and automatically cleaned up upon token expiration, is a technically elegant solution. This approach eliminates the need for manual user provisioning and deprovisioning, a common source of errors and security gaps in traditional database management. The ability to map JWT claims (like clickhouse:roles or custom group claims) directly to database roles and grants provides granular control over access. Furthermore, the persistent association of settings profiles, quotas, and row policies with a stable user UUID, rather than the ephemeral username, ensures that critical access controls remain effective even as user sessions cycle. This is a sophisticated design that anticipates the practical needs of managing access in a dynamic cloud environment.
While the implementation is robust, potential limitations to consider include the reliance on the identity provider's availability and security. Any compromise or outage of the OIDC provider would directly impact ClickHouse access. Additionally, the initial setup requires careful configuration of the JWKS URI and claim mapping to ensure seamless integration. For organizations without an existing OIDC provider or with highly specialized authentication requirements, adopting this feature might necessitate an initial investment in setting up such infrastructure. However, for the vast majority of enterprises already utilizing OIDC, this feature represents a significant simplification and security enhancement. The support for RSA and EC keys across different versions also indicates a forward-thinking approach to cryptographic standards.
Key Points
- ClickHouse Cloud now supports JWT authentication, replacing traditional database passwords with short-lived tokens.
- Integrates with existing OpenID Connect (OIDC) providers like Okta and Microsoft Entra.
- Introduces ephemeral users that are created in-memory based on validated JWTs and automatically removed after token expiration.
- Simplifies credential management, reduces attack surface, and alleviates operational burden on security and platform teams.
- Access controls (settings profiles, quotas, row policies) are associated with a stable user UUID, ensuring persistence across token expirations.
- Supports RSA and EC keys for token signing, with broader support in later versions.

📖 Source: Introducing JWT authentication in ClickHouse Cloud
Related Articles
Comments (0)
No comments yet. Be the first to comment!
