Support for OAuth2?
tonypiazza opened this issue · 3 comments
Curious whether you have considered adding support for OAuth2 authentication. We are in need of a provider like this but we need to authenticate our users via our IdP (Auth0).
@tonypiazza NReco.PrestoAdo implementation uses https://github.com/bamcis-io/PrestoClient library under the hood; I guess it doesn't support OAuth2 according to available connection config properties: https://github.com/bamcis-io/PrestoClient/blob/main/PrestoClient/PrestoClientSessionConfig.cs, however you may ask PrestoClient lib maintainers about that.
@VitaliyMF, I'm sorry I forgot to mention that we need a driver for use with Trino, which does support OAuth2.
The latest https://www.nuget.org/packages/PrestoClient/0.256.0-beta uses "X-Presto" headers, so it can connect to Trino only if it is configured for 'presto-compatible' HTTP headers (protocol.v1.alternate-header-name=Presto). Only difference is "X-Trino-" prefix instead of "X-Presto", so it's rather easy to make PrestoClient compatible with Trino -- actually, this could be a even a connection string option to switch between Presto/Trino headers prefix.
However, I don't know how to add support for OAuth2 - if you can do that, you can propose a PR to https://github.com/bamcis-io/PrestoClient