Skip to content

Commit

Permalink
fix(askar): secure environment get public key is now async
Browse files Browse the repository at this point in the history
Signed-off-by: Berend Sliedrecht <[email protected]>
  • Loading branch information
Berend Sliedrecht committed Nov 25, 2024
1 parent 2110e4a commit df6589e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
4 changes: 2 additions & 2 deletions packages/askar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"tsyringe": "^4.8.0"
},
"devDependencies": {
"@animo-id/expo-secure-environment": "^0.0.1-alpha.0",
"@animo-id/expo-secure-environment": "^0.1.0-alpha.11",
"@hyperledger/aries-askar-nodejs": "^0.2.3",
"@hyperledger/aries-askar-shared": "^0.2.3",
"@types/bn.js": "^5.1.0",
Expand All @@ -46,7 +46,7 @@
},
"peerDependencies": {
"@hyperledger/aries-askar-shared": "^0.2.3",
"@animo-id/expo-secure-environment": "^0.0.1-alpha.0"
"@animo-id/expo-secure-environment": "*"
},
"peerDependenciesMeta": {
"@animo-id/expo-secure-environment": {
Expand Down
2 changes: 1 addition & 1 deletion packages/askar/src/wallet/AskarBaseWallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ export abstract class AskarBaseWallet implements Wallet {

// Generate a hardware-backed P-256 keypair
secureEnvironment.generateKeypair(kid)
const publicKeyBytes = secureEnvironment.getPublicBytesForKeyId(kid)
const publicKeyBytes = await secureEnvironment.getPublicBytesForKeyId(kid)
const publicKeyBase58 = TypedArrayEncoder.toBase58(publicKeyBytes)

await this.storeSecureEnvironmentKeyById({
Expand Down
18 changes: 10 additions & 8 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit df6589e

Please sign in to comment.