Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Public key store/cache for Observer #1262

Merged
merged 1 commit into from
Apr 27, 2022
Merged

Conversation

bstasyszyn
Copy link
Contributor

Implemented a public key storage and cache for the Observer. When verifying a witness proof, the Observer will load the public key of the signer from the cache/database. If it doesn't exist in the DB then the public key is retrieved using the public key fetcher.

Also enhanced the BDD test so that, when creating DIDs on multiple targets, the target will be greylisted if it is down and the create will be performed on another target.

closes #1261

Signed-off-by: Bob Stasyszyn Bob.Stasyszyn@securekey.com

@cla-bot cla-bot bot added the cla-signed label Apr 26, 2022
@codecov
Copy link

codecov bot commented Apr 26, 2022

Codecov Report

Merging #1262 (f71bd68) into main (4425233) will decrease coverage by 0.00%.
The diff coverage is 87.17%.

@@            Coverage Diff             @@
##             main    #1262      +/-   ##
==========================================
- Coverage   87.87%   87.87%   -0.01%     
==========================================
  Files         173      174       +1     
  Lines       17397    17471      +74     
==========================================
+ Hits        15288    15352      +64     
- Misses       1345     1351       +6     
- Partials      764      768       +4     
Impacted Files Coverage Δ
cmd/orb-server/startcmd/start.go 68.00% <33.33%> (-0.25%) ⬇️
pkg/store/publickey/publickeystore.go 90.62% <90.62%> (ø)
pkg/discovery/endpoint/client/client.go 84.01% <100.00%> (+0.24%) ⬆️
pkg/store/anchorstatus/store.go 96.51% <100.00%> (ø)
pkg/observer/pubsub.go 94.49% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4425233...f71bd68. Read the comment docs.

Implemented a public key storage and cache for the Observer. When verifying a witness proof, the Observer will load the public key of the signer from the cache/database. If it doesn't exist in the DB then the public key is retrieved using the public key fetcher.

Also enhanced the BDD test so that, when creating DIDs on multiple targets, the target will be greylisted if it is down and the create will be performed on another target.

closes trustbloc#1261

Signed-off-by: Bob Stasyszyn <Bob.Stasyszyn@securekey.com>
@fqutishat fqutishat merged commit 07f44d6 into trustbloc:main Apr 27, 2022
@bstasyszyn bstasyszyn deleted the 1261 branch June 30, 2022 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Witness proof verification fails when witness domain is down
3 participants