diff options
author | Rob Austein <sra@hactrn.net> | 2016-04-26 20:07:50 +0000 |
---|---|---|
committer | Rob Austein <sra@hactrn.net> | 2016-04-26 20:07:50 +0000 |
commit | 89245def44ce5d2f7fbf665155b42794484c507d (patch) | |
tree | 862fb232cf7badd11b3bcd75a11d52c4c8e40690 /rp/utils/print_rpki_manifest | |
parent | 2e0f5147b3099b6b584ec302be7f0818aad969f0 (diff) |
Convert RP utilities to use common config/argparse/logging setup.
svn path=/branches/tk705/; revision=6392
Diffstat (limited to 'rp/utils/print_rpki_manifest')
-rwxr-xr-x | rp/utils/print_rpki_manifest | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/rp/utils/print_rpki_manifest b/rp/utils/print_rpki_manifest index 83e5c16e..74a3fbd4 100755 --- a/rp/utils/print_rpki_manifest +++ b/rp/utils/print_rpki_manifest @@ -21,14 +21,14 @@ Pretty-print the content of a manifest. Does NOT attempt to verify the signature. """ -import argparse +import rpki.config import rpki.POW import rpki.oids -parser = argparse.ArgumentParser(description = __doc__) -parser.add_argument("-c", "--cms", action = "store_true", help = "print text representation of entire CMS blob") -parser.add_argument("manifests", nargs = "+", type = rpki.POW.Manifest.derReadFile, help = "manifest(s) to print") -args = parser.parse_args() +cfg = rpki.config.argparser(doc = __doc__) +cfg.argparser.add_argument("--cms", action = "store_true", help = "print text representation of entire CMS blob") +cfg.argparser.add_argument("manifests", nargs = "+", type = rpki.POW.Manifest.derReadFile, help = "manifest(s) to print") +args = cfg.argparser.parse_args() for mft in args.manifests: mft.extractWithoutVerifying() |