aboutsummaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
authorRasmus Dahlberg <rasmus.dahlberg@kau.se>2020-11-04 12:17:59 +0100
committerRasmus Dahlberg <rasmus.dahlberg@kau.se>2020-11-04 12:17:59 +0100
commit0e2d1423e8863279d187429ee4fb80b371816d42 (patch)
tree485e4cd22c88ddb3d15fb3954c702e8a3b42c8cc /server
parente7d80645f5f3795183ff6062a6529ea226d8ef47 (diff)
allowed configuration of max-range and max-chain
Diffstat (limited to 'server')
-rw-r--r--server/main.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/server/main.go b/server/main.go
index 3bc9dce..aea2239 100644
--- a/server/main.go
+++ b/server/main.go
@@ -21,6 +21,8 @@ var (
rpcDeadline = flag.Duration("rpc_deadline", time.Second*10, "deadline for backend RPC requests")
anchorPath = flag.String("anchor_path", "testdata/x509/root.pem", "path to a file containing PEM-encoded X.509 root certificates")
keyPath = flag.String("key_path", "testdata/log/private.key", "path to a PEM-encoded ed25519 signing key")
+ maxRange = flag.Int64("max_range", 2, "maximum number of entries that can be retrived in a single request")
+ maxChain = flag.Int64("max_chain", 3, "maximum number of certificates in a chain, including the trust anchor")
)
func main() {
@@ -38,7 +40,7 @@ func main() {
mux := http.NewServeMux()
http.Handle("/", mux)
- lp, err := stfe.NewLogParameters(*trillianID, *prefix, *anchorPath, *keyPath)
+ lp, err := stfe.NewLogParameters(*trillianID, *prefix, *anchorPath, *keyPath, *maxRange, *maxChain)
if err != nil {
glog.Fatalf("failed setting up log parameters: %v", err)
}