This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #/usr/bin/python | |
| # usage | |
| # python not_after.py /path/to/cert | |
| #!/bin/python | |
| import sys | |
| from rhsm import _certificate | |
| cert = _certificate.load(sys.argv[1]) | |
| print "get_not_before():" | |
| print cert.get_not_before() | |
| print "get_not_after():" | |
| print cert.get_not_after() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
[root@abed ~]# ./not_after.py test.crt
get_not_before():
Feb 8 16:57:38 2016 GMT
get_not_after():
Bad time value