diff --git a/core/scc/lscc/lscc.go b/core/scc/lscc/lscc.go index 2e2c268da03..c54337b7f96 100644 --- a/core/scc/lscc/lscc.go +++ b/core/scc/lscc/lscc.go @@ -721,7 +721,7 @@ func (lscc *LifeCycleSysCC) Invoke(stub shim.ChaincodeStubInterface) pb.Response // 2. check local MSP Admins policy if err = lscc.policyChecker.CheckPolicyNoChannel(mgmt.Admins, sp); err != nil { - return shim.Error(fmt.Sprintf("Authorization for INSTALL on %s has been denied with error %s", args[1], err)) + return shim.Error(fmt.Sprintf("Authorization for INSTALL has been denied (error-%s)", err)) } depSpec := args[1] diff --git a/core/scc/lscc/lscc_test.go b/core/scc/lscc/lscc_test.go index ca543cabae6..21c57e39f77 100644 --- a/core/scc/lscc/lscc_test.go +++ b/core/scc/lscc/lscc_test.go @@ -86,7 +86,7 @@ func TestInstall(t *testing.T) { testInstall(t, "example02.go", "0", path, InvalidChaincodeNameErr("example02.go").Error(), "Alice") testInstall(t, "", "0", path, EmptyChaincodeNameErr("").Error(), "Alice") testInstall(t, "example02", "1{}0", path, InvalidVersionErr("1{}0").Error(), "Alice") - testInstall(t, "example02", "0", path, "Authorization for INSTALL on", "Bob") + testInstall(t, "example02", "0", path, "Authorization for INSTALL has been denied", "Bob") } func testInstall(t *testing.T, ccname string, version string, path string, expectedErrorMsg string, caller string) {