aboutsummaryrefslogtreecommitdiff
path: root/scripts/manifests.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/manifests.py')
-rw-r--r--scripts/manifests.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/manifests.py b/scripts/manifests.py
index 079d7a3d..bab02a5b 100644
--- a/scripts/manifests.py
+++ b/scripts/manifests.py
@@ -7,6 +7,8 @@ show_signed_manifest_PEM = False
show_signed_manifest_asn1dump = True
show_content_2 = False
show_content_3 = False
+dump_signed_manifest_DER = True
+dump_manifest_content_DER = True
def dumpasn1(thing):
# Save to file rather than using popen4() because dumpasn1 uses
@@ -37,6 +39,16 @@ m.sign(keypair = rpki.x509.RSA(Auto_file = "biz-certs/Alice-EE.key"),
if show_signed_manifest_PEM:
print m.get_PEM()
+if dump_manifest_content_DER:
+ f = open("manifest-content.der", "w")
+ f.write(m.get_content().toString())
+ f.close()
+
+if dump_signed_manifest_DER:
+ f = open("signed-manifest.der", "w")
+ f.write(m.get_DER())
+ f.close()
+
if show_signed_manifest_asn1dump:
dumpasn1(m.get_DER())