Skip to content
This repository has been archived by the owner on Mar 27, 2024. It is now read-only.

feat: Present proof - signs the presentation #2596

Merged
merged 1 commit into from
Mar 3, 2021
Merged

feat: Present proof - signs the presentation #2596

merged 1 commit into from
Mar 3, 2021

Conversation

soluchok
Copy link
Contributor

@soluchok soluchok commented Mar 3, 2021

By default, we will sign the presentation with BbsBlsSignature2020 (if a signature is needed). Also, it can be changed by providing an option e.g WithAddProofFn.

Signed-off-by: Andrii Soluk [email protected]

@codecov
Copy link

codecov bot commented Mar 3, 2021

Codecov Report

Merging #2596 (ab46295) into main (5a969e2) will decrease coverage by 0.00%.
The diff coverage is 87.50%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2596      +/-   ##
==========================================
- Coverage   88.67%   88.66%   -0.01%     
==========================================
  Files         263      263              
  Lines       20188    20249      +61     
==========================================
+ Hits        17901    17954      +53     
- Misses       1332     1336       +4     
- Partials      955      959       +4     
Impacted Files Coverage Δ
pkg/didcomm/protocol/presentproof/middleware.go 100.00% <ø> (ø)
...mm/protocol/middleware/presentproof/middlewares.go 89.01% <84.61%> (-1.90%) ⬇️
pkg/client/presentproof/client.go 85.36% <100.00%> (+0.75%) ⬆️
pkg/controller/command/presentproof/command.go 100.00% <100.00%> (ø)
pkg/didcomm/protocol/presentproof/service.go 85.23% <100.00%> (+0.27%) ⬆️
pkg/framework/aries/default.go 78.57% <100.00%> (+0.52%) ⬆️

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 5a969e2...01ad7db. Read the comment docs.

return err
}

methodID := fingerprint.KeyFingerprint(bls12381g2pub, pubKey)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Baha-sk is going to add Create DID Key feature for bls12381 keys, please add a follow up task for him to replace this code with create bbs DID key api.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done #2601

SignatureRepresentation: verifiable.SignatureProofValue,
Suite: bbsblssignature2020.New(
suite.WithSigner(newBBSSigner(km, cr, kid)),
suite.WithVerifier(bbsblssignature2020.NewG2PublicKeyVerifier()),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit - you don't need a verifier when signing

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so. I will try to remove it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done #2601

@llorllale llorllale merged commit 4671672 into hyperledger-archives:main Mar 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants