profile

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2023 License: Apache-2.0 Imports: 10 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CredentialChecks

type CredentialChecks struct {
	Proof            bool                   `json:"proof,omitempty"`
	Format           []vcsverifiable.Format `json:"format,omitempty"`
	Status           bool                   `json:"status,omitempty"`
	CredentialExpiry bool                   `json:"credentialExpiry,omitempty"`
	Strict           bool                   `json:"strict,omitempty"`
	LinkedDomain     bool                   `json:"linkedDomain,omitempty"`
}

CredentialChecks are checks to be performed during credential verification.

type CredentialMetaData

type CredentialMetaData struct {
	CredentialsSupported []map[string]interface{} `json:"credentials_supported"`
}

type CredentialTemplate

type CredentialTemplate struct {
	Contexts                            []string                 `json:"contexts"`
	ID                                  string                   `json:"id"`
	Type                                string                   `json:"type"`
	CredentialSubject                   json.RawMessage          `json:"credentialSubject"`
	CredentialDefaultExpirationDuration *time.Duration           `json:"credentialDefaultExpirationDuration"`
	Checks                              CredentialTemplateChecks `json:"checks"`
}

type CredentialTemplateChecks

type CredentialTemplateChecks struct {
	Strict bool `json:"strict,omitempty"`
}

type ID

type ID = string // ID of the Profile.

type Issuer

type Issuer struct {
	ID                  ID                    `json:"id"`
	Version             Version               `json:"version"`
	GroupID             ID                    `json:"groupID"`
	Name                string                `json:"name,omitempty"`
	URL                 string                `json:"url,omitempty"`
	Active              bool                  `json:"active"`
	OIDCConfig          *OIDCConfig           `json:"oidcConfig"`
	OrganizationID      string                `json:"organizationID,omitempty"`
	VCConfig            *VCConfig             `json:"vcConfig"`
	KMSConfig           *vcskms.Config        `json:"kmsConfig"`
	SigningDID          *SigningDID           `json:"signingDID"`
	CredentialTemplates []*CredentialTemplate `json:"credentialTemplates,omitempty"`
	WebHook             string                `json:"webHook,omitempty"`
	CredentialMetaData  *CredentialMetaData   `json:"credentialMetadata"`
}

Issuer profile.

type Method

type Method string // DID method of the Profile.
const (
	WebDIDMethod Method = "web"
	KeyDIDMethod Method = key.DIDMethod
	OrbDIDMethod Method = orb.DIDMethod
)

type OIDC4VPConfig

type OIDC4VPConfig struct {
	ROSigningAlgorithm vcsverifiable.SignatureType `json:"roSigningAlgorithm,omitempty"`
	DIDMethod          Method                      `json:"didMethod,omitempty"`
	KeyType            kms.KeyType                 `json:"keyType,omitempty"`
}

OIDC4VPConfig store config for verifier did that used to sign request object in oidc4vp process.

type OIDCConfig added in v1.1.0

type OIDCConfig struct {
	IssuerWellKnownURL                         string        `json:"issuer_well_known"`
	ClientID                                   string        `json:"client_id"`
	ClientSecretHandle                         string        `json:"client_secret_handle"`
	ScopesSupported                            []string      `json:"scopes_supported"`
	GrantTypesSupported                        []string      `json:"grant_types_supported"`
	ResponseTypesSupported                     []string      `json:"response_types_supported"`
	TokenEndpointAuthMethodsSupported          []string      `json:"token_endpoint_auth_methods_supported"`
	EnableDynamicClientRegistration            bool          `json:"enable_dynamic_client_registration"`
	InitialAccessTokenLifespan                 time.Duration `json:"initial_access_token_lifespan"`
	PreAuthorizedGrantAnonymousAccessSupported bool          `json:"pre-authorized_grant_anonymous_access_supported"`
}

OIDCConfig represents issuer's OIDC configuration.

type PresentationChecks

type PresentationChecks struct {
	Proof     bool                   `json:"proof,omitempty"`
	VCSubject bool                   `json:"vcSubject,omitempty"`
	Format    []vcsverifiable.Format `json:"format,omitempty"`
}

PresentationChecks are checks to be performed during presentation verification.

type SigningDID

type SigningDID struct {
	DID            string `json:"did,omitempty"`
	Creator        string `json:"creator,omitempty"`
	KMSKeyID       string `json:"kmsKeyID,omitempty"`
	UpdateKeyURL   string `json:"updateKeyURL,omitempty"`
	RecoveryKeyURL string `json:"recoveryKeyURL,omitempty"`
}

SigningDID contains information about profile signing did.

type StatusConfig

type StatusConfig struct {
	Type    vc.StatusType `json:"type"`
	Disable bool          `json:"disable"`
}

StatusConfig represents the VC status configuration.

type VCConfig

type VCConfig struct {
	Format                  vcsverifiable.Format               `json:"format,omitempty"`
	SigningAlgorithm        vcsverifiable.SignatureType        `json:"signingAlgorithm,omitempty"`
	KeyType                 kms.KeyType                        `json:"keyType,omitempty"`
	DIDMethod               Method                             `json:"didMethod,omitempty"`
	SignatureRepresentation verifiable.SignatureRepresentation `json:"signatureRepresentation,omitempty"`
	Status                  StatusConfig                       `json:"status,omitempty"`
	Context                 []string                           `json:"context,omitempty"`
	SDJWT                   vc.SDJWT                           `json:"sdjwt,omitempty"`
}

VCConfig describes how to sign verifiable credentials.

type VerificationChecks

type VerificationChecks struct {
	Credential   CredentialChecks    `json:"credential,omitempty"`
	Presentation *PresentationChecks `json:"presentation,omitempty"`
}

VerificationChecks are checks to be performed for verifying credentials and presentations.

type Verifier

type Verifier struct {
	ID                      ID                                 `json:"id,omitempty"`
	Version                 Version                            `json:"version,omitempty"`
	Name                    string                             `json:"name,omitempty"`
	URL                     string                             `json:"url,omitempty"`
	Active                  bool                               `json:"active,omitempty"`
	OrganizationID          string                             `json:"organizationID,omitempty"`
	Checks                  *VerificationChecks                `json:"checks,omitempty"`
	OIDCConfig              *OIDC4VPConfig                     `json:"oidcConfig,omitempty"`
	KMSConfig               *vcskms.Config                     `json:"kmsConfig,omitempty"`
	SigningDID              *SigningDID                        `json:"signingDID,omitempty"`
	PresentationDefinitions []*presexch.PresentationDefinition `json:"presentationDefinitions,omitempty"`
	WebHook                 string                             `json:"webHook,omitempty"`
}

Verifier profile.

type Version

type Version = string // Profile version.

Jump to

Keyboard shortcuts

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