identity

package
v2.0.5-beta Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewEnrollIdentity

func NewEnrollIdentity(privateKey interface{}) (api.Identity, error)

func NewMSPIdentity

func NewMSPIdentity(mspId string, certPath string, keyPath string) (api.Identity, error)

func NewMSPIdentityBytes

func NewMSPIdentityBytes(mspId string, certBytes []byte, keyBytes []byte) (api.Identity, error)

func NewMSPIdentityFromPath

func NewMSPIdentityFromPath(mspId string, mspPath string) (api.Identity, error)

func NewMSPIdentityRaw

func NewMSPIdentityRaw(mspId string, cert *x509.Certificate, privateKey interface{}) (api.Identity, error)

Types

type MSPIndentities

type MSPIndentities struct {
	// identity from 'signcerts'
	MSP api.Identity
	// identities from 'admincerts'
	Admins []api.Identity
	// indentities from 'users'
	Users []api.Identity
}

MSPIndentities - contains all parsed identities from msp folder Should be used instead of single `api.Identity` which contains ONLY msp identity

func NewMSPIndentitiesFromPath

func NewMSPIndentitiesFromPath(mspID string, mspPath string) (*MSPIndentities, error)

NewMSPIndentitiesFromPath - parse all certificates(msp,admins,users) from MSP folder. Came to replace legacy `util.LoadKeyPairFromMSP` method

Jump to

Keyboard shortcuts

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