config

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PubK_SM = `` /* 177-byte string literal not displayed */

	PubK_R1 = `` /* 1093-byte string literal not displayed */

	Pubk_K1 = `` /* 173-byte string literal not displayed */

	PubK_SM_test = `` /* 177-byte string literal not displayed */

	PubK_R1_test = `` /* 1093-byte string literal not displayed */

	Pubk_K1_test = `` /* 173-byte string literal not displayed */

)

Variables

This section is empty.

Functions

func GetGatewayPublicKey added in v1.2.0

func GetGatewayPublicKey(algorithmType enum.App_AlgorithmType) string

func SetTest added in v1.0.4

func SetTest()

Enable test net parameters set test gateway public key

Types

type AppInfo added in v1.2.0

type AppInfo struct {
	AppCode string
	AppType string

	CAType        enum.App_CaType
	AlgorithmType enum.App_AlgorithmType

	MspId     string
	ChannelId string
	Version   string
}

func (*AppInfo) TxHash added in v1.2.0

func (a *AppInfo) TxHash() key.HashProvider

type CertInfo added in v1.2.0

type CertInfo struct {
	//public key cert of DApp
	AppPublicCert string

	//Private key cert of user
	UserAppPrivateCert string
	// contains filtered or unexported fields
}

type Config

type Config struct {
	// contains filtered or unexported fields
}

func NewConfig

func NewConfig(api, userCode, appCode, prk, mspDir string) (*Config, error)

Create a profile information api: address of the node gateway userCode: user's code appCode: DApp code prk : private key of DApp cert

func NewConfigFormFile added in v1.1.2

func NewConfigFormFile(path string) (*Config, error)

NewConfigFormFile get config from file, if path is empty ,use the ./conf/config.json file in the root directory

func NewMockCitaConfig added in v1.0.4

func NewMockCitaConfig() (*Config, error)

func NewMockFabricConfig added in v1.0.4

func NewMockFabricConfig() (*Config, error)

func NewMockFiscoConfig added in v1.0.4

func NewMockFiscoConfig() (*Config, error)

func NewMockXuperchainConfig added in v1.0.4

func NewMockXuperchainConfig() (*Config, error)

func (*Config) GetAppCert

func (c *Config) GetAppCert() CertInfo

func (*Config) GetAppInfo

func (c *Config) GetAppInfo() AppInfo

func (*Config) GetKSPath

func (c *Config) GetKSPath() string

func (*Config) GetNodeApi

func (c *Config) GetNodeApi() string

func (*Config) GetReqHeader

func (c *Config) GetReqHeader() base.ReqHeader

func (*Config) GetUSPath

func (c *Config) GetUSPath() string

func (*Config) GetUserCode added in v1.2.0

func (c *Config) GetUserCode() string

func (*Config) Init

func (c *Config) Init() error

Jump to

Keyboard shortcuts

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