Skip to content

Conversation

@krpeacock
Copy link
Contributor

@krpeacock krpeacock commented Jan 3, 2024

Description

Adds a utility method to initialize a secp256k1 identity from a pem file.

Fixes SDK-1255
Fixes SDKTG-221

How Has This Been Tested?

Tested against a test identity exported from dfx and compatible with dfx and keysmith

Checklist:

  • My changes follow the guidelines in CONTRIBUTING.md.
  • The title of this PR complies with Conventional Commits.
  • I have edited the CHANGELOG accordingly.
  • I have made corresponding changes to the documentation.

@github-actions
Copy link
Contributor

github-actions bot commented Jan 3, 2024

size-limit report 📦

Path Size
@dfinity/agent 101.1 KB (0%)
@dfinity/candid 13.61 KB (0%)
@dfinity/principal 5.04 KB (0%)
@dfinity/auth-client 91.84 KB (0%)
@dfinity/assets 92.87 KB (0%)
@dfinity/identity 89.15 KB (0%)
@dfinity/identity-secp256k1 280.34 KB (+6.06% 🔺)

@krpeacock krpeacock requested a review from randombit February 16, 2024 22:15
@krpeacock
Copy link
Contributor Author

@randombit got back to this today - should be more legible now. Thanks for your suggestions!

@krpeacock krpeacock marked this pull request as ready for review February 16, 2024 23:07
@krpeacock krpeacock requested a review from a team as a code owner February 16, 2024 23:07
@krpeacock krpeacock enabled auto-merge (squash) February 21, 2024 18:51
@krpeacock krpeacock merged commit e04e3c6 into main Feb 21, 2024
@krpeacock krpeacock deleted the kai/SDK-1255-from-pem branch February 21, 2024 18:57
@randombit
Copy link

LGTM

hpeebles pushed a commit to hpeebles/agent-js that referenced this pull request Mar 28, 2024
* feat: adds pemToSecretKey

* feat: adds `fromPem` method for `identity-secp256k1`

* wip

* feat: check for ASN.1 OID before returning private key

* rebuilding package-lock

* increasing size limit

* Update docs/generated/changelog.html

* Update docs/generated/changelog.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants