Skip to content

Commit 0728bd5

Browse files
author
Jason Yellick
committed
[FAB-4765] Remove dead MSP config code
The getMspConfig function loads the MSP signer certs from the signer cert dir, error if the dir is not present, and then does nothing with them. This function is used to get the Verifying MSP definition to include in a channel, so requiring that a signcerts directory be present is non-sensical in this case, but still causes an error if not present. Change-Id: Ic89709df51f768a06c08551563b1e00df05f7695 Signed-off-by: Jason Yellick <[email protected]>
1 parent 859fd8a commit 0728bd5

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

msp/configbuilder.go

-6
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,6 @@ func GetVerifyingMspConfig(dir string, ID string) (*msp.MSPConfig, error) {
162162

163163
func getMspConfig(dir string, ID string, sigid *msp.SigningIdentityInfo) (*msp.MSPConfig, error) {
164164
cacertDir := filepath.Join(dir, cacerts)
165-
signcertDir := filepath.Join(dir, signcerts)
166165
admincertDir := filepath.Join(dir, admincerts)
167166
intermediatecertsDir := filepath.Join(dir, intermediatecerts)
168167
crlsDir := filepath.Join(dir, crlsfolder)
@@ -173,11 +172,6 @@ func getMspConfig(dir string, ID string, sigid *msp.SigningIdentityInfo) (*msp.M
173172
return nil, fmt.Errorf("Could not load a valid ca certificate from directory %s, err %s", cacertDir, err)
174173
}
175174

176-
signcert, err := getPemMaterialFromDir(signcertDir)
177-
if err != nil || len(signcert) == 0 {
178-
return nil, fmt.Errorf("Could not load a valid signer certificate from directory %s, err %s", signcertDir, err)
179-
}
180-
181175
admincert, err := getPemMaterialFromDir(admincertDir)
182176
if err != nil || len(admincert) == 0 {
183177
return nil, fmt.Errorf("Could not load a valid admin certificate from directory %s, err %s", admincertDir, err)

0 commit comments

Comments
 (0)