Documentation ¶
Index ¶
- type MockFabricCAServer
- type MockKey
- type MockSigningIdentity
- func (m *MockSigningIdentity) EnrollmentCertificate() []byte
- func (m *MockSigningIdentity) Identifier() *msp.IdentityIdentifier
- func (m *MockSigningIdentity) PrivateKey() core.Key
- func (m *MockSigningIdentity) PublicVersion() msp.Identity
- func (m *MockSigningIdentity) Serialize() ([]byte, error)
- func (m *MockSigningIdentity) SetEnrollmentCertificate(cert []byte)
- func (m *MockSigningIdentity) SetPrivateKey(key core.Key)
- func (m *MockSigningIdentity) Sign(msg []byte) ([]byte, error)
- func (m *MockSigningIdentity) Verify(msg []byte, sig []byte) error
- type MockUserStore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockFabricCAServer ¶
type MockFabricCAServer struct {
// contains filtered or unexported fields
}
MockFabricCAServer is a mock for FabricCAServer
func (*MockFabricCAServer) Running ¶
func (s *MockFabricCAServer) Running() bool
Running returns the status of the mock server
func (*MockFabricCAServer) Start ¶
func (s *MockFabricCAServer) Start(lis net.Listener, cryptoSuite core.CryptoSuite)
Start fabric CA mock server
type MockSigningIdentity ¶
type MockSigningIdentity struct {
// contains filtered or unexported fields
}
MockSigningIdentity ...
func NewMockSigningIdentity ¶
func NewMockSigningIdentity(id string, mspid string) *MockSigningIdentity
NewMockSigningIdentity to return mock user with MSPID
func (*MockSigningIdentity) EnrollmentCertificate ¶
func (m *MockSigningIdentity) EnrollmentCertificate() []byte
EnrollmentCertificate Returns the underlying ECert representing this user’s identity.
func (*MockSigningIdentity) Identifier ¶
func (m *MockSigningIdentity) Identifier() *msp.IdentityIdentifier
Identifier returns the identifier of that identity
func (*MockSigningIdentity) PrivateKey ¶
func (m *MockSigningIdentity) PrivateKey() core.Key
PrivateKey returns the crypto suite representation of the private key
func (*MockSigningIdentity) PublicVersion ¶
func (m *MockSigningIdentity) PublicVersion() msp.Identity
PublicVersion returns the public parts of this identity
func (*MockSigningIdentity) Serialize ¶
func (m *MockSigningIdentity) Serialize() ([]byte, error)
Serialize converts an identity to bytes
func (*MockSigningIdentity) SetEnrollmentCertificate ¶
func (m *MockSigningIdentity) SetEnrollmentCertificate(cert []byte)
SetEnrollmentCertificate sets yhe enrollment certificate.
func (*MockSigningIdentity) SetPrivateKey ¶
func (m *MockSigningIdentity) SetPrivateKey(key core.Key)
SetPrivateKey sets the private key
type MockUserStore ¶
type MockUserStore struct { }
MockUserStore ...
func (*MockUserStore) Load ¶
func (m *MockUserStore) Load(identifier msp.IdentityIdentifier) (*msp.UserData, error)
Load ...
Click to show internal directories.
Click to hide internal directories.