This repository was archived by the owner on Apr 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +128
-1
lines changed Expand file tree Collapse file tree 4 files changed +128
-1
lines changed Original file line number Diff line number Diff line change @@ -34,6 +34,12 @@ type Config interface {
3434 TcertBatchSize () int
3535 SecurityAlgorithm () string
3636 SecurityLevel () int
37+ SecurityProvider () string
38+ Ephemeral () bool
39+ SecurityProviderLibPath () string
40+ SecurityProviderPin () string
41+ SecurityProviderLabel () string
42+ SoftVerify () bool
3743 KeyStorePath () string
3844 CAKeyStorePath () string
3945 CryptoConfigPath () string
Original file line number Diff line number Diff line change @@ -146,3 +146,33 @@ func (c *MockConfig) CSPConfig() *bccspFactory.FactoryOpts {
146146func (c * MockConfig ) NetworkConfig () (* apiconfig.NetworkConfig , error ) {
147147 return nil , nil
148148}
149+
150+ //SecurityProvider provider SW or PKCS11
151+ func (c * MockConfig ) SecurityProvider () string {
152+ return "SW"
153+ }
154+
155+ //Ephemeral flag
156+ func (c * MockConfig ) Ephemeral () bool {
157+ return false
158+ }
159+
160+ //SoftVerify flag
161+ func (c * MockConfig ) SoftVerify () bool {
162+ return true
163+ }
164+
165+ //SecurityProviderLibPath will be set only if provider is PKCS11
166+ func (c * MockConfig ) SecurityProviderLibPath () string {
167+ return ""
168+ }
169+
170+ //SecurityProviderPin will be set only if provider is PKCS11
171+ func (c * MockConfig ) SecurityProviderPin () string {
172+ return ""
173+ }
174+
175+ //SecurityProviderLabel will be set only if provider is PKCS11
176+ func (c * MockConfig ) SecurityProviderLabel () string {
177+ return ""
178+ }
Original file line number Diff line number Diff line change @@ -113,6 +113,36 @@ func (c *MockConfig) SecurityLevel() int {
113113
114114}
115115
116+ //SecurityProvider provider SW or PKCS11
117+ func (c * MockConfig ) SecurityProvider () string {
118+ return "SW"
119+ }
120+
121+ //Ephemeral flag
122+ func (c * MockConfig ) Ephemeral () bool {
123+ return false
124+ }
125+
126+ //SoftVerify flag
127+ func (c * MockConfig ) SoftVerify () bool {
128+ return true
129+ }
130+
131+ //SecurityProviderLibPath will be set only if provider is PKCS11
132+ func (c * MockConfig ) SecurityProviderLibPath () string {
133+ return ""
134+ }
135+
136+ //SecurityProviderPin will be set only if provider is PKCS11
137+ func (c * MockConfig ) SecurityProviderPin () string {
138+ return ""
139+ }
140+
141+ //SecurityProviderLabel will be set only if provider is PKCS11
142+ func (c * MockConfig ) SecurityProviderLabel () string {
143+ return ""
144+ }
145+
116146// OrderersConfig returns a list of defined orderers
117147func (c * MockConfig ) OrderersConfig () ([]config.OrdererConfig , error ) {
118148 return nil , nil
You can’t perform that action at this time.
0 commit comments