Re: [PoC] Federated Authn/z with OAUTHBEARER - Mailing list pgsql-hackers

From Wolfgang Walther
Subject Re: [PoC] Federated Authn/z with OAUTHBEARER
Date
Msg-id bf7c3396-a9a2-4df7-aabd-6fed387e027b@technowledgy.de
Whole thread Raw
In response to Re: [PoC] Federated Authn/z with OAUTHBEARER  (Jacob Champion <jacob.champion@enterprisedb.com>)
Responses Re: [PoC] Federated Authn/z with OAUTHBEARER
Re: [PoC] Federated Authn/z with OAUTHBEARER
List pgsql-hackers
Jacob Champion:
The currently proposed patch would have you package and install a
separate .so module implementing OAuth, which the staticlib would load
once when needed. Similarly to how you still have to somehow
dynamically link your static app against Curl.

As a staticlib user, how do you feel about that?

When linking statically, I am producing entirely statically linked single binaries. Those contain libpq, all other dependencies, and would also contain curl.

The "entirely statically linked" thing is actually enforced by the build system (NixOS' pkgsStatic here), so dlopen() might just not be possible. Not exactly sure right now, whether it's stubbed out or just not available at all.

This means that shipping another .so file will not happen with this approach. Assuming OAuth will be picked up by some of the bigger providers, that would... make me feel quite bad about it, actually.

I'm not seeing the overall problem, yet. When I build with --enable-curl... ofc, I have a dependency on cURL. That's kind of the point. When I don't want that, then I just disable it. And that should also not be a problem for distributions - they could offer a libpq and a libpq_oauth package, where only one of them can be installed at the same time, I guess? *

Best,

Wolfgang

* Currently, the two build systems don't handle the "please build only libpq" scenario well. If that was supported better, building a second package with oauth support could be much easier.

pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: Feature freeze
Next
From: Bruce Momjian
Date:
Subject: Re: [PoC] Federated Authn/z with OAUTHBEARER