-
Notifications
You must be signed in to change notification settings - Fork 8.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FAB-6355] Fix GetPrivateData() error on CouchDB
The problem was that the retrieve of the public hash from couch state db fails due to a URL encoding issue of a plus sign in the hashed key. Keys were already URL encoded using golang URL encoding, but the encoding skips plus signs in the path component. CouchDB unencodes the plus sign as a space. The fix is to explicitly URL encode plus character when interacting with CouchDB. Also add unit test to verify the fix and test all other URL special characters. Also clarified the error message received when private version does not match public hash. Change-Id: I9b99d3446542e9eae0196158270205d3ea09db9f Signed-off-by: David Enyeart <enyeart@us.ibm.com>
- Loading branch information
Showing
3 changed files
with
29 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters