did

package
v0.0.0-...-7b7c10a Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2022 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Fragments

func Fragments(didURLs ...string) ([]string, error)

Fragments parses each url and returns the fragments in the same order.

func PublicDID

func PublicDID(config *Config) func(kms.KeyManager) (*did.DocResolution, error)

PublicDID creates a new public DID given a Config and a key manager.

func VerificationMethods

func VerificationMethods(d *did.Doc, relations ...did.VerificationRelationship) ([]*did.VerificationMethod, error)

VerificationMethods returns the first verification method encountered for all relations in the same given order. At least one relation must be provided.

Types

type Config

type Config struct {
	Method                 string
	VerificationMethodType string
	VDR                    vdr.Registry
	JWKKeyCreator          func(kms.KeyManager) (string, *jwk.JWK, error)
	CryptoKeyCreator       func(kms.KeyManager) (string, interface{}, error)
	DIDAnchorOrigin        string
}

Config configures PublicDID.

Jump to

Keyboard shortcuts

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