You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
351 B
19 lines
351 B
#!/usr/bin/env python
|
|
|
|
from __future__ import print_function
|
|
|
|
import base64
|
|
import sys
|
|
|
|
pkFile = open(sys.argv[1], 'rb').readlines()
|
|
base64Key = ""
|
|
inCert = False
|
|
for line in pkFile:
|
|
if line.startswith(b"-"):
|
|
inCert = not inCert
|
|
continue
|
|
|
|
base64Key += line.strip()
|
|
|
|
print(base64.b16encode(base64.b64decode(base64Key)).lower())
|