Documentation ¶
Overview ¶
Package mocks is a generated GoMock package.
Index ¶
- type MockToken
- func (m *MockToken) Checksum(keyLabel string) ([]byte, error)
- func (m *MockToken) DeleteAllExcept(keyLabels []string) error
- func (m *MockToken) EXPECT() *MockTokenMockRecorder
- func (m *MockToken) Finalise() error
- func (m *MockToken) GenerateKey(label, keytype string, keysize int) error
- func (m *MockToken) ImportKey(keyBytes []byte, label string) error
- func (m *MockToken) PrintObjects(label *string) error
- type MockTokenCtx
- func (m *MockTokenCtx) CloseSession(sh pkcs11.SessionHandle) error
- func (m *MockTokenCtx) CreateObject(sh pkcs11.SessionHandle, temp []*pkcs11.Attribute) (pkcs11.ObjectHandle, error)
- func (m *MockTokenCtx) Destroy()
- func (m *MockTokenCtx) DestroyObject(sh pkcs11.SessionHandle, oh pkcs11.ObjectHandle) error
- func (m *MockTokenCtx) EXPECT() *MockTokenCtxMockRecorder
- func (m *MockTokenCtx) Encrypt(sh pkcs11.SessionHandle, message []byte) ([]byte, error)
- func (m_2 *MockTokenCtx) EncryptInit(sh pkcs11.SessionHandle, m []*pkcs11.Mechanism, o pkcs11.ObjectHandle) error
- func (m *MockTokenCtx) Finalize() error
- func (m *MockTokenCtx) FindObjects(sh pkcs11.SessionHandle, max int) ([]pkcs11.ObjectHandle, bool, error)
- func (m *MockTokenCtx) FindObjectsFinal(sh pkcs11.SessionHandle) error
- func (m *MockTokenCtx) FindObjectsInit(sh pkcs11.SessionHandle, temp []*pkcs11.Attribute) error
- func (m *MockTokenCtx) GenerateKey(sh pkcs11.SessionHandle, mech []*pkcs11.Mechanism, temp []*pkcs11.Attribute) (pkcs11.ObjectHandle, error)
- func (m *MockTokenCtx) GenerateKeyPair(sh pkcs11.SessionHandle, mech []*pkcs11.Mechanism, ...) (pkcs11.ObjectHandle, pkcs11.ObjectHandle, error)
- func (m *MockTokenCtx) GetAttributeValue(sh pkcs11.SessionHandle, o pkcs11.ObjectHandle, a []*pkcs11.Attribute) ([]*pkcs11.Attribute, error)
- func (m_2 *MockTokenCtx) GetMechanismInfo(slotID uint, m []*pkcs11.Mechanism) (pkcs11.MechanismInfo, error)
- func (m *MockTokenCtx) GetMechanismList(slotID uint) ([]*pkcs11.Mechanism, error)
- func (m *MockTokenCtx) GetSlotList(tokenPresent bool) ([]uint, error)
- func (m *MockTokenCtx) GetTokenInfo(slotID uint) (pkcs11.TokenInfo, error)
- func (m *MockTokenCtx) Initialize() error
- func (m *MockTokenCtx) Login(sh pkcs11.SessionHandle, userType uint, pin string) error
- func (m *MockTokenCtx) OpenSession(slotID, flags uint) (pkcs11.SessionHandle, error)
- type MockTokenCtxMockRecorder
- func (mr *MockTokenCtxMockRecorder) CloseSession(sh interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) CreateObject(sh, temp interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) Destroy() *gomock.Call
- func (mr *MockTokenCtxMockRecorder) DestroyObject(sh, oh interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) Encrypt(sh, message interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) EncryptInit(sh, m, o interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) Finalize() *gomock.Call
- func (mr *MockTokenCtxMockRecorder) FindObjects(sh, max interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) FindObjectsFinal(sh interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) FindObjectsInit(sh, temp interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GenerateKey(sh, mech, temp interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GenerateKeyPair(sh, mech, public, private interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GetAttributeValue(sh, o, a interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GetMechanismInfo(slotID, m interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GetMechanismList(slotID interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GetSlotList(tokenPresent interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) GetTokenInfo(slotID interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) Initialize() *gomock.Call
- func (mr *MockTokenCtxMockRecorder) Login(sh, userType, pin interface{}) *gomock.Call
- func (mr *MockTokenCtxMockRecorder) OpenSession(slotID, flags interface{}) *gomock.Call
- type MockTokenMockRecorder
- func (mr *MockTokenMockRecorder) Checksum(keyLabel interface{}) *gomock.Call
- func (mr *MockTokenMockRecorder) DeleteAllExcept(keyLabels interface{}) *gomock.Call
- func (mr *MockTokenMockRecorder) Finalise() *gomock.Call
- func (mr *MockTokenMockRecorder) GenerateKey(label, keytype, keysize interface{}) *gomock.Call
- func (mr *MockTokenMockRecorder) ImportKey(keyBytes, label interface{}) *gomock.Call
- func (mr *MockTokenMockRecorder) PrintObjects(label interface{}) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockToken ¶
type MockToken struct {
// contains filtered or unexported fields
}
MockToken is a mock of Token interface
func NewMockToken ¶
func NewMockToken(ctrl *gomock.Controller) *MockToken
NewMockToken creates a new mock instance
func (*MockToken) DeleteAllExcept ¶
DeleteAllExcept mocks base method
func (*MockToken) EXPECT ¶
func (m *MockToken) EXPECT() *MockTokenMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockToken) GenerateKey ¶
GenerateKey mocks base method
func (*MockToken) PrintObjects ¶
PrintObjects mocks base method
type MockTokenCtx ¶
type MockTokenCtx struct {
// contains filtered or unexported fields
}
MockTokenCtx is a mock of TokenCtx interface
func NewMockTokenCtx ¶
func NewMockTokenCtx(ctrl *gomock.Controller) *MockTokenCtx
NewMockTokenCtx creates a new mock instance
func (*MockTokenCtx) CloseSession ¶
func (m *MockTokenCtx) CloseSession(sh pkcs11.SessionHandle) error
CloseSession mocks base method
func (*MockTokenCtx) CreateObject ¶
func (m *MockTokenCtx) CreateObject(sh pkcs11.SessionHandle, temp []*pkcs11.Attribute) (pkcs11.ObjectHandle, error)
CreateObject mocks base method
func (*MockTokenCtx) DestroyObject ¶
func (m *MockTokenCtx) DestroyObject(sh pkcs11.SessionHandle, oh pkcs11.ObjectHandle) error
DestroyObject mocks base method
func (*MockTokenCtx) EXPECT ¶
func (m *MockTokenCtx) EXPECT() *MockTokenCtxMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockTokenCtx) Encrypt ¶
func (m *MockTokenCtx) Encrypt(sh pkcs11.SessionHandle, message []byte) ([]byte, error)
Encrypt mocks base method
func (*MockTokenCtx) EncryptInit ¶
func (m_2 *MockTokenCtx) EncryptInit(sh pkcs11.SessionHandle, m []*pkcs11.Mechanism, o pkcs11.ObjectHandle) error
EncryptInit mocks base method
func (*MockTokenCtx) FindObjects ¶
func (m *MockTokenCtx) FindObjects(sh pkcs11.SessionHandle, max int) ([]pkcs11.ObjectHandle, bool, error)
FindObjects mocks base method
func (*MockTokenCtx) FindObjectsFinal ¶
func (m *MockTokenCtx) FindObjectsFinal(sh pkcs11.SessionHandle) error
FindObjectsFinal mocks base method
func (*MockTokenCtx) FindObjectsInit ¶
func (m *MockTokenCtx) FindObjectsInit(sh pkcs11.SessionHandle, temp []*pkcs11.Attribute) error
FindObjectsInit mocks base method
func (*MockTokenCtx) GenerateKey ¶
func (m *MockTokenCtx) GenerateKey(sh pkcs11.SessionHandle, mech []*pkcs11.Mechanism, temp []*pkcs11.Attribute) (pkcs11.ObjectHandle, error)
GenerateKey mocks base method
func (*MockTokenCtx) GenerateKeyPair ¶
func (m *MockTokenCtx) GenerateKeyPair(sh pkcs11.SessionHandle, mech []*pkcs11.Mechanism, public, private []*pkcs11.Attribute) (pkcs11.ObjectHandle, pkcs11.ObjectHandle, error)
GenerateKeyPair mocks base method
func (*MockTokenCtx) GetAttributeValue ¶
func (m *MockTokenCtx) GetAttributeValue(sh pkcs11.SessionHandle, o pkcs11.ObjectHandle, a []*pkcs11.Attribute) ([]*pkcs11.Attribute, error)
GetAttributeValue mocks base method
func (*MockTokenCtx) GetMechanismInfo ¶
func (m_2 *MockTokenCtx) GetMechanismInfo(slotID uint, m []*pkcs11.Mechanism) (pkcs11.MechanismInfo, error)
GetMechanismInfo mocks base method
func (*MockTokenCtx) GetMechanismList ¶
func (m *MockTokenCtx) GetMechanismList(slotID uint) ([]*pkcs11.Mechanism, error)
GetMechanismList mocks base method
func (*MockTokenCtx) GetSlotList ¶
func (m *MockTokenCtx) GetSlotList(tokenPresent bool) ([]uint, error)
GetSlotList mocks base method
func (*MockTokenCtx) GetTokenInfo ¶
func (m *MockTokenCtx) GetTokenInfo(slotID uint) (pkcs11.TokenInfo, error)
GetTokenInfo mocks base method
func (*MockTokenCtx) Initialize ¶
func (m *MockTokenCtx) Initialize() error
Initialize mocks base method
func (*MockTokenCtx) Login ¶
func (m *MockTokenCtx) Login(sh pkcs11.SessionHandle, userType uint, pin string) error
Login mocks base method
func (*MockTokenCtx) OpenSession ¶
func (m *MockTokenCtx) OpenSession(slotID, flags uint) (pkcs11.SessionHandle, error)
OpenSession mocks base method
type MockTokenCtxMockRecorder ¶
type MockTokenCtxMockRecorder struct {
// contains filtered or unexported fields
}
MockTokenCtxMockRecorder is the mock recorder for MockTokenCtx
func (*MockTokenCtxMockRecorder) CloseSession ¶
func (mr *MockTokenCtxMockRecorder) CloseSession(sh interface{}) *gomock.Call
CloseSession indicates an expected call of CloseSession
func (*MockTokenCtxMockRecorder) CreateObject ¶
func (mr *MockTokenCtxMockRecorder) CreateObject(sh, temp interface{}) *gomock.Call
CreateObject indicates an expected call of CreateObject
func (*MockTokenCtxMockRecorder) Destroy ¶
func (mr *MockTokenCtxMockRecorder) Destroy() *gomock.Call
Destroy indicates an expected call of Destroy
func (*MockTokenCtxMockRecorder) DestroyObject ¶
func (mr *MockTokenCtxMockRecorder) DestroyObject(sh, oh interface{}) *gomock.Call
DestroyObject indicates an expected call of DestroyObject
func (*MockTokenCtxMockRecorder) Encrypt ¶
func (mr *MockTokenCtxMockRecorder) Encrypt(sh, message interface{}) *gomock.Call
Encrypt indicates an expected call of Encrypt
func (*MockTokenCtxMockRecorder) EncryptInit ¶
func (mr *MockTokenCtxMockRecorder) EncryptInit(sh, m, o interface{}) *gomock.Call
EncryptInit indicates an expected call of EncryptInit
func (*MockTokenCtxMockRecorder) Finalize ¶
func (mr *MockTokenCtxMockRecorder) Finalize() *gomock.Call
Finalize indicates an expected call of Finalize
func (*MockTokenCtxMockRecorder) FindObjects ¶
func (mr *MockTokenCtxMockRecorder) FindObjects(sh, max interface{}) *gomock.Call
FindObjects indicates an expected call of FindObjects
func (*MockTokenCtxMockRecorder) FindObjectsFinal ¶
func (mr *MockTokenCtxMockRecorder) FindObjectsFinal(sh interface{}) *gomock.Call
FindObjectsFinal indicates an expected call of FindObjectsFinal
func (*MockTokenCtxMockRecorder) FindObjectsInit ¶
func (mr *MockTokenCtxMockRecorder) FindObjectsInit(sh, temp interface{}) *gomock.Call
FindObjectsInit indicates an expected call of FindObjectsInit
func (*MockTokenCtxMockRecorder) GenerateKey ¶
func (mr *MockTokenCtxMockRecorder) GenerateKey(sh, mech, temp interface{}) *gomock.Call
GenerateKey indicates an expected call of GenerateKey
func (*MockTokenCtxMockRecorder) GenerateKeyPair ¶
func (mr *MockTokenCtxMockRecorder) GenerateKeyPair(sh, mech, public, private interface{}) *gomock.Call
GenerateKeyPair indicates an expected call of GenerateKeyPair
func (*MockTokenCtxMockRecorder) GetAttributeValue ¶
func (mr *MockTokenCtxMockRecorder) GetAttributeValue(sh, o, a interface{}) *gomock.Call
GetAttributeValue indicates an expected call of GetAttributeValue
func (*MockTokenCtxMockRecorder) GetMechanismInfo ¶
func (mr *MockTokenCtxMockRecorder) GetMechanismInfo(slotID, m interface{}) *gomock.Call
GetMechanismInfo indicates an expected call of GetMechanismInfo
func (*MockTokenCtxMockRecorder) GetMechanismList ¶
func (mr *MockTokenCtxMockRecorder) GetMechanismList(slotID interface{}) *gomock.Call
GetMechanismList indicates an expected call of GetMechanismList
func (*MockTokenCtxMockRecorder) GetSlotList ¶
func (mr *MockTokenCtxMockRecorder) GetSlotList(tokenPresent interface{}) *gomock.Call
GetSlotList indicates an expected call of GetSlotList
func (*MockTokenCtxMockRecorder) GetTokenInfo ¶
func (mr *MockTokenCtxMockRecorder) GetTokenInfo(slotID interface{}) *gomock.Call
GetTokenInfo indicates an expected call of GetTokenInfo
func (*MockTokenCtxMockRecorder) Initialize ¶
func (mr *MockTokenCtxMockRecorder) Initialize() *gomock.Call
Initialize indicates an expected call of Initialize
func (*MockTokenCtxMockRecorder) Login ¶
func (mr *MockTokenCtxMockRecorder) Login(sh, userType, pin interface{}) *gomock.Call
Login indicates an expected call of Login
func (*MockTokenCtxMockRecorder) OpenSession ¶
func (mr *MockTokenCtxMockRecorder) OpenSession(slotID, flags interface{}) *gomock.Call
OpenSession indicates an expected call of OpenSession
type MockTokenMockRecorder ¶
type MockTokenMockRecorder struct {
// contains filtered or unexported fields
}
MockTokenMockRecorder is the mock recorder for MockToken
func (*MockTokenMockRecorder) Checksum ¶
func (mr *MockTokenMockRecorder) Checksum(keyLabel interface{}) *gomock.Call
Checksum indicates an expected call of Checksum
func (*MockTokenMockRecorder) DeleteAllExcept ¶
func (mr *MockTokenMockRecorder) DeleteAllExcept(keyLabels interface{}) *gomock.Call
DeleteAllExcept indicates an expected call of DeleteAllExcept
func (*MockTokenMockRecorder) Finalise ¶
func (mr *MockTokenMockRecorder) Finalise() *gomock.Call
Finalise indicates an expected call of Finalise
func (*MockTokenMockRecorder) GenerateKey ¶
func (mr *MockTokenMockRecorder) GenerateKey(label, keytype, keysize interface{}) *gomock.Call
GenerateKey indicates an expected call of GenerateKey
func (*MockTokenMockRecorder) ImportKey ¶
func (mr *MockTokenMockRecorder) ImportKey(keyBytes, label interface{}) *gomock.Call
ImportKey indicates an expected call of ImportKey
func (*MockTokenMockRecorder) PrintObjects ¶
func (mr *MockTokenMockRecorder) PrintObjects(label interface{}) *gomock.Call
PrintObjects indicates an expected call of PrintObjects