You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "lovromazgon (via GitHub)" <gi...@apache.org> on 2026/04/14 15:18:34 UTC

[PR] feat(catalog): add `WithOAuthTLSConfig` for separate OAuth server TLS [iceberg-go]

lovromazgon opened a new pull request, #895:
URL: https://github.com/apache/iceberg-go/pull/895

   The Iceberg REST spec allows configuring the OAuth2 server separately from the catalog via `oauth2-server-uri`. When the OAuth2 server is a different host, it may require different TLS settings (different CA, client certificates, etc.).
   
   Currently `setupOAuthManager` reuses the catalog's HTTP client for token requests, making it impossible to configure separate TLS trust without creating a custom AuthManager.
   
   This adds `WithOAuthTLSConfig(*tls.Config)` which creates a dedicated HTTP client for OAuth token requests. When not set, behavior is unchanged.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(catalog): add `WithOAuthTLSConfig` for separate OAuth server TLS [iceberg-go]

Posted by "laskoviymishka (via GitHub)" <gi...@apache.org>.
laskoviymishka commented on code in PR #895:
URL: https://github.com/apache/iceberg-go/pull/895#discussion_r3115675163


##########
catalog/rest/options.go:
##########
@@ -58,6 +58,19 @@ func WithTLSConfig(config *tls.Config) Option {
 	}
 }
 
+// WithOAuthTLSConfig sets a separate TLS configuration for the HTTP client
+// used to communicate with the OAuth2 server. This is useful when the OAuth2
+// server (oauth2-server-uri) is a different host than the catalog and requires
+// different TLS settings (e.g. a different CA or client certificate).
+//
+// If not set, the OAuth2 client reuses the catalog's HTTP client (and its TLS
+// configuration).
+func WithOAuthTLSConfig(config *tls.Config) Option {

Review Comment:
   I think this is sufficient, plus this is flexible enough for most of the cases.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(catalog): add `WithOAuthTLSConfig` for separate OAuth server TLS [iceberg-go]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade merged PR #895:
URL: https://github.com/apache/iceberg-go/pull/895


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(catalog): add `WithOAuthTLSConfig` for separate OAuth server TLS [iceberg-go]

Posted by "zeroshade (via GitHub)" <gi...@apache.org>.
zeroshade commented on code in PR #895:
URL: https://github.com/apache/iceberg-go/pull/895#discussion_r3082164238


##########
catalog/rest/options.go:
##########
@@ -58,6 +58,19 @@ func WithTLSConfig(config *tls.Config) Option {
 	}
 }
 
+// WithOAuthTLSConfig sets a separate TLS configuration for the HTTP client
+// used to communicate with the OAuth2 server. This is useful when the OAuth2
+// server (oauth2-server-uri) is a different host than the catalog and requires
+// different TLS settings (e.g. a different CA or client certificate).
+//
+// If not set, the OAuth2 client reuses the catalog's HTTP client (and its TLS
+// configuration).
+func WithOAuthTLSConfig(config *tls.Config) Option {

Review Comment:
   @laskoviymishka what do you think from an API point of view, would we actually want to present a full `WithOAuthTransport` / `WithOAuthHTTPClient`? Or do you think this is sufficient? I'm curious about your thoughts here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(catalog): add `WithOAuthTLSConfig` for separate OAuth server TLS [iceberg-go]

Posted by "lovromazgon (via GitHub)" <gi...@apache.org>.
lovromazgon commented on code in PR #895:
URL: https://github.com/apache/iceberg-go/pull/895#discussion_r3080549789


##########
catalog/rest/options.go:
##########
@@ -58,6 +58,19 @@ func WithTLSConfig(config *tls.Config) Option {
 	}
 }
 
+// WithOAuthTLSConfig sets a separate TLS configuration for the HTTP client
+// used to communicate with the OAuth2 server. This is useful when the OAuth2
+// server (oauth2-server-uri) is a different host than the catalog and requires
+// different TLS settings (e.g. a different CA or client certificate).
+//
+// If not set, the OAuth2 client reuses the catalog's HTTP client (and its TLS
+// configuration).
+func WithOAuthTLSConfig(config *tls.Config) Option {

Review Comment:
   Alternatively this could be generalized to `WithOAuthTransport` or even `WithOAuthHTTPClient`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org