did

package
v0.30.5 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Doc

type Doc struct {
	Context        string               `json:"@context,omitempty"`
	ID             string               `json:"id,omitempty"`
	PublicKey      []PublicKey          `json:"publicKey,omitempty"`
	Service        []Service            `json:"service,omitempty"`
	Authentication []VerificationMethod `json:"authentication,omitempty"`
	Created        *time.Time           `json:"created,omitempty"`
	Updated        *time.Time           `json:"updated,omitempty"`
}

Doc DID Document definition

func NewDoc

func NewDoc(did *ssi.DID, ae service.Addr) *Doc

type PublicKey

type PublicKey struct {
	ID              string `json:"id,omitempty"`
	Type            string `json:"type,omitempty"`
	Controller      string `json:"controller,omitempty"`
	PublicKeyBase58 string `json:"publicKeyBase58,omitempty"`
}

PublicKey DID doc public key

type Service

type Service struct {
	ID              string                 `json:"id,omitempty"`
	Type            string                 `json:"type,omitempty"`
	Priority        uint                   `json:"priority,omitempty"`
	RecipientKeys   []string               `json:"recipientKeys,omitempty"`
	RoutingKeys     []string               `json:"routingKeys,omitempty"`
	ServiceEndpoint string                 `json:"serviceEndpoint"`
	Properties      map[string]interface{} `json:"properties,omitempty"`
}

Service DID doc service

type VerificationMethod

type VerificationMethod struct {
	Type      string `json:"type,omitempty"`
	PublicKey string `json:"publicKey,omitempty"`
}

VerificationMethod authentication verification method

Jump to

Keyboard shortcuts

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