blob: d773bcc9902fc9a8a076c7ecd94a739ff6398d14 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
// package api implements the Sigsum v0 API. See
//
// https://git.sigsum.org/sigsum/tree/doc/api.md
//
// for further details. No verification, retries, etc., is done here.
package api
import (
"git.sigsum.org/sigsum-lib-go/pkg/requests"
"git.sigsum.org/sigsum-lib-go/pkg/types"
)
type API interface {
GetToCosignTreeHead() (*types.SignedTreeHead, error)
GetCosignedTreeHead() (*types.CosignedTreeHead, error)
GetInclusionProof(treeSize uint64, leafHash *types.Hash) (*types.InclusionProof, error)
GetConsistencyProof(oldSize, newSize uint64) (*types.ConsistencyProof, error)
GetLeaves(startSize, endSize uint64) (*types.Leaves, error)
AddLeaf(*requests.Leaf) error
AddCosignature(*requests.Cosignature) error
}
|