entities

package
v0.1.7 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Signing    = "signing"
	Encryption = "encryption"
)
View Source
const (
	WalletStoreType = "wallet"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Attributes

type Attributes struct {
	// Operations supported by a stored item (e.g. sign, encrypt...)
	Operations []CryptoOperation

	// Disabled whether item is disabled
	Disabled bool

	// TTL
	TTL time.Duration

	// Recovery policy about a key after being deleted before being destroyed
	Recovery *Recovery

	// Tags attached to a stored item
	Tags map[string]string

	// Auth data
	Auth map[string]interface{}
}

Attributes are user set configuration and information attached to stored item

type CryptoOperation

type CryptoOperation string

CryptoOperation type of crypto operation

type Key

type Key struct {
	ID        string
	PublicKey []byte
	Algo      *entities.Algorithm
	Metadata  *Metadata
	Tags      map[string]string
}

Key public part of a key

func (*Key) IsETHAccount

func (k *Key) IsETHAccount() bool

type Metadata

type Metadata struct {
	Version   string
	Disabled  bool
	ExpireAt  time.Time
	CreatedAt time.Time
	UpdatedAt time.Time
	DeletedAt time.Time
}

type Recovery

type Recovery struct {
	// Policy for recovery
	Policy RecoveryPolicy

	// Period for recovery
	Period time.Time
}

type RecoveryPolicy

type RecoveryPolicy string

RecoveryPolicy policies for recovering a deleted item

type Store

type Store struct {
	Name           string
	AllowedTenants []string
	Store          interface{}
	StoreType      string
}

type Wallet

type Wallet struct {
	Namespaces          string
	Pubkey              string
	PublicKey           []byte
	CompressedPublicKey []byte
	Metadata            *Metadata
	Tags                map[string]string
	Extra               map[string]interface{}
}

Jump to

Keyboard shortcuts

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