aboutsummaryrefslogtreecommitdiff
path: root/client/get-proof-by-hash/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'client/get-proof-by-hash/main.go')
-rw-r--r--client/get-proof-by-hash/main.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/client/get-proof-by-hash/main.go b/client/get-proof-by-hash/main.go
index 897a8aa..04dd7dc 100644
--- a/client/get-proof-by-hash/main.go
+++ b/client/get-proof-by-hash/main.go
@@ -33,7 +33,9 @@ func main() {
if err := sth.UnmarshalB64(*signedTreeHead); err != nil {
glog.Fatalf("bad signed tree head: %v", err)
}
- if err := client.VerifySignedTreeHeadV1(&sth, cli.Log.Scheme, cli.Log.Key()); err != nil {
+ if k, err := cli.Log.Key(); err != nil {
+ glog.Fatalf("bad public key: %v", err)
+ } else if err := client.VerifySignedTreeHeadV1(&sth, cli.Log.Scheme, k); err != nil {
glog.Fatalf("bad signed tree head: %v", err)
}
glog.V(3).Info("verified sth")