daf-did-comm
Advanced tools
Comparing version 7.0.0-beta.57 to 7.0.0
517
CHANGELOG.md
@@ -6,3 +6,3 @@ # Change Log | ||
# [7.0.0-beta.57](https://github.com/uport-project/daf/compare/v7.0.0-beta.56...v7.0.0-beta.57) (2020-12-15) | ||
# [7.0.0](https://github.com/uport-project/daf/compare/v6.4.1...v7.0.0) (2020-12-17) | ||
@@ -13,226 +13,16 @@ | ||
* **message-handler:** Rewire promise rejections as `Error` objects ([#300](https://github.com/uport-project/daf/issues/300)) ([04446d4](https://github.com/uport-project/daf/commit/04446d4e2d2dba8ff2ae5695014686ef49891804)), closes [#294](https://github.com/uport-project/daf/issues/294) | ||
* MessageHandler ([21a78e3](https://github.com/uport-project/daf/commit/21a78e3a16257d2c9d956acfc46576955688aed4)) | ||
* OpenAPI schema ([2ef0bc7](https://github.com/uport-project/daf/commit/2ef0bc7ae4a425e29eae4aaad982048314c9ca14)) | ||
* Saving DIDComm message ([7d0201e](https://github.com/uport-project/daf/commit/7d0201ec584371a6257b651beffbad7776fe5d5c)) | ||
### Code Refactoring | ||
* Rename Identity to Identifier ([#308](https://github.com/uport-project/daf/issues/308)) ([7812e51](https://github.com/uport-project/daf/commit/7812e51ee250265bcc308e7fd4db1ee8b2e408a4)) | ||
* **daf-cli:** Refactor CLI command palette ([#304](https://github.com/uport-project/daf/issues/304)) ([a5a0670](https://github.com/uport-project/daf/commit/a5a0670f5162e3f8753fa338ed00e64397c8acc0)), closes [#264](https://github.com/uport-project/daf/issues/264) | ||
# [7.0.0-beta.56](https://github.com/uport-project/daf/compare/v7.0.0-beta.55...v7.0.0-beta.56) (2020-12-09) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.55](https://github.com/uport-project/daf/compare/v7.0.0-beta.54...v7.0.0-beta.55) (2020-12-08) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.54](https://github.com/uport-project/daf/compare/v7.0.0-beta.53...v7.0.0-beta.54) (2020-12-08) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.53](https://github.com/uport-project/daf/compare/v7.0.0-beta.52...v7.0.0-beta.53) (2020-12-04) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.52](https://github.com/uport-project/daf/compare/v7.0.0-beta.51...v7.0.0-beta.52) (2020-12-01) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.51](https://github.com/uport-project/daf/compare/v7.0.0-beta.50...v7.0.0-beta.51) (2020-11-26) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.50](https://github.com/uport-project/daf/compare/v7.0.0-beta.49...v7.0.0-beta.50) (2020-11-25) | ||
### Features | ||
* Generate plugin schema ([#277](https://github.com/uport-project/daf/issues/277)) ([c90473a](https://github.com/uport-project/daf/commit/c90473a67731eb0cfcaf545afe0d64dfee77809c)) | ||
# [7.0.0-beta.49](https://github.com/uport-project/daf/compare/v7.0.0-beta.48...v7.0.0-beta.49) (2020-11-24) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.48](https://github.com/uport-project/daf/compare/v7.0.0-beta.47...v7.0.0-beta.48) (2020-11-24) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.47](https://github.com/uport-project/daf/compare/v7.0.0-beta.46...v7.0.0-beta.47) (2020-11-23) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.46](https://github.com/uport-project/daf/compare/v7.0.0-beta.45...v7.0.0-beta.46) (2020-11-19) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.45](https://github.com/uport-project/daf/compare/v7.0.0-beta.44...v7.0.0-beta.45) (2020-10-22) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.44](https://github.com/uport-project/daf/compare/v7.0.0-beta.43...v7.0.0-beta.44) (2020-10-21) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.43](https://github.com/uport-project/daf/compare/v7.0.0-beta.42...v7.0.0-beta.43) (2020-10-21) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.42](https://github.com/uport-project/daf/compare/v7.0.0-beta.41...v7.0.0-beta.42) (2020-10-20) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.41](https://github.com/uport-project/daf/compare/v7.0.0-beta.40...v7.0.0-beta.41) (2020-10-20) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.40](https://github.com/uport-project/daf/compare/v7.0.0-beta.39...v7.0.0-beta.40) (2020-10-20) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.39](https://github.com/uport-project/daf/compare/v7.0.0-beta.38...v7.0.0-beta.39) (2020-10-20) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.38](https://github.com/uport-project/daf/compare/v7.0.0-beta.37...v7.0.0-beta.38) (2020-10-19) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.37](https://github.com/uport-project/daf/compare/v7.0.0-beta.36...v7.0.0-beta.37) (2020-10-19) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.36](https://github.com/uport-project/daf/compare/v7.0.0-beta.35...v7.0.0-beta.36) (2020-10-18) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.35](https://github.com/uport-project/daf/compare/v7.0.0-beta.34...v7.0.0-beta.35) (2020-10-18) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.34](https://github.com/uport-project/daf/compare/v7.0.0-beta.33...v7.0.0-beta.34) (2020-10-15) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.33](https://github.com/uport-project/daf/compare/v7.0.0-beta.32...v7.0.0-beta.33) (2020-10-15) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.32](https://github.com/uport-project/daf/compare/v7.0.0-beta.31...v7.0.0-beta.32) (2020-10-15) | ||
### Bug Fixes | ||
* Saving DIDComm message ([7d0201e](https://github.com/uport-project/daf/commit/7d0201ec584371a6257b651beffbad7776fe5d5c)) | ||
# [7.0.0-beta.31](https://github.com/uport-project/daf/compare/v7.0.0-beta.30...v7.0.0-beta.31) (2020-10-14) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.30](https://github.com/uport-project/daf/compare/v7.0.0-beta.29...v7.0.0-beta.30) (2020-10-13) | ||
### Features | ||
* Generating plugin schemas ([d4450cd](https://github.com/uport-project/daf/commit/d4450cd30e27ebc8bf961400b871757662e202c3)) | ||
@@ -244,15 +34,34 @@ * Removing GraphQL support ([3646aab](https://github.com/uport-project/daf/commit/3646aaba6bc72db933ceb7ddb4250bf4457902e3)) | ||
### BREAKING CHANGES | ||
* This rename affects almost all the Identity management API | ||
Please look for `IDIDManager.ts` in `daf-core/src/types` to see the new method names. | ||
Functionality is the same but some renaming is required if already in use. | ||
* refactor: Rename Identity to Identifier | ||
* fix: Integration tests | ||
* refactor: WebDIDProvider | ||
* refactor: EthrDIDProvider | ||
* refactor: DIDStore | ||
* refactor: Resolver | ||
* refactor: DidManagerFind | ||
* refactor: DidManagerFind | ||
* refactor: DidManagerGet | ||
* refactor: DidManagerCreate | ||
* refactor: DidManagerGetOrCreate | ||
* refactor: DidManagerImport | ||
* refactor: DidManagerDelete | ||
* refactor: KeyManager | ||
* refactor: DefaultDID | ||
* refactor: IDIDManager | ||
* refactor: IDIDManager.ts | ||
* **daf-cli:** This refactor changes the CLI list of commands. Run `daf --help` to get the latest options. | ||
The same actions are possible, but under different (simpler) names and subcommands. | ||
# [7.0.0-beta.29](https://github.com/uport-project/daf/compare/v7.0.0-beta.28...v7.0.0-beta.29) (2020-10-02) | ||
**Note:** Version bump only for package daf-did-comm | ||
## [6.4.1](https://github.com/uport-project/daf/compare/v6.4.0...v6.4.1) (2020-11-13) | ||
# [7.0.0-beta.28](https://github.com/uport-project/daf/compare/v7.0.0-beta.27...v7.0.0-beta.28) (2020-10-01) | ||
**Note:** Version bump only for package daf-did-comm | ||
@@ -264,211 +73,21 @@ | ||
# [7.0.0-beta.27](https://github.com/uport-project/daf/compare/v7.0.0-beta.26...v7.0.0-beta.27) (2020-09-30) | ||
# [6.4.0](https://github.com/uport-project/daf/compare/v6.3.1...v6.4.0) (2020-11-12) | ||
### Features | ||
### Bug Fixes | ||
- Enable setting headers to DAF DID Comm ([#239](https://github.com/uport-project/daf/issues/239)) ([03f3dbb](https://github.com/uport-project/daf/commit/03f3dbb9c1f8a2b061234cdddf4d70953209c1b3)) | ||
* MessageHandler ([21a78e3](https://github.com/uport-project/daf/commit/21a78e3a16257d2c9d956acfc46576955688aed4)) | ||
# [7.0.0-beta.26](https://github.com/uport-project/daf/compare/v7.0.0-beta.25...v7.0.0-beta.26) (2020-09-29) | ||
### Bug Fixes | ||
* OpenAPI schema ([2ef0bc7](https://github.com/uport-project/daf/commit/2ef0bc7ae4a425e29eae4aaad982048314c9ca14)) | ||
# [7.0.0-beta.25](https://github.com/uport-project/daf/compare/v7.0.0-beta.24...v7.0.0-beta.25) (2020-09-28) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.24](https://github.com/uport-project/daf/compare/v7.0.0-beta.23...v7.0.0-beta.24) (2020-09-25) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.23](https://github.com/uport-project/daf/compare/v7.0.0-beta.22...v7.0.0-beta.23) (2020-09-22) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.22](https://github.com/uport-project/daf/compare/v7.0.0-beta.21...v7.0.0-beta.22) (2020-09-22) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.21](https://github.com/uport-project/daf/compare/v7.0.0-beta.20...v7.0.0-beta.21) (2020-09-17) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.20](https://github.com/uport-project/daf/compare/v7.0.0-beta.19...v7.0.0-beta.20) (2020-09-15) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.19](https://github.com/uport-project/daf/compare/v7.0.0-beta.18...v7.0.0-beta.19) (2020-09-14) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.18](https://github.com/uport-project/daf/compare/v6.3.0...v7.0.0-beta.18) (2020-09-09) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.17](https://github.com/uport-project/daf/compare/v6.1.1...v7.0.0-beta.17) (2020-09-04) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.16](https://github.com/uport-project/daf/compare/v7.0.0-beta.15...v7.0.0-beta.16) (2020-09-02) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.15](https://github.com/uport-project/daf/compare/v7.0.0-beta.14...v7.0.0-beta.15) (2020-08-27) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.14](https://github.com/uport-project/daf/compare/v7.0.0-beta.13...v7.0.0-beta.14) (2020-08-26) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.13](https://github.com/uport-project/daf/compare/v7.0.0-beta.12...v7.0.0-beta.13) (2020-08-26) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.12](https://github.com/uport-project/daf/compare/v7.0.0-beta.11...v7.0.0-beta.12) (2020-08-26) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.11](https://github.com/uport-project/daf/compare/v7.0.0-beta.10...v7.0.0-beta.11) (2020-08-17) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.10](https://github.com/uport-project/daf/compare/v7.0.0-beta.9...v7.0.0-beta.10) (2020-08-17) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.9](https://github.com/uport-project/daf/compare/v7.0.0-beta.8...v7.0.0-beta.9) (2020-08-14) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.8](https://github.com/uport-project/daf/compare/v7.0.0-beta.7...v7.0.0-beta.8) (2020-07-14) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.7](https://github.com/uport-project/daf/compare/v7.0.0-beta.6...v7.0.0-beta.7) (2020-07-10) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.6](https://github.com/uport-project/daf/compare/v7.0.0-beta.5...v7.0.0-beta.6) (2020-07-10) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.5](https://github.com/uport-project/daf/compare/v7.0.0-beta.4...v7.0.0-beta.5) (2020-07-10) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.4](https://github.com/uport-project/daf/compare/v7.0.0-beta.3...v7.0.0-beta.4) (2020-07-09) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.3](https://github.com/uport-project/daf/compare/v7.0.0-beta.2...v7.0.0-beta.3) (2020-07-09) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.2](https://github.com/uport-project/daf/compare/v7.0.0-beta.1...v7.0.0-beta.2) (2020-07-07) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [7.0.0-beta.1](https://github.com/uport-project/daf/compare/v6.1.1...v7.0.0-beta.1) (2020-07-07) | ||
**Note:** Version bump only for package daf-did-comm | ||
# [6.3.0](https://github.com/uport-project/daf/compare/v6.1.1...v6.3.0) (2020-09-04) | ||
### Features | ||
* **release:** Fix package descriptions and trigger new minor release ([#233](https://github.com/uport-project/daf/issues/233)) ([e67f4da](https://github.com/uport-project/daf/commit/e67f4da055d1f0b1b0ba4205726b79979d234a06)) | ||
* **release:** Trigger a new minor release ([#234](https://github.com/uport-project/daf/issues/234)) ([7c905e1](https://github.com/uport-project/daf/commit/7c905e1ea7c4851f7f06e87e06efe34d4eac7b0f)) | ||
- **release:** Fix package descriptions and trigger new minor release ([#233](https://github.com/uport-project/daf/issues/233)) ([e67f4da](https://github.com/uport-project/daf/commit/e67f4da055d1f0b1b0ba4205726b79979d234a06)) | ||
- **release:** Trigger a new minor release ([#234](https://github.com/uport-project/daf/issues/234)) ([7c905e1](https://github.com/uport-project/daf/commit/7c905e1ea7c4851f7f06e87e06efe34d4eac7b0f)) | ||
# [6.2.0](https://github.com/uport-project/daf/compare/v6.1.2...v6.2.0) (2020-09-04) | ||
### Features | ||
* **release:** Fix package descriptions and trigger new minor release ([#233](https://github.com/uport-project/daf/issues/233)) ([e67f4da](https://github.com/uport-project/daf/commit/e67f4da055d1f0b1b0ba4205726b79979d234a06)) | ||
- **release:** Fix package descriptions and trigger new minor release ([#233](https://github.com/uport-project/daf/issues/233)) ([e67f4da](https://github.com/uport-project/daf/commit/e67f4da055d1f0b1b0ba4205726b79979d234a06)) | ||
## [6.1.2](https://github.com/uport-project/daf/compare/v6.1.1...v6.1.2) (2020-09-03) | ||
@@ -478,6 +97,2 @@ | ||
## [6.1.1](https://github.com/uport-project/daf/compare/v6.1.0...v6.1.1) (2020-07-06) | ||
@@ -487,6 +102,2 @@ | ||
# [6.0.0](https://github.com/uport-project/daf/compare/v5.7.0...v6.0.0) (2020-05-29) | ||
@@ -496,6 +107,2 @@ | ||
# [5.7.0](https://github.com/uport-project/daf/compare/v5.6.7...v5.7.0) (2020-05-29) | ||
@@ -505,6 +112,2 @@ | ||
## [5.6.6](https://github.com/uport-project/daf/compare/v5.6.5...v5.6.6) (2020-05-26) | ||
@@ -514,6 +117,2 @@ | ||
## [5.6.5](https://github.com/uport-project/daf/compare/v5.6.4...v5.6.5) (2020-05-25) | ||
@@ -523,6 +122,2 @@ | ||
## [5.6.4](https://github.com/uport-project/daf/compare/v5.6.3...v5.6.4) (2020-05-22) | ||
@@ -532,6 +127,2 @@ | ||
# [5.5.0](https://github.com/uport-project/daf/compare/v5.4.0...v5.5.0) (2020-05-13) | ||
@@ -541,6 +132,2 @@ | ||
# [5.1.0](https://github.com/uport-project/daf/compare/v5.0.0...v5.1.0) (2020-05-06) | ||
@@ -550,6 +137,2 @@ | ||
# [5.0.0](https://github.com/uport-project/daf/compare/v4.5.0...v5.0.0) (2020-05-05) | ||
@@ -559,6 +142,2 @@ | ||
# [4.5.0](https://github.com/uport-project/daf/compare/v4.4.0...v4.5.0) (2020-05-05) | ||
@@ -568,6 +147,2 @@ | ||
# [4.4.0](https://github.com/uport-project/daf/compare/v4.3.0...v4.4.0) (2020-04-29) | ||
@@ -577,6 +152,2 @@ | ||
# [4.3.0](https://github.com/uport-project/daf/compare/v4.2.1...v4.3.0) (2020-04-28) | ||
@@ -586,6 +157,2 @@ | ||
# [4.2.0](https://github.com/uport-project/daf/compare/v4.1.0...v4.2.0) (2020-04-24) | ||
@@ -595,10 +162,4 @@ | ||
# [4.1.0](https://github.com/uport-project/daf/compare/v4.0.0...v4.1.0) (2020-04-23) | ||
## [3.4.2](https://github.com/uport-project/daf/compare/v3.4.1...v3.4.2) (2020-03-23) | ||
@@ -608,6 +169,2 @@ | ||
# [4.0.0](https://github.com/uport-project/daf/compare/v4.0.0-beta.48...v4.0.0) (2020-04-22) | ||
@@ -614,0 +171,0 @@ |
{ | ||
"name": "daf-did-comm", | ||
"description": "DAF DIDComm inspired messaging based on the v1 messaging envelope.", | ||
"version": "7.0.0-beta.57", | ||
"version": "7.0.0", | ||
"main": "build/index.js", | ||
@@ -9,3 +9,3 @@ "types": "build/index.d.ts", | ||
"build": "tsc", | ||
"generate-plugin-schema": "yarn daf generate-plugin-schema" | ||
"generate-plugin-schema": "yarn daf dev generate-plugin-schema" | ||
}, | ||
@@ -19,4 +19,4 @@ "daf": { | ||
"cross-fetch": "^3.0.5", | ||
"daf-core": "^7.0.0-beta.57", | ||
"daf-message-handler": "^7.0.0-beta.57", | ||
"daf-core": "^7.0.0", | ||
"daf-message-handler": "^7.0.0", | ||
"debug": "^4.1.1", | ||
@@ -41,3 +41,3 @@ "uuid": "^8.3.0" | ||
"keywords": [], | ||
"gitHead": "bb7f0629e3e73b02d1bd120d38d59fd4e0638bf1" | ||
"gitHead": "f4f70d057f8ca3b42b335a37ea28d95c5322a75e" | ||
} |
@@ -46,2 +46,8 @@ { | ||
] | ||
}, | ||
"headers": { | ||
"type": "object", | ||
"additionalProperties": { | ||
"type": "string" | ||
} | ||
} | ||
@@ -238,3 +244,3 @@ }, | ||
], | ||
"description": "Verifiable Credential {@link https://github.com/decentralized-identity/did-jwt-vc}" | ||
"description": "Verifiable Credential {@link https://github.com/decentralized-identifier/did-jwt-vc}" | ||
}, | ||
@@ -297,3 +303,3 @@ "VerifiablePresentation": { | ||
], | ||
"description": "Verifiable Presentation {@link https://github.com/decentralized-identity/did-jwt-vc}" | ||
"description": "Verifiable Presentation {@link https://github.com/decentralized-identifier/did-jwt-vc}" | ||
} | ||
@@ -300,0 +306,0 @@ }, |
@@ -6,3 +6,3 @@ import 'cross-fetch/polyfill' | ||
IMessage, | ||
IIdentityManager, | ||
IDIDManager, | ||
IKeyManager, | ||
@@ -33,2 +33,3 @@ IMessageHandler, | ||
} | ||
headers?: Record<string, string> | ||
} | ||
@@ -42,3 +43,3 @@ | ||
/** | ||
* This is used to create a message according to the initial {@link https://github.com/decentralized-identity/DIDComm-js | DIDComm-js} implementation. | ||
* This is used to create a message according to the initial {@link https://github.com/decentralized-identifier/DIDComm-js | DIDComm-js} implementation. | ||
* | ||
@@ -52,3 +53,3 @@ * @remarks Be advised that this spec is still not final and that this protocol may need to change. | ||
args: ISendMessageDIDCommAlpha1Args, | ||
context: IAgentContext<IIdentityManager & IKeyManager & IResolver & IMessageHandler>, | ||
context: IAgentContext<IDIDManager & IKeyManager & IResolver & IMessageHandler>, | ||
): Promise<IMessage> | ||
@@ -60,3 +61,3 @@ } | ||
* | ||
* This plugin provides a method of creating an encrypted message according to the initial {@link https://github.com/decentralized-identity/DIDComm-js | DIDComm-js} implementation. | ||
* This plugin provides a method of creating an encrypted message according to the initial {@link https://github.com/decentralized-identifier/DIDComm-js | DIDComm-js} implementation. | ||
* | ||
@@ -81,5 +82,5 @@ * @remarks Be advised that this spec is still not final and that this protocol may need to change. | ||
args: ISendMessageDIDCommAlpha1Args, | ||
context: IAgentContext<IIdentityManager & IKeyManager & IResolver & IMessageHandler>, | ||
context: IAgentContext<IDIDManager & IKeyManager & IResolver & IMessageHandler>, | ||
): Promise<IMessage> { | ||
const { data, url, save = true } = args | ||
const { data, url, headers, save = true } = args | ||
@@ -101,4 +102,4 @@ debug('Resolving didDoc') | ||
try { | ||
const identity = await context.agent.identityManagerGetIdentity({ did: data.from }) | ||
const key = identity.keys.find((k) => k.type === 'Ed25519') | ||
const identifier = await context.agent.didManagerGet({ did: data.from }) | ||
const key = identifier.keys.find((k) => k.type === 'Ed25519') | ||
if (!key) throw Error('No encryption key') | ||
@@ -125,2 +126,3 @@ const publicKey = didDoc?.publicKey.find((item) => item.type == 'Ed25519VerificationKey2018') | ||
body: postPayload, | ||
headers, | ||
}) | ||
@@ -127,0 +129,0 @@ debug('Status', res.status, res.statusText) |
@@ -1,2 +0,2 @@ | ||
import { IAgentContext, IIdentityManager, IKeyManager } from 'daf-core' | ||
import { IAgentContext, IDIDManager, IKeyManager } from 'daf-core' | ||
import { AbstractMessageHandler, Message } from 'daf-message-handler' | ||
@@ -6,3 +6,3 @@ import Debug from 'debug' | ||
type IContext = IAgentContext<IIdentityManager & IKeyManager> | ||
type IContext = IAgentContext<IDIDManager & IKeyManager> | ||
@@ -23,7 +23,7 @@ /** | ||
if (parsed.ciphertext && parsed.protected) { | ||
const identities = await context.agent.identityManagerGetIdentities() | ||
for (const identity of identities) { | ||
const identifiers = await context.agent.didManagerFind() | ||
for (const identifier of identifiers) { | ||
let decrypted | ||
try { | ||
const key = identity.keys.find((k) => k.type === 'Ed25519') | ||
const key = identifier.keys.find((k) => k.type === 'Ed25519') | ||
if (!key) throw Error('No encryption keys') | ||
@@ -33,3 +33,3 @@ decrypted = await context.agent.keyManagerDecryptJWE({ kid: key.kid, data: message.raw }) | ||
if (decrypted) { | ||
debug('Decrypted for %s', identity.did) | ||
debug('Decrypted for %s', identifier.did) | ||
debug('Message:', decrypted) | ||
@@ -36,0 +36,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
0
43678
9
528
Updateddaf-core@^7.0.0
Updateddaf-message-handler@^7.0.0