Documentation ¶
Overview ¶
Package attestation provides APIs for wallets to receive attestation credential.
Index ¶
- func GetAttestationPayloadHash(attestationPayloadJSON string) (string, error)
- type Client
- type CreateClientArgs
- func (a *CreateClientArgs) AddHeader(header *api.Header) *CreateClientArgs
- func (a *CreateClientArgs) DisableHTTPClientTLSVerify() *CreateClientArgs
- func (a *CreateClientArgs) DisableOpenTelemetry() *CreateClientArgs
- func (a *CreateClientArgs) SetDocumentLoader(documentLoader api.LDDocumentLoader) *CreateClientArgs
- func (a *CreateClientArgs) SetHTTPTimeoutNanoseconds(timeout int64) *CreateClientArgs
- func (a *CreateClientArgs) SetMetricsLogger(metricsLogger api.MetricsLogger) *CreateClientArgs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a client for the attestation API.
func NewClient ¶
func NewClient( args *CreateClientArgs, ) (*Client, error)
NewClient creates a new attestation client.
func (*Client) GetAttestationVC ¶
func (c *Client) GetAttestationVC( vm *api.VerificationMethod, attestationPayloadJSON string, ) (*verifiable.Credential, error)
GetAttestationVC requests an attestation VC from the attestation service.
type CreateClientArgs ¶
type CreateClientArgs struct {
// contains filtered or unexported fields
}
CreateClientArgs holds the arguments for creating a new client.
func NewCreateClientArgs ¶
func NewCreateClientArgs(attestationURL string, crypto api.Crypto) *CreateClientArgs
NewCreateClientArgs creates a new CreateClientArgs object.
func (*CreateClientArgs) AddHeader ¶
func (a *CreateClientArgs) AddHeader(header *api.Header) *CreateClientArgs
AddHeader adds the given HTTP header to all REST calls made to the issuer during the OpenID4CI flow.
func (*CreateClientArgs) DisableHTTPClientTLSVerify ¶
func (a *CreateClientArgs) DisableHTTPClientTLSVerify() *CreateClientArgs
DisableHTTPClientTLSVerify disables tls verification, should be used only for test purposes.
func (*CreateClientArgs) DisableOpenTelemetry ¶
func (a *CreateClientArgs) DisableOpenTelemetry() *CreateClientArgs
DisableOpenTelemetry disables OpenTelemetry.
func (*CreateClientArgs) SetDocumentLoader ¶
func (a *CreateClientArgs) SetDocumentLoader(documentLoader api.LDDocumentLoader) *CreateClientArgs
SetDocumentLoader sets the document loader to use when parsing VCs received from the issuer. If no document loader is explicitly set, then a network-based loader will be used.
func (*CreateClientArgs) SetHTTPTimeoutNanoseconds ¶
func (a *CreateClientArgs) SetHTTPTimeoutNanoseconds(timeout int64) *CreateClientArgs
SetHTTPTimeoutNanoseconds sets the timeout (in nanoseconds) for HTTP calls. Passing in 0 will disable timeouts.
func (*CreateClientArgs) SetMetricsLogger ¶
func (a *CreateClientArgs) SetMetricsLogger(metricsLogger api.MetricsLogger) *CreateClientArgs
SetMetricsLogger sets a metrics logger to use.