how to retrieve SSL certificate informations?

Wolf, Dave dave.wolf@REDACTED
Thu Mar 12 13:42:36 CET 2020


HI Marc,

I’d like to again express our thanks for taking the time to do this!

Cheers,
Dave.

From: Marc Worrell <marc@REDACTED>
Sent: Thursday, March 12, 2020 6:52 AM
To: Wolf, Dave (SI SSP R&D ATL) <dave.wolf@REDACTED>
Cc: Benoit Chesneau <bchesneau@REDACTED>; Leonard B <leonard.boyce@REDACTED>; Roger Lipscombe <roger@REDACTED>; Erlang Questions <erlang-questions@REDACTED>
Subject: Re: how to retrieve SSL certificate informations?

I have isolated and slightly reworked the SSL routines.
There is now a Hex package here:

https://hex.pm/packages/zotonic_ssl<https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fhex.pm%2Fpackages%2Fzotonic_ssl&data=02%7C01%7Cdave.wolf%40siemens.com%7Ce1474a20bfef4f21758708d7c6739a1b%7C38ae3bcd95794fd4addab42e1495d55a%7C1%7C0%7C637196072118762098&sdata=GG7LkZaaWfjapn0NOOD1%2BggZL%2B43Usuoxnu0Zda3Ndk%3D&reserved=0>

Please add pull requests for any additional feature or cert decoding info!

Cheers, Marc



On 9 Mar 2020, at 18:44, Wolf, Dave <dave.wolf@REDACTED<mailto:dave.wolf@REDACTED>> wrote:

Hi Marc,

Thanks for doing this; we appreciate your efforts!

Cheers,
Dave.

From: Benoit Chesneau <bchesneau@REDACTED<mailto:bchesneau@REDACTED>>
Sent: Monday, March 9, 2020 12:36 PM
To: Marc Worrell <marc@REDACTED<mailto:marc@REDACTED>>
Cc: Leonard B <leonard.boyce@REDACTED<mailto:leonard.boyce@REDACTED>>; Roger Lipscombe <roger@REDACTED<mailto:roger@REDACTED>>; Wolf, Dave (SI SSP R&D ATL) <dave.wolf@REDACTED<mailto:dave.wolf@REDACTED>>; Erlang Questions <erlang-questions@REDACTED<mailto:erlang-questions@REDACTED>>
Subject: Re: how to retrieve SSL certificate informations?

pretty cool :) Thanks for it!

On Mon, Mar 9, 2020 at 5:35 PM Marc Worrell <marc@REDACTED<mailto:marc@REDACTED>> wrote:
As there is some interest in such a library I will start with splitting off code from the Zotonic code base into a separate application.

I can do that tomorrow.

Then we can start adding extra functionality afterwards.


Cheers, Marc




On 9 Mar 2020, at 17:32, Benoit Chesneau <bchesneau@REDACTED<mailto:bchesneau@REDACTED>> wrote:

I think a library that allows manipulation of certificate infos and their creation would make sense indeed.... I can see a lot of usage for it.

On Mon, Mar 9, 2020 at 1:25 PM Leonard B <leonard.boyce@REDACTED<mailto:leonard.boyce@REDACTED>> wrote:
Hi Benoit,

This may be helpful for pulling basic cert info

https://gist.github.com/leonardb/a4dc25651ba3682966bafe5c7d1f575c<https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgist.github.com%2Fleonardb%2Fa4dc25651ba3682966bafe5c7d1f575c&data=02%7C01%7Cdave.wolf%40siemens.com%7Ce1474a20bfef4f21758708d7c6739a1b%7C38ae3bcd95794fd4addab42e1495d55a%7C1%7C0%7C637196072118762098&sdata=cSHaqL1eoky0R0KJYwQlXSQC1Xj8%2FSWcjn0NXwJlvXU%3D&reserved=0>

Leonard

On Mon, Mar 9, 2020 at 8:16 AM Wolf, Dave <dave.wolf@REDACTED<mailto:dave.wolf@REDACTED>> wrote:
>
> Hi Marc,
>
>
>
> This is a very timely topic in a current project I’m working on at the moment.  We need to determine the expiration date of a certificate as well as generate a self-signed one, which I see this module does as well.  Could you please isolate it in a separate library so we can include it in our list of OSS components?
>
>
>
> Thanks!
>
> Dave
>
>
>
> From: erlang-questions <erlang-questions-bounces@REDACTED<mailto:erlang-questions-bounces@REDACTED>> On Behalf Of Marc Worrell
> Sent: Monday, March 9, 2020 3:58 AM
> To: Benoit Chesneau <bchesneau@REDACTED<mailto:bchesneau@REDACTED>>
> Cc: Erlang Questions <erlang-questions@REDACTED<mailto:erlang-questions@REDACTED>>
> Subject: Re: how to retrieve SSL certificate informations?
>
>
>
> Hi Benoît,
>
>
>
> If the below is what you are looking for, then I can also isolate it in a separate library app for inclusion in your projects.
>
>
>
> - Marc
>
>
>
> On 9 Mar 2020, at 07:25, Marc Worrell <marcw@REDACTED<mailto:marcw@REDACTED>> wrote:
>
>
>
> Hi Benoit,
>
>
>
> Maybe this helps:
>
>
>
> https://github.com/zotonic/zotonic/blob/master/apps/zotonic_core/src/support/z_ssl_certs.erl#L313<https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fzotonic%2Fzotonic%2Fblob%2Fmaster%2Fapps%2Fzotonic_core%2Fsrc%2Fsupport%2Fz_ssl_certs.erl%23L313&data=02%7C01%7Cdave.wolf%40siemens.com%7Ce1474a20bfef4f21758708d7c6739a1b%7C38ae3bcd95794fd4addab42e1495d55a%7C1%7C0%7C637196072118772095&sdata=6av%2BhYgM4YEPKcE%2BAAnWzRG4TwIORYUHA6RK2WLWHa0%3D&reserved=0>
>
>
>
> Cheers, Marc
>
> Sent from my iPhone
>
>
>
> On 9 Mar 2020, at 00:34, Benoit Chesneau <bchesneau@REDACTED<mailto:bchesneau@REDACTED>> wrote:
>
> 
>
> How can I get informations about an SSL certificate ? Specifically I am looking for a way to retrieve the issuer, subject, and the  serial number of the certificate.
>
>
>
> The record I get from decoding using public_key functions is hard to parse so any help is welcome. Maybe there is already an api/app somewhere for it?
>
>
>
> Benoît
>
>
>
>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20200312/f825746d/attachment.htm>


More information about the erlang-questions mailing list