credentialstatus

package module
v0.0.0-...-8d7de0a Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2026 License: Apache-2.0 Imports: 34 Imported by: 1 module, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	HTTPClient                     httpClient
	RequestTokens                  map[string]string
	VDR                            vdrapi.Registry
	CSLVCStore                     credentialstatus.CSLVCStore
	CSLIndexStore                  credentialstatus.CSLIndexStore
	CSLManager                     cslManager
	VCStatusStore                  vcStatusStore
	Crypto                         vcCrypto
	ProfileService                 profileService
	KMSRegistry                    kmsRegistry
	EventPublisher                 eventPublisher
	CredentialIssuanceHistoryStore credentialIssuanceHistoryStore
	EventTopic                     string
	DocumentLoader                 ld.DocumentLoader
	CMD                            *cobra.Command
	ExternalURL                    string
}

type IdentityHubRequest

type IdentityHubRequest struct {
	RequestID string    `json:"requestId"`
	Target    string    `json:"target"`
	Messages  []Message `json:"messages"`
}

type IdentityHubResponse

type IdentityHubResponse struct {
	RequestID string          `json:"requestId"`
	Status    *Status         `json:"status"`
	Replies   []MessageResult `json:"replies"`
}

func (IdentityHubResponse) GetVCBytes

func (i IdentityHubResponse) GetVCBytes(objectID string) ([]byte, error)

type Message

type Message struct {
	Descriptor map[string]interface{} `json:"descriptor"`
	Data       string                 `json:"data,omitempty"`
}

func (Message) GetObjectID

func (m Message) GetObjectID() (string, bool)

func (Message) IsMethod

func (m Message) IsMethod(method string) bool

type MessageResult

type MessageResult struct {
	MessageID string    `json:"messageId"`
	Status    Status    `json:"status"`
	Entries   []Message `json:"entries,omitempty"`
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func New

func New(config *Config) (*Service, error)

New returns new Credential Status service.

func (*Service) CreateStatusListEntry

func (s *Service) CreateStatusListEntry(
	ctx context.Context,
	profileID profileapi.ID,
	profileVersion profileapi.Version,
	credentialID string,
	statusPurpose string,
) (*credentialstatus.StatusListEntry, error)

CreateStatusListEntry creates credentialstatus.StatusListEntry for profileID.

func (*Service) GetStatusListVC

func (s *Service) GetStatusListVC(
	ctx context.Context, groupID profileapi.ID, listID string) (*credentialstatus.CSL, error)

GetStatusListVC returns StatusListVC (credentialstatus.CSL) from underlying cslVCStore. Used for handling public HTTP requests.

func (*Service) Resolve

func (s *Service) Resolve(ctx context.Context, statusListVCURI string) (*credentialstatus.CSL, error)

Resolve resolves statusListVCURI and returns StatusListVC (credentialstatus.CSL). Used for credential verification. statusListVCURI might be either HTTP URL or DID URL.

func (*Service) StoreIssuedCredentialMetadata

func (s *Service) StoreIssuedCredentialMetadata(
	ctx context.Context,
	profileID profileapi.ID,
	profileVersion profileapi.Version,
	metadata *credentialstatus.CredentialMetadata,
) error

StoreIssuedCredentialMetadata stores credentialstatus.CredentialMetadata for each issued credential.

func (*Service) UpdateVCStatus

func (s *Service) UpdateVCStatus(ctx context.Context, params credentialstatus.UpdateVCStatusParams) error

UpdateVCStatus fetches credential based on UpdateVCStatusParams.CredentialID and updates associated credentialstatus.CSL to UpdateVCStatusParams.DesiredStatus.

type Status

type Status struct {
	Code    int    `json:"code"`
	Message string `json:"message"`
}

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

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