SSL meta data

Paul Rubin http
Mon Sep 25 21:17:45 CEST 2006


"BerndWill" <bernd at ewill.de> writes:
> I would love to read programmatically some information out of the 
> certificates itself (who signed it and what is the validation period, i.e. 
> meta data).
> 
>  Can someone please help me out here !?

This is very cheesy but I sometimes I've just run the openssl command
line utility with popen and read the output:

  openssl x509 -text -noout -in certfile

will dump out the cert contents and you can parse it with regexps.

The right way to do it is to make the appropriate m2crypto (or
whatever) calls that parse the cert directly.



More information about the Python-list mailing list