msppb

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2026 License: Apache-2.0 Imports: 6 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_api_msppb_msp_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type FabricMSPConfig

type FabricMSPConfig struct {

	// Name holds the identifier of the MSP; MSP identifier
	// is chosen by the application that governs this MSP.
	// For example, and assuming the default implementation of MSP,
	// that is X.509-based and considers a single Issuer,
	// this can refer to the Subject OU field or the Issuer OU field.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// List of root certificates trusted by this MSP
	// they are used upon certificate validation (see
	// comment for IntermediateCerts below)
	RootCerts [][]byte `protobuf:"bytes,2,rep,name=root_certs,json=rootCerts,proto3" json:"root_certs,omitempty"`
	// List of intermediate certificates trusted by this MSP;
	// they are used upon certificate validation as follows:
	// validation attempts to build a path from the certificate
	// to be validated (which is at one end of the path) and
	// one of the certs in the RootCerts field (which is at
	// the other end of the path). If the path is longer than
	// 2, certificates in the middle are searched within the
	// IntermediateCerts pool
	IntermediateCerts [][]byte `protobuf:"bytes,3,rep,name=intermediate_certs,json=intermediateCerts,proto3" json:"intermediate_certs,omitempty"`
	// Identity denoting the administrator of this MSP
	Admins [][]byte `protobuf:"bytes,4,rep,name=admins,proto3" json:"admins,omitempty"`
	// Identity revocation list
	RevocationList [][]byte `protobuf:"bytes,5,rep,name=revocation_list,json=revocationList,proto3" json:"revocation_list,omitempty"`
	// SigningIdentity holds information on the signing identity
	// this peer is to use, and which is to be imported by the
	// MSP defined before
	SigningIdentity *msp.SigningIdentityInfo `protobuf:"bytes,6,opt,name=signing_identity,json=signingIdentity,proto3" json:"signing_identity,omitempty"`
	// OrganizationalUnitIdentifiers holds one or more
	// fabric organizational unit identifiers that belong to
	// this MSP configuration
	OrganizationalUnitIdentifiers []*msp.FabricOUIdentifier `` /* 150-byte string literal not displayed */
	// FabricCryptoConfig contains the configuration parameters
	// for the cryptographic algorithms used by this MSP
	CryptoConfig *msp.FabricCryptoConfig `protobuf:"bytes,8,opt,name=crypto_config,json=cryptoConfig,proto3" json:"crypto_config,omitempty"`
	// List of TLS root certificates trusted by this MSP.
	// They are returned by GetTLSRootCerts.
	TlsRootCerts [][]byte `protobuf:"bytes,9,rep,name=tls_root_certs,json=tlsRootCerts,proto3" json:"tls_root_certs,omitempty"`
	// List of TLS intermediate certificates trusted by this MSP;
	// They are returned by GetTLSIntermediateCerts.
	TlsIntermediateCerts [][]byte `protobuf:"bytes,10,rep,name=tls_intermediate_certs,json=tlsIntermediateCerts,proto3" json:"tls_intermediate_certs,omitempty"`
	// fabric_node_ous contains the configuration to distinguish clients from peers from orderers
	// based on the OUs.
	FabricNodeOus *msp.FabricNodeOUs `protobuf:"bytes,11,opt,name=fabric_node_ous,json=fabricNodeOus,proto3" json:"fabric_node_ous,omitempty"`
	// List of known certificates of this MSP.
	KnownCerts [][]byte `protobuf:"bytes,12,rep,name=known_certs,json=knownCerts,proto3" json:"known_certs,omitempty"`
	// contains filtered or unexported fields
}

FabricMSPConfig collects all the configuration information for a Fabric MSP. Here we assume a default certificate validation policy, where any certificate signed by any of the listed rootCA certs would be considered as valid under this MSP. This MSP may or may not come with a signing identity. If it does, it can also issue signing identities. If it does not, it can only be used to validate and verify certificates.

func (*FabricMSPConfig) Descriptor deprecated

func (*FabricMSPConfig) Descriptor() ([]byte, []int)

Deprecated: Use FabricMSPConfig.ProtoReflect.Descriptor instead.

func (*FabricMSPConfig) GetAdmins

func (x *FabricMSPConfig) GetAdmins() [][]byte

func (*FabricMSPConfig) GetCryptoConfig

func (x *FabricMSPConfig) GetCryptoConfig() *msp.FabricCryptoConfig

func (*FabricMSPConfig) GetFabricNodeOus

func (x *FabricMSPConfig) GetFabricNodeOus() *msp.FabricNodeOUs

func (*FabricMSPConfig) GetIntermediateCerts

func (x *FabricMSPConfig) GetIntermediateCerts() [][]byte

func (*FabricMSPConfig) GetKnownCerts

func (x *FabricMSPConfig) GetKnownCerts() [][]byte

func (*FabricMSPConfig) GetName

func (x *FabricMSPConfig) GetName() string

func (*FabricMSPConfig) GetOrganizationalUnitIdentifiers

func (x *FabricMSPConfig) GetOrganizationalUnitIdentifiers() []*msp.FabricOUIdentifier

func (*FabricMSPConfig) GetRevocationList

func (x *FabricMSPConfig) GetRevocationList() [][]byte

func (*FabricMSPConfig) GetRootCerts

func (x *FabricMSPConfig) GetRootCerts() [][]byte

func (*FabricMSPConfig) GetSigningIdentity

func (x *FabricMSPConfig) GetSigningIdentity() *msp.SigningIdentityInfo

func (*FabricMSPConfig) GetTlsIntermediateCerts

func (x *FabricMSPConfig) GetTlsIntermediateCerts() [][]byte

func (*FabricMSPConfig) GetTlsRootCerts

func (x *FabricMSPConfig) GetTlsRootCerts() [][]byte

func (*FabricMSPConfig) ProtoMessage

func (*FabricMSPConfig) ProtoMessage()

func (*FabricMSPConfig) ProtoReflect

func (x *FabricMSPConfig) ProtoReflect() protoreflect.Message

func (*FabricMSPConfig) Reset

func (x *FabricMSPConfig) Reset()

func (*FabricMSPConfig) String

func (x *FabricMSPConfig) String() string

type Identity

type Identity struct {

	// The identifier of the associated membership service provider
	MspId string `protobuf:"bytes,1,opt,name=msp_id,json=mspId,proto3" json:"msp_id,omitempty"`
	// Types that are valid to be assigned to Creator:
	//
	//	*Identity_Certificate
	//	*Identity_CertificateId
	Creator isIdentity_Creator `protobuf_oneof:"creator"`
	// contains filtered or unexported fields
}

func NewIdentity

func NewIdentity(mspID string, certificate []byte) *Identity

NewIdentity creates a msppb.Identity with the certificate.

func NewIdentityWithIDOfCert

func NewIdentityWithIDOfCert(mspID, certificateID string) *Identity

NewIdentityWithIDOfCert creates a msppb.Identity with the certificateID.

func (*Identity) Descriptor deprecated

func (*Identity) Descriptor() ([]byte, []int)

Deprecated: Use Identity.ProtoReflect.Descriptor instead.

func (*Identity) GetCertificate

func (x *Identity) GetCertificate() []byte

func (*Identity) GetCertificateId

func (x *Identity) GetCertificateId() string

func (*Identity) GetCreator

func (x *Identity) GetCreator() isIdentity_Creator

func (*Identity) GetMspId

func (x *Identity) GetMspId() string

func (*Identity) ProtoMessage

func (*Identity) ProtoMessage()

func (*Identity) ProtoReflect

func (x *Identity) ProtoReflect() protoreflect.Message

func (*Identity) Reset

func (x *Identity) Reset()

func (*Identity) String

func (x *Identity) String() string

type Identity_Certificate

type Identity_Certificate struct {
	// The full raw bytes of the creator's certificate (e.g., an X.509 certificate).
	Certificate []byte `protobuf:"bytes,2,opt,name=certificate,proto3,oneof"`
}

type Identity_CertificateId

type Identity_CertificateId struct {
	// An identifier for a certificate that is pre-stored or known by the committer.
	CertificateId string `protobuf:"bytes,3,opt,name=certificate_id,json=certificateId,proto3,oneof"`
}

Jump to

Keyboard shortcuts

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