New functions

Started by Воронин Дмитрийabout 11 years ago6 messageshackers
Jump to latest
#1Воронин Дмитрий
carriingfate92@yandex.ru

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Attachments:

ssl-extensions-1.patchtext/x-diff; name=ssl-extensions-1.patchDownload+273-2
#2Воронин Дмитрий
carriingfate92@yandex.ru
In reply to: Воронин Дмитрий (#1)
Re: New functions

Sorry, 3 functions.

08.03.2015, 22:16, "Dmitry Voronin" <carriingfate92@yandex.ru>:

Hello,

I make an a patch, which adds 4 functions to sslinfo extension module:
1) ssl_extension_names() --- get short names of X509v3 extensions from client certificate and it's values; 2) ssl_extension_value(text) --- get value of extension from certificate (argument --- short name of extension); 3) ssl_extension_is_critical(text) --- returns true, if extension is critical and false, if is not (argument --- short name of extension). You can view some information of certificate's extensions via those functions. What do you think about it?
--
Best regards, Dmitry Voronin

,

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

--О©╫
Best regards, Dmitry Voronin

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#3Alvaro Herrera
alvherre@2ndquadrant.com
In reply to: Воронин Дмитрий (#1)
Re: New functions

Dmitry Voronin wrote:

<div><pre>Hello,
</pre><pre>I make an a patch, which adds 4 functions to sslinfo extension module:<br />1) ssl_extension_names() --- get short names of X509v3 extensions from client certificate and it's values;
2) ssl_extension_value(text) --- get value of extension from certificate (argument --- short name of extension);
3) ssl_extension_is_critical(text) --- returns true, if extension is critical and false, if is not (argument --- short name of extension).

You can view some information of certificate's extensions via those functions.

Since you change default version from 1.0 to 1.1 you need to supply the
sslinfo--1.1.sql script. You also need to supply a sslinfo--1.0--1.1.sql
script which enables updates from version 1.0 to 1.1.

(The test for the upgrade is to initdb 9.4, and in some database install
the sslinfo extension; then pg_upgrade to a version with your patch. In
the database with the extension then try to upgrade it to 1.1.)

Please use C type bool not int when that's what the code means.

--
�lvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#4Воронин Дмитрий
carriingfate92@yandex.ru
In reply to: Alvaro Herrera (#3)
Re: New functions

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Attachments:

ssl-extensions-2.patchtext/x-diff; name=ssl-extensions-2.patchDownload+271-0
#5Andreas Karlsson
andreas.karlsson@percona.com
In reply to: Воронин Дмитрий (#1)
Re: New functions

On 03/08/2015 08:14 PM, Dmitry Voronin wrote:

What do you think about it?

Nice to see you back working on the patch.

For reviewers: the previous discussion and review of the patch can be
found at /messages/by-id/53A88911.6060300@proxel.se.

--
Andreas Karlsson

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

#6Michael Paquier
michael@paquier.xyz
In reply to: Andreas Karlsson (#5)
Re: New functions

On Tue, Mar 10, 2015 at 7:24 AM, Andreas Karlsson <andreas@proxel.se> wrote:

On 03/08/2015 08:14 PM, Dmitry Voronin wrote:

What do you think about it?

Nice to see you back working on the patch.

For reviewers: the previous discussion and review of the patch can be found
at /messages/by-id/53A88911.6060300@proxel.se.

Worth noticing as well, this has been added to CF 2015-06:
https://commitfest.postgresql.org/5/192/
(I am going to remove the duplicate entry 191..)
--
Michael

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers