Skip to content
This repository was archived by the owner on Aug 2, 2022. It is now read-only.

Sign, recover, verify, and validate functions (release/21.0.x branch) #654

Merged
jlamarr22 merged 5 commits intorelease/21.0.xfrom
ecc-pkg-functions
Jan 23, 2020
Merged

Sign, recover, verify, and validate functions (release/21.0.x branch) #654
jlamarr22 merged 5 commits intorelease/21.0.xfrom
ecc-pkg-functions

Conversation

@bradlhart
Copy link
Copy Markdown
Contributor

Change Description

Adding functions that were available in eosjs-ecc to PrivateKey/PublicKey/Signature classes to handle the format conversions and call elliptic functions.

Second PR to cherry pick commits to release/21.0.x branch

API Changes

  • API Changes

PrivateKey.getPublicKey(): Retrieve the public key from a private key
PrivateKey.sign(): Sign a message digest with private key

PublicKey.validate(): Validate a public key

Signature.verify(): Verify a signature with a message digest and public key
Signature.recoverPublicKey(): Recover a public key from a message digest and signature

constructElliptic() in eosjs-key-conversions.js: Used for PrivateKey, PublicKey, Signature

Documentation Additions

  • Documentation Additions

Bradley Hart added 5 commits January 23, 2020 15:43
Added/adjusted tests

Adjusted JsSignatureProvider to use new sign method
Moving constructElliptic to a central location
@jlamarr22 jlamarr22 merged commit 87ac6b3 into release/21.0.x Jan 23, 2020
@jlamarr22 jlamarr22 deleted the ecc-pkg-functions branch January 23, 2020 21:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants