verifier

package
v0.0.2502 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 21, 2025 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Overview

Copyright 2022-2023 Contributors to the Veraison project. SPDX-License-Identifier: Apache-2.0

Copyright 2022-2024 Contributors to the Veraison project. SPDX-License-Identifier: Apache-2.0

Index

Constants

This section is empty.

Variables

View Source
var ErrInputParam = errors.New("invalid input parameter")

Functions

This section is empty.

Types

type IVerifier

type IVerifier interface {
	GetVTSState() (*proto.ServiceState, error)
	GetPublicKey() (*proto.PublicKey, error)
	IsSupportedMediaType(mt string) (bool, error)
	SupportedMediaTypes() ([]string, error)
	ProcessEvidence(tenantID string, nonce []byte, data []byte, mt string) ([]byte, error)
}

func New

func New(v *viper.Viper, vtsClient vtsclient.IVTSClient) IVerifier

type Verifier

type Verifier struct {
	VTSClient vtsclient.IVTSClient
}

func (*Verifier) GetPublicKey

func (o *Verifier) GetPublicKey() (*proto.PublicKey, error)

func (*Verifier) GetVTSState

func (o *Verifier) GetVTSState() (*proto.ServiceState, error)

func (*Verifier) IsSupportedMediaType

func (o *Verifier) IsSupportedMediaType(mt string) (bool, error)

func (*Verifier) ProcessEvidence

func (o *Verifier) ProcessEvidence(
	tenantID string,
	nonce []byte,
	data []byte,
	mt string,
) ([]byte, error)

func (*Verifier) SupportedMediaTypes

func (o *Verifier) SupportedMediaTypes() ([]string, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL