diff options
author | Magnus Ahltorp <map@kth.se> | 2015-03-03 15:33:39 +0100 |
---|---|---|
committer | Magnus Ahltorp <map@kth.se> | 2015-03-03 15:33:39 +0100 |
commit | ff18e0fdd57a6b485f427173fe7febee03345037 (patch) | |
tree | d3f223fcdeb889a09fd8bb4fd250bd00373daf69 /tools/merge.py | |
parent | 4e1bcab3f91f975a19710a4350bbee0e9af5168e (diff) |
merge.py: use external signing
Diffstat (limited to 'tools/merge.py')
-rwxr-xr-x | tools/merge.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tools/merge.py b/tools/merge.py index c9f99af..0996ec9 100755 --- a/tools/merge.py +++ b/tools/merge.py @@ -21,7 +21,7 @@ parser.add_argument("--baseurl", metavar="url", help="Base URL for CT server", r parser.add_argument("--frontend", action="append", metavar="url", help="Base URL for frontend server", required=True) parser.add_argument("--storage", action="append", metavar="url", help="Base URL for storage server", required=True) parser.add_argument("--mergedb", metavar="dir", help="Merge database directory", required=True) -parser.add_argument("--keyfile", metavar="keyfile", help="File containing log key", required=True) +parser.add_argument("--signing", metavar="url", help="Base URL for signing server", required=True) parser.add_argument("--own-keyname", metavar="keyname", help="The key name of the merge node", required=True) parser.add_argument("--own-keyfile", metavar="keyfile", help="The file containing the private key of the merge node", required=True) parser.add_argument("--nomerge", action='store_true', help="Don't actually do merge") @@ -215,10 +215,9 @@ tree = build_merkle_tree(logorder) tree_size = len(logorder) root_hash = tree[-1][0] timestamp = int(time.time() * 1000) -privatekey = get_eckey_from_file(args.keyfile) tree_head_signature = create_sth_signature(tree_size, timestamp, - root_hash, privatekey) + root_hash, args.signing, key=own_key) sth = {"tree_size": tree_size, "timestamp": timestamp, "sha256_root_hash": base64.b64encode(root_hash), |