From 0168f18229402b299a3fb3bb6fe3edb8e3ffa7fc Mon Sep 17 00:00:00 2001 From: Rasmus Dahlberg Date: Tue, 3 Nov 2020 20:01:08 +0100 Subject: added chain processing with intermediate certificates Basic test chains can be generated manually with openssl, see details in server/testdata/x509/README.md. --- client/add-entry/main.go | 4 ++-- client/get-consistency-proof/main.go | 2 +- client/get-proof-by-hash/main.go | 2 +- client/get-sth/main.go | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'client') diff --git a/client/add-entry/main.go b/client/add-entry/main.go index 11162e5..463b65c 100644 --- a/client/add-entry/main.go +++ b/client/add-entry/main.go @@ -15,8 +15,8 @@ import ( var ( operators = flag.String("operators", "../../server/descriptor/stfe.json", "path to json-encoded list of log operators") logId = flag.String("log_id", "B9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPM=", "base64-encoded log identifier") - chain = flag.String("chain", "../../server/testdata/chain/ee.pem", "path to pem-encoded certificate chain that the log accepts") - key = flag.String("key", "../../server/testdata/chain/ee.key", "path to ed25519 private key that corresponds to the chain's end-entity certificate") + chain = flag.String("chain", "../../server/testdata/x509/chain.pem", "path to pem-encoded certificate chain that the log accepts") + key = flag.String("key", "../../server/testdata/x509/end-entity.key", "path to ed25519 private key that corresponds to the chain's end-entity certificate") name = flag.String("name", "foobar-1.2.3", "package name") checksum = flag.String("checksum", "50e7967bce266a506f8f614bb5096beba580d205046b918f47d23b2ec626d75e", "base64-encoded package checksum") ) diff --git a/client/get-consistency-proof/main.go b/client/get-consistency-proof/main.go index 49c45f1..f5cb57a 100644 --- a/client/get-consistency-proof/main.go +++ b/client/get-consistency-proof/main.go @@ -15,7 +15,7 @@ import ( var ( operators = flag.String("operators", "../../server/descriptor/stfe.json", "path to json-encoded list of log operators") logId = flag.String("log_id", "B9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPM=", "base64-encoded log identifier") - chain = flag.String("chain", "../../server/testdata/chain/ee.pem", "path to pem-encoded certificate chain that the log accepts") + chain = flag.String("chain", "../../server/testdata/x509/end-entity.pem", "path to pem-encoded certificate chain that the log accepts") first = flag.String("first", "AAEgB9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPMAAAF1jnn7fwAAAAAAAAAxICCqLJn4QWYd0aRIRjDWGf4GWalDIb/iH60jSSX89WgvAAAAQF9XPFRdM56KaelHFFg1RqjTw1yFL085zHhdNkLeZh9BCXxVTByqrHEMngAkY69EX45aJMWh9NymmPau0qoigA8=", "first base64-encoded StItem of type StFormatSignedTreeHeadV1") second = flag.String("second", "AAEgB9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPMAAAF1jsZrygAAAAAAAABFIL7Zz0WEolql7o7G496Izl7Qy/l2Qd/Pwc87W8jFPoL6AAAAQHc7ttIDUKuMJR7uqCLb3qqAxiwEN5KLt/7IblT7f+QaKq4BqqI3cO6vT3eMSZMHZDd4EkgvkAwo1o7IsA4N8Qc=", "second base64-encoded StItem of type StFormatSignedTreeHeadV1") ) diff --git a/client/get-proof-by-hash/main.go b/client/get-proof-by-hash/main.go index 78a4621..842dbcd 100644 --- a/client/get-proof-by-hash/main.go +++ b/client/get-proof-by-hash/main.go @@ -16,7 +16,7 @@ import ( var ( operators = flag.String("operators", "../../server/descriptor/stfe.json", "path to json-encoded list of log operators") logId = flag.String("log_id", "B9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPM=", "base64-encoded log identifier") - chain = flag.String("chain", "../../server/testdata/chain/ee.pem", "path to pem-encoded certificate chain that the log accepts") + chain = flag.String("chain", "../../server/testdata/x509/end-entity.pem", "path to pem-encoded certificate chain that the log accepts") signedTreeHead = flag.String("sth", "AAEgB9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPMAAAF1jnn7fwAAAAAAAAAxICCqLJn4QWYd0aRIRjDWGf4GWalDIb/iH60jSSX89WgvAAAAQF9XPFRdM56KaelHFFg1RqjTw1yFL085zHhdNkLeZh9BCXxVTByqrHEMngAkY69EX45aJMWh9NymmPau0qoigA8=", "base64-encoded StItem of type StFormatSignedTreeHeadV1") entry = flag.String("entry", "AAUBOCAsYkIyzdIhdxKU37sxCsoACg32rItmtpbZDvBv3vtkow==", "base64-encoded StItem of type StFormatChecksumV1") ) diff --git a/client/get-sth/main.go b/client/get-sth/main.go index 6f0075b..8db64d5 100644 --- a/client/get-sth/main.go +++ b/client/get-sth/main.go @@ -14,7 +14,7 @@ import ( var ( operators = flag.String("operators", "../../server/descriptor/stfe.json", "path to json-encoded list of log operators") logId = flag.String("log_id", "B9oCJk4XIOMXba8dBM5yUj+NLtqTE6xHwbvR9dYkHPM=", "base64-encoded log identifier") - chain = flag.String("chain", "../../server/testdata/chain/ee.pem", "path to pem-encoded certificate chain that the log accepts") + chain = flag.String("chain", "../../server/testdata/x509/end-entity.pem", "path to pem-encoded certificate chain that the log accepts") ) func main() { -- cgit v1.2.3