Skip to content

Commit

Permalink
Revert "fixup! Idemix MSP Folder Structure incompatible with what Fab…
Browse files Browse the repository at this point in the history
…ric expects #303"

This reverts commit 29e083e.
  • Loading branch information
jkneubuh authored Jul 7, 2022
1 parent 832cf96 commit cc46f24
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
14 changes: 1 addition & 13 deletions lib/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
"encoding/hex"
"encoding/json"
"fmt"
"github.com/hyperledger/fabric-protos-go/msp"
"io/ioutil"
"net"
"net/http"
Expand Down Expand Up @@ -945,18 +944,7 @@ func (c *Client) verifyIdemixCredential() error {
signerConfig := &idemixcred.SignerConfig{}
err = json.Unmarshal(credfileBytes, signerConfig)
if err != nil {
// try proto
idemixSignerConfig := &msp.IdemixMSPSignerConfig{}
err = proto.Unmarshal(credfileBytes, idemixSignerConfig)
if err != nil {
return errors.Wrapf(err, "Failed to unmarshal signer config from %s", c.idemixCredFile)
}
signerConfig.Cred = idemixSignerConfig.Cred
signerConfig.Sk = idemixSignerConfig.Sk
signerConfig.CredentialRevocationInformation = idemixSignerConfig.CredentialRevocationInformation
signerConfig.EnrollmentID = idemixSignerConfig.EnrollmentId
signerConfig.Role = int(idemixSignerConfig.Role)
signerConfig.OrganizationalUnitIdentifier = idemixSignerConfig.OrganizationalUnitIdentifier
return errors.Wrapf(err, "Failed to unmarshal signer config from %s", c.idemixCredFile)
}

cred := new(idemix.Credential)
Expand Down
2 changes: 0 additions & 2 deletions lib/client/credential/idemix/credential.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,6 @@ func (cred *Credential) Store() error {
return err
}
caSignerConfig := val.(*SignerConfig)

// Store the MSP signer config as Fabric expects
mspSignerConfig := &m.IdemixMSPSignerConfig{
Cred: caSignerConfig.Cred,
Sk: caSignerConfig.Sk,
Expand Down

0 comments on commit cc46f24

Please sign in to comment.