Skip to content

Commit dc99fc2

Browse files
committed
jwtauthccl: turn off cluster settings visibility for jwt authorization
previously, the cluster settings for JWT authorization were exposed `WithPublic` and `WithReportable`. It was discussed later that this feature should be kept private until 25.4. To address this, this commit removes `WithPublic` and `WithReportable` from the following cluster settings: - server.jwt_authentication.authorization.enabled - server.jwt_authentication.group_claim - server.jwt_authentication.userinfo_group_key Informs: #104671 Epic: CRDB-48763 Release note (security update): The JWT Authorization settings which were merged in #147318 are no longer visible to users in 25.3. They will be re-introduced in 25.4.
1 parent e5d1c94 commit dc99fc2

File tree

3 files changed

+2
-12
lines changed

3 files changed

+2
-12
lines changed

docs/generated/settings/settings-for-tenants.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,16 +125,13 @@ server.hsts.enabled boolean false if true, HSTS headers will be sent along with
125125
server.http.base_path string / path to redirect the user to upon succcessful login application
126126
server.identity_map.configuration string system-identity to database-username mappings application
127127
server.jwt_authentication.audience string sets accepted audience values for JWT logins over the SQL interface application
128-
server.jwt_authentication.authorization.enabled boolean false enables role synchronisation based on group claims in JWTs application
129128
server.jwt_authentication.claim string sets the JWT claim that is parsed to get the username application
130129
server.jwt_authentication.client.timeout duration 15s sets the client timeout for external calls made during JWT authentication (e.g. fetching JWKS, etc.) application
131130
server.jwt_authentication.enabled boolean false enables or disables JWT login for the SQL interface application
132-
server.jwt_authentication.group_claim string groups sets the name of the JWT claim that contains groups used for role mapping application
133131
server.jwt_authentication.issuers.configuration (alias: server.jwt_authentication.issuers) string sets accepted issuer values for JWT logins over the SQL interface which can be a single issuer URL string or a JSON string containing an array of issuer URLs or a JSON object containing map of issuer URLS to JWKS URIs application
134132
server.jwt_authentication.issuers.custom_ca string sets the PEM encoded custom root CA for verifying certificates while fetching JWKS application
135133
server.jwt_authentication.jwks string "{""keys"":[]}" sets the public key set for JWT logins over the SQL interface (JWKS format) application
136134
server.jwt_authentication.jwks_auto_fetch.enabled boolean false enables or disables automatic fetching of JWKS from the issuer's well-known endpoint or JWKS URI set in JWTAuthIssuersConfig. If this is enabled, the server.jwt_authentication.jwks will be ignored. application
137-
server.jwt_authentication.userinfo_group_key string groups sets the field name to look for in userinfo JSON that lists groups when groups claim is absent from JWT application
138135
server.ldap_authentication.client.tls_certificate string sets the client certificate PEM for establishing mTLS connection with LDAP server application
139136
server.ldap_authentication.client.tls_key string sets the client key PEM for establishing mTLS connection with LDAP server application
140137
server.ldap_authentication.domain.custom_ca string sets the PEM encoded custom root CA for verifying domain certificates when establishing connection with LDAP server application

docs/generated/settings/settings.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -157,16 +157,13 @@
157157
<tr><td><div id="setting-server-http-base-path" class="anchored"><code>server.http.base_path</code></div></td><td>string</td><td><code>/</code></td><td>path to redirect the user to upon succcessful login</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
158158
<tr><td><div id="setting-server-identity-map-configuration" class="anchored"><code>server.identity_map.configuration</code></div></td><td>string</td><td><code></code></td><td>system-identity to database-username mappings</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
159159
<tr><td><div id="setting-server-jwt-authentication-audience" class="anchored"><code>server.jwt_authentication.audience</code></div></td><td>string</td><td><code></code></td><td>sets accepted audience values for JWT logins over the SQL interface</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
160-
<tr><td><div id="setting-server-jwt-authentication-authorization-enabled" class="anchored"><code>server.jwt_authentication.authorization.enabled</code></div></td><td>boolean</td><td><code>false</code></td><td>enables role synchronisation based on group claims in JWTs</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
161160
<tr><td><div id="setting-server-jwt-authentication-claim" class="anchored"><code>server.jwt_authentication.claim</code></div></td><td>string</td><td><code></code></td><td>sets the JWT claim that is parsed to get the username</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
162161
<tr><td><div id="setting-server-jwt-authentication-client-timeout" class="anchored"><code>server.jwt_authentication.client.timeout</code></div></td><td>duration</td><td><code>15s</code></td><td>sets the client timeout for external calls made during JWT authentication (e.g. fetching JWKS, etc.)</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
163162
<tr><td><div id="setting-server-jwt-authentication-enabled" class="anchored"><code>server.jwt_authentication.enabled</code></div></td><td>boolean</td><td><code>false</code></td><td>enables or disables JWT login for the SQL interface</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
164-
<tr><td><div id="setting-server-jwt-authentication-group-claim" class="anchored"><code>server.jwt_authentication.group_claim</code></div></td><td>string</td><td><code>groups</code></td><td>sets the name of the JWT claim that contains groups used for role mapping</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
165163
<tr><td><div id="setting-server-jwt-authentication-issuers" class="anchored"><code>server.jwt_authentication.issuers.configuration<br />(alias: server.jwt_authentication.issuers)</code></div></td><td>string</td><td><code></code></td><td>sets accepted issuer values for JWT logins over the SQL interface which can be a single issuer URL string or a JSON string containing an array of issuer URLs or a JSON object containing map of issuer URLS to JWKS URIs</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
166164
<tr><td><div id="setting-server-jwt-authentication-issuers-custom-ca" class="anchored"><code>server.jwt_authentication.issuers.custom_ca</code></div></td><td>string</td><td><code></code></td><td>sets the PEM encoded custom root CA for verifying certificates while fetching JWKS</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
167165
<tr><td><div id="setting-server-jwt-authentication-jwks" class="anchored"><code>server.jwt_authentication.jwks</code></div></td><td>string</td><td><code>{"keys":[]}</code></td><td>sets the public key set for JWT logins over the SQL interface (JWKS format)</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
168166
<tr><td><div id="setting-server-jwt-authentication-jwks-auto-fetch-enabled" class="anchored"><code>server.jwt_authentication.jwks_auto_fetch.enabled</code></div></td><td>boolean</td><td><code>false</code></td><td>enables or disables automatic fetching of JWKS from the issuer&#39;s well-known endpoint or JWKS URI set in JWTAuthIssuersConfig. If this is enabled, the server.jwt_authentication.jwks will be ignored.</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
169-
<tr><td><div id="setting-server-jwt-authentication-userinfo-group-key" class="anchored"><code>server.jwt_authentication.userinfo_group_key</code></div></td><td>string</td><td><code>groups</code></td><td>sets the field name to look for in userinfo JSON that lists groups when groups claim is absent from JWT</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
170167
<tr><td><div id="setting-server-ldap-authentication-client-tls-certificate" class="anchored"><code>server.ldap_authentication.client.tls_certificate</code></div></td><td>string</td><td><code></code></td><td>sets the client certificate PEM for establishing mTLS connection with LDAP server</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
171168
<tr><td><div id="setting-server-ldap-authentication-client-tls-key" class="anchored"><code>server.ldap_authentication.client.tls_key</code></div></td><td>string</td><td><code></code></td><td>sets the client key PEM for establishing mTLS connection with LDAP server</td><td>Serverless/Dedicated/Self-Hosted</td></tr>
172169
<tr><td><div id="setting-server-ldap-authentication-domain-custom-ca" class="anchored"><code>server.ldap_authentication.domain.custom_ca</code></div></td><td>string</td><td><code></code></td><td>sets the PEM encoded custom root CA for verifying domain certificates when establishing connection with LDAP server</td><td>Serverless/Dedicated/Self-Hosted</td></tr>

pkg/ccl/jwtauthccl/settings.go

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,7 @@ var JWTAuthZEnabled = settings.RegisterBoolSetting(
162162
JWTAuthZEnabledSettingName,
163163
"enables role synchronisation based on group claims in JWTs",
164164
false,
165-
settings.WithReportable(true),
166-
settings.WithPublic)
165+
)
167166

168167
// JWTAuthGroupClaim sets the name of the JWT claim that contains the groups.
169168
var JWTAuthGroupClaim = settings.RegisterStringSetting(
@@ -172,8 +171,7 @@ var JWTAuthGroupClaim = settings.RegisterStringSetting(
172171
"sets the name of the JWT claim that contains groups used for role mapping",
173172
"groups",
174173
settings.WithValidateString(validateJWTGroupKey),
175-
settings.WithReportable(true),
176-
settings.WithPublic)
174+
)
177175

178176
// JWTAuthUserinfoGroupKey sets the name of the field in the userinfo response which
179177
// contains the group membership info.
@@ -185,8 +183,6 @@ var JWTAuthUserinfoGroupKey = settings.RegisterStringSetting(
185183
"sets the field name to look for in userinfo JSON that lists groups when groups claim is absent from JWT",
186184
"groups",
187185
settings.WithValidateString(validateJWTGroupKey),
188-
settings.WithReportable(true),
189-
settings.WithPublic,
190186
)
191187

192188
// getJSONDecoder generates a new decoder from provided json string. This is

0 commit comments

Comments
 (0)