Difference between revisions of "Postgres x509 tls certs"
Jump to navigation
Jump to search
(Created page with "https://dba.stackexchange.com/questions/36416/what-is-the-best-way-to-store-x509-certificate-in-postgresql-database ``` CREATE OR REPLACE FUNCTION issuer(x509table) returns t...") |
|||
| Line 12: | Line 12: | ||
SELECT x.issuer FROM x509table x; --works | SELECT x.issuer FROM x509table x; --works | ||
``` | ``` | ||
| + | |||
| + | |||
| + | Auth | ||
| + | - https://www.postgresql.org/docs/current/auth-cert.html | ||
Latest revision as of 19:26, 12 June 2022
CREATE OR REPLACE FUNCTION issuer(x509table) returns text
LANGUAGE SQL IMMUTABLE AS $$
select issuer_cn FROM extract_x509info($1.x509data);
$$;
This can then be found by
SELECT x.issuer FROM x509table x; --works
Auth - https://www.postgresql.org/docs/current/auth-cert.html