#fabric A probable Bug of Fabric 2.1 BCCSP #fabric


paul_lee0919@...
 

A probable bug of Fabric 2.1*
There might be a typo in the source code of Fabric release 2.1 /bccsp/sw/fileks.go line 82.
original code "*copy(pk.pwd, pwd)*" should be revised into "*copy(clone, pwd)*", otherwise the *ks.pwd* will be replaced by the empty bytes array clone[ ]. 

Please correct me if my understanding is wrong.

--
Paul 


Brett T Logan <brett.t.logan@...>
 

Nice catch, I refactored that area of code a few months back and this was missed in review. I've submitted a PR to correct it: https://github.com/hyperledger/fabric/pull/2018
 
Thank you for letting us know!
 
Brett Logan
Software Engineer, IBM Blockchain
Phone: 1-984-242-6890
 
 
 

----- Original message -----
From: paul_lee0919@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] #fabric A probable Bug of Fabric 2.1 BCCSP
Date: Thu, Oct 15, 2020 11:19 PM
 
A probable bug of Fabric 2.1*
There might be a typo in the source code of Fabric release 2.1 /bccsp/sw/fileks.go line 82.
original code "*copy(pk.pwd, pwd)*" should be revised into "*copy(clone, pwd)*", otherwise the *ks.pwd* will be replaced by the empty bytes array clone[ ]. 

Please correct me if my understanding is wrong.

--
Paul 
 


Gari Singh <garis@...>
 

In the end, it does not actually affect anything as we never use this field as far as I recall.

Gari Singh
garis@...
978-846-7499



On Oct 15, 2020, at 11:38 PM, Brett T Logan <Brett.T.Logan@...> wrote:


Nice catch, I refactored that area of code a few months back and this was missed in review. I've submitted a PR to correct it: https://github.com/hyperledger/fabric/pull/2018
 
Thank you for letting us know!
 
Brett Logan
Software Engineer, IBM Blockchain
Phone: 1-984-242-6890
 
<Image.16027896466640.png>
 
 
----- Original message -----
From: paul_lee0919@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] #fabric A probable Bug of Fabric 2.1 BCCSP
Date: Thu, Oct 15, 2020 11:19 PM
 
A probable bug of Fabric 2.1*
There might be a typo in the source code of Fabric release 2.1 /bccsp/sw/fileks.go line 82.
original code "*copy(pk.pwd, pwd)*" should be revised into "*copy(clone, pwd)*", otherwise the *ks.pwd* will be replaced by the empty bytes array clone[ ]. 

Please correct me if my understanding is wrong.

--
Paul