Documentation
¶
Index ¶
- Variables
- type Verifier
- func (v *Verifier) CreateUpdateEntryRequest(trusted *trillian.SignedLogRoot, getResp *tpb.GetEntryResponse, ...) (*tpb.UpdateEntryRequest, error)
- func (Verifier) VerifyCommitment(userID, appID string, in *tpb.GetEntryResponse) error
- func (v *Verifier) VerifyGetEntryResponse(ctx context.Context, userID, appID string, trusted *trillian.SignedLogRoot, ...) error
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Verifier ¶
type Verifier struct {
// contains filtered or unexported fields
}
Verifier is a client helper library for verifying request and responses.
func New ¶
func New(vrf vrf.PublicKey, tree *tv.Verifier, sig crypto.PublicKey, log client.LogVerifier) *Verifier
New creates a new instance of the client verifier.
func (*Verifier) CreateUpdateEntryRequest ¶
func (v *Verifier) CreateUpdateEntryRequest( trusted *trillian.SignedLogRoot, getResp *tpb.GetEntryResponse, vrf vrf.PublicKey, userID, appID string, profileData []byte, signers []signatures.Signer, authorizedKeys []*tpb.PublicKey) (*tpb.UpdateEntryRequest, error)
CreateUpdateEntryRequest creates UpdateEntryRequest given GetEntryResponse, user ID and a profile.
func (Verifier) VerifyCommitment ¶
func (Verifier) VerifyCommitment(userID, appID string, in *tpb.GetEntryResponse) error
VerifyCommitment verifies that the commitment in `in` is correct for userID.
func (*Verifier) VerifyGetEntryResponse ¶
func (v *Verifier) VerifyGetEntryResponse(ctx context.Context, userID, appID string, trusted *trillian.SignedLogRoot, in *tpb.GetEntryResponse) error
VerifyGetEntryResponse verifies GetEntryResponse:
- Verify commitment.
- Verify VRF.
- Verify tree proof.
- Verify signature.
- Verify consistency proof from log.Root().
- Verify inclusion proof.
Click to show internal directories.
Click to hide internal directories.