aboutsummaryrefslogtreecommitdiff
path: root/siglog-witness.py
diff options
context:
space:
mode:
authorLinus Nordberg <linus@nordberg.se>2021-09-14 14:33:13 +0200
committerLinus Nordberg <linus@nordberg.se>2021-09-14 14:34:23 +0200
commit73aa0ea861ea86def159db81b024b13b423afbca (patch)
treed1c81ac1cec51d9d03ab5361f2676551e13a0ba5 /siglog-witness.py
parent771a90a429654916e03838e407d78a5109476933 (diff)
signed tree head wire format doesn't include `key_hash` anymore
Diffstat (limited to 'siglog-witness.py')
-rwxr-xr-xsiglog-witness.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/siglog-witness.py b/siglog-witness.py
index 5a91be2..06e9330 100755
--- a/siglog-witness.py
+++ b/siglog-witness.py
@@ -111,12 +111,11 @@ def parse_keyval(text):
class TreeHead:
def __init__(self, sth_data):
self._text = parse_keyval(sth_data)
- assert(len(self._text) == 5)
+ assert(len(self._text) == 4)
assert('timestamp' in self._text)
assert('tree_size' in self._text)
assert('root_hash' in self._text)
assert('signature' in self._text)
- assert('key_hash' in self._text)
@property
def timestamp(self):
@@ -135,7 +134,6 @@ class TreeHead:
text += 'tree_size={}\n'.format(self._text['tree_size'])
text += 'root_hash={}\n'.format(self._text['root_hash'])
text += 'signature={}\n'.format(self._text['signature'])
- text += 'key_hash={}\n'.format(self._text['key_hash'])
return text.encode('ascii')
def serialise(self):