@icure/api 8.0.12 → 8.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"signature-keys-manager-test.js","sourceRoot":"","sources":["../../../../test/icc-x-api/crypto/signature-keys-manager-test.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,iGAA6F;AAC7F,sFAAkF;AAClF,yDAAqE;AACrE,8GAA0G;AAC1G,mEAA+D;AAC/D,iFAA6E;AAC7E,mCAAkC;AAClC,gFAA4E;AAC5E,kDAA2C;AAC3C,+BAA6B;AAC7B,2DAA+D;AAE/D,QAAQ,CAAC,sBAAsB,EAAE,GAAG,EAAE;IACpC,EAAE,CAAC,mEAAmE,EAAE,GAAS,EAAE;QACjF,MAAM,YAAY,GAAG,IAAI,uCAAkB,CAAC,IAAI,4BAAc,EAAE,EAAE,IAAI,yBAAW,EAAE,EAAE,IAAI,+DAA8B,EAAE,CAAC,CAAA;QAC1H,MAAM,UAAU,GAAG,IAAI,mCAAgB,CAAC,kBAAgB,CAAC,CAAA;QACzD,MAAM,YAAY,GAAG,IAAI,mCAAgB,CAAC,EAAE,EAAE,EAAE,UAAU,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE,qCAAiB,CAAC,GAAG,EAAE,CAAC,CAAA;QACvG,MAAM,QAAQ,GAAG,IAAI,mDAAwB,CAAC,YAAY,EAAE,YAAY,EAAE,UAAU,CAAC,CAAA;QACrF,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,2BAA2B,EAAE,CAAA;QAC1D,MAAM,QAAQ,GAAG,IAAI,mDAAwB,CAAC,YAAY,EAAE,YAAY,EAAE,UAAU,CAAC,CAAA;QACrF,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,2BAA2B,EAAE,CAAA;QAC1D,MAAM,QAAQ,GAAG,IAAA,kBAAM,EAAC,MAAM,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,KAAK,CAAC,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,CAAC,CAAA,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA","sourcesContent":["import { UserSignatureKeysManager } from '../../../icc-x-api/crypto/UserSignatureKeysManager'\nimport { IcureStorageFacade } from '../../../icc-x-api/storage/IcureStorageFacade'\nimport { TestKeyStorage, TestStorage } from '../../utils/TestStorage'\nimport { DefaultStorageEntryKeysFactory } from '../../../icc-x-api/storage/DefaultStorageEntryKeysFactory'\nimport { FakeDataOwnerApi } from '../../utils/FakeDataOwnerApi'\nimport { CryptoPrimitives } from '../../../icc-x-api/crypto/CryptoPrimitives'\nimport { webcrypto } from 'crypto'\nimport { DataOwnerTypeEnum } from '../../../icc-api/model/DataOwnerTypeEnum'\nimport { ua2hex } from '../../../icc-x-api'\nimport { expect } from 'chai'\nimport { fingerprintV1 } from '../../../icc-x-api/crypto/utils'\n\ndescribe('SignatureKeysManager', () => {\n it('should be able to store a key pair in local storage and reload it', async () => {\n const iCureStorage = new IcureStorageFacade(new TestKeyStorage(), new TestStorage(), new DefaultStorageEntryKeysFactory())\n const primitives = new CryptoPrimitives(webcrypto as any)\n const dataOwnerApi = new FakeDataOwnerApi({ id: primitives.randomUuid(), type: DataOwnerTypeEnum.Hcp })\n const manager1 = new UserSignatureKeysManager(iCureStorage, dataOwnerApi, primitives)\n const pair1 = await manager1.getOrCreateSignatureKeyPair()\n const manager2 = new UserSignatureKeysManager(iCureStorage, dataOwnerApi, primitives)\n const pair2 = await manager2.getOrCreateSignatureKeyPair()\n const private1 = ua2hex(await primitives.RSA.exportKey(pair1.keyPair.privateKey, 'pkcs8'))\n const private2 = ua2hex(await primitives.RSA.exportKey(pair2.keyPair.privateKey, 'pkcs8'))\n expect(private1).to.equal(private2)\n const public1 = ua2hex(await primitives.RSA.exportKey(pair1.keyPair.publicKey, 'spki'))\n const public2 = ua2hex(await primitives.RSA.exportKey(pair2.keyPair.publicKey, 'spki'))\n expect(public1).to.equal(public2)\n const verification1 = ua2hex(await primitives.RSA.exportKey((await manager1.getSignatureVerificationKey(fingerprintV1(public1)))!, 'spki'))\n const verification2 = ua2hex(await primitives.RSA.exportKey((await manager2.getSignatureVerificationKey(fingerprintV1(public1)))!, 'spki'))\n expect(verification1).to.equal(public1)\n expect(verification2).to.equal(public1)\n })\n})\n"]}
1
+ {"version":3,"file":"signature-keys-manager-test.js","sourceRoot":"","sources":["../../../../test/icc-x-api/crypto/signature-keys-manager-test.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,iGAA6F;AAC7F,sFAAkF;AAClF,yDAAqE;AACrE,8GAA0G;AAC1G,mEAA+D;AAC/D,iFAA6E;AAC7E,mCAAkC;AAClC,gFAA4E;AAC5E,kDAA2C;AAC3C,+BAA6B;AAC7B,2DAA8E;AAE9E,QAAQ,CAAC,sBAAsB,EAAE,GAAG,EAAE;IACpC,EAAE,CAAC,mEAAmE,EAAE,GAAS,EAAE;QACjF,MAAM,YAAY,GAAG,IAAI,uCAAkB,CAAC,IAAI,4BAAc,EAAE,EAAE,IAAI,yBAAW,EAAE,EAAE,IAAI,+DAA8B,EAAE,CAAC,CAAA;QAC1H,MAAM,UAAU,GAAG,IAAI,mCAAgB,CAAC,kBAAgB,CAAC,CAAA;QACzD,MAAM,YAAY,GAAG,IAAI,mCAAgB,CAAC,EAAE,EAAE,EAAE,UAAU,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE,qCAAiB,CAAC,GAAG,EAAE,CAAC,CAAA;QACvG,MAAM,QAAQ,GAAG,IAAI,mDAAwB,CAAC,YAAY,EAAE,YAAY,EAAE,UAAU,CAAC,CAAA;QACrF,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,2BAA2B,EAAE,CAAA;QAC1D,MAAM,QAAQ,GAAG,IAAI,mDAAwB,CAAC,YAAY,EAAE,YAAY,EAAE,UAAU,CAAC,CAAA;QACrF,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,2BAA2B,EAAE,CAAA;QAC1D,MAAM,QAAQ,GAAG,IAAA,kBAAM,EAAC,MAAM,UAAU,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,CAAC,KAAK,CAAC,OAAO,CAAC,CAAA;IACzC,CAAC,CAAA,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA","sourcesContent":["import { UserSignatureKeysManager } from '../../../icc-x-api/crypto/UserSignatureKeysManager'\nimport { IcureStorageFacade } from '../../../icc-x-api/storage/IcureStorageFacade'\nimport { TestKeyStorage, TestStorage } from '../../utils/TestStorage'\nimport { DefaultStorageEntryKeysFactory } from '../../../icc-x-api/storage/DefaultStorageEntryKeysFactory'\nimport { FakeDataOwnerApi } from '../../utils/FakeDataOwnerApi'\nimport { CryptoPrimitives } from '../../../icc-x-api/crypto/CryptoPrimitives'\nimport { webcrypto } from 'crypto'\nimport { DataOwnerTypeEnum } from '../../../icc-api/model/DataOwnerTypeEnum'\nimport { ua2hex } from '../../../icc-x-api'\nimport { expect } from 'chai'\nimport { fingerprintV1, fingerprintV2 } from '../../../icc-x-api/crypto/utils'\n\ndescribe('SignatureKeysManager', () => {\n it('should be able to store a key pair in local storage and reload it', async () => {\n const iCureStorage = new IcureStorageFacade(new TestKeyStorage(), new TestStorage(), new DefaultStorageEntryKeysFactory())\n const primitives = new CryptoPrimitives(webcrypto as any)\n const dataOwnerApi = new FakeDataOwnerApi({ id: primitives.randomUuid(), type: DataOwnerTypeEnum.Hcp })\n const manager1 = new UserSignatureKeysManager(iCureStorage, dataOwnerApi, primitives)\n const pair1 = await manager1.getOrCreateSignatureKeyPair()\n const manager2 = new UserSignatureKeysManager(iCureStorage, dataOwnerApi, primitives)\n const pair2 = await manager2.getOrCreateSignatureKeyPair()\n const private1 = ua2hex(await primitives.RSA.exportKey(pair1.keyPair.privateKey, 'pkcs8'))\n const private2 = ua2hex(await primitives.RSA.exportKey(pair2.keyPair.privateKey, 'pkcs8'))\n expect(private1).to.equal(private2)\n const public1 = ua2hex(await primitives.RSA.exportKey(pair1.keyPair.publicKey, 'spki'))\n const public2 = ua2hex(await primitives.RSA.exportKey(pair2.keyPair.publicKey, 'spki'))\n expect(public1).to.equal(public2)\n const verification1 = ua2hex(await primitives.RSA.exportKey((await manager1.getSignatureVerificationKey(fingerprintV2(public1)))!, 'spki'))\n const verification2 = ua2hex(await primitives.RSA.exportKey((await manager2.getSignatureVerificationKey(fingerprintV2(public1)))!, 'spki'))\n expect(verification1).to.equal(public1)\n expect(verification2).to.equal(public1)\n })\n})\n"]}
@@ -0,0 +1 @@
1
+ import 'isomorphic-fetch';
@@ -8,12 +8,40 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  step((generator = generator.apply(thisArg, _arguments || [])).next());
9
9
  });
10
10
  };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ const icc_x_api_1 = require("../../icc-x-api");
13
+ const crypto_1 = require("crypto");
14
+ require("isomorphic-fetch");
15
+ const test_utils_1 = require("../utils/test_utils");
16
+ const icc_api_1 = require("../../icc-api");
17
+ (0, test_utils_1.setLocalStorage)(fetch);
18
+ class DiocaneCryptoStrategies {
19
+ generateNewKeyForDataOwner(self, cryptoPrimitives) {
20
+ return Promise.resolve(false);
21
+ }
22
+ recoverAndVerifySelfHierarchyKeys(keysData, cryptoPrimitives) {
23
+ return Promise.resolve(Object.fromEntries(keysData.map(({ dataOwner }) => [dataOwner.dataOwner.id, { recoveredKeys: {}, keyAuthenticity: {} }])));
24
+ }
25
+ verifyDelegatePublicKeys(delegate, publicKeys, cryptoPrimitives) {
26
+ return Promise.resolve(publicKeys);
27
+ }
28
+ dataOwnerRequiresAnonymousDelegation(dataOwner) {
29
+ return dataOwner.type !== 'hcp';
30
+ }
31
+ }
11
32
  describe('CSM-87', function () {
12
33
  return __awaiter(this, void 0, void 0, function* () {
13
34
  it('An hcp should be able to load his key with `loadKeyPairsAsJwkInBrowserLocalStorage` and then create shamir partitions for himself', function () {
14
35
  return __awaiter(this, void 0, void 0, function* () {
15
- // This test does not apply to v7 or higher: it was a bug related to a specific method
16
- this.skip();
36
+ const api = yield icc_x_api_1.IcureApi.initialise("https://api.icure.cloud", new icc_x_api_1.JwtAuthenticationProvider(new icc_api_1.IccAuthApi("https://api.icure.cloud", {}, new icc_x_api_1.NoAuthenticationProvider(), fetch), "fabien.zimmer@medispring.be", "Ztf993pf", undefined, undefined), new DiocaneCryptoStrategies(), crypto_1.webcrypto, fetch, {
37
+ groupSelector: (availableGroupsInfo, currentGroupId) => {
38
+ const testapp = availableGroupsInfo.filter(g => { var _a; return ((_a = g.groupId) === null || _a === void 0 ? void 0 : _a.startsWith('ms-testapppatient')) == true; });
39
+ return Promise.resolve(currentGroupId);
40
+ // if (testapp.length != 1) throw new Error(`Found ${JSON.stringify(testapp)}`)
41
+ // return Promise.resolve(testapp[0].groupId!)
42
+ }
43
+ });
44
+ console.log("Hello");
17
45
  });
18
46
  });
19
47
  });
@@ -1 +1 @@
1
- {"version":3,"file":"CSM-87.js","sourceRoot":"","sources":["../../../test/support/CSM-87.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,QAAQ,CAAC,QAAQ,EAAE;;QACjB,EAAE,CAAC,mIAAmI,EAAE;;gBACtI,sFAAsF;gBACtF,IAAI,CAAC,IAAI,EAAE,CAAA;YACb,CAAC;SAAA,CAAC,CAAA;IACJ,CAAC;CAAA,CAAC,CAAA","sourcesContent":["describe('CSM-87', async function () {\n it('An hcp should be able to load his key with `loadKeyPairsAsJwkInBrowserLocalStorage` and then create shamir partitions for himself', async function () {\n // This test does not apply to v7 or higher: it was a bug related to a specific method\n this.skip()\n })\n})\n"]}
1
+ {"version":3,"file":"CSM-87.js","sourceRoot":"","sources":["../../../test/support/CSM-87.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+CAA0I;AAG1I,mCAAgC;AAChC,4BAAyB;AACzB,oDAAmD;AACnD,2CAAwC;AACxC,IAAA,4BAAe,EAAC,KAAK,CAAC,CAAA;AAEtB,MAAM,uBAAuB;IAC3B,0BAA0B,CAAC,IAAuB,EAAE,gBAAkC;QACpF,OAAO,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;IAC/B,C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F,CAAA;gBACD,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAA;YACtB,CAAC;SAAA,CAAC,CAAA;IACJ,CAAC;CAAA,CAAC,CAAA","sourcesContent":["import {CryptoPrimitives, CryptoStrategies, IcureApi, JwtAuthenticationProvider, KeyPair, NoAuthenticationProvider} from \"../../icc-x-api\"\nimport {DataOwnerWithType} from \"../../icc-api/model/DataOwnerWithType\"\nimport {CryptoActorStubWithType} from \"../../icc-api/model/CryptoActorStub\"\nimport {webcrypto} from \"crypto\"\nimport 'isomorphic-fetch'\nimport {setLocalStorage} from \"../utils/test_utils\"\nimport {IccAuthApi} from \"../../icc-api\"\nsetLocalStorage(fetch)\n\nclass DiocaneCryptoStrategies implements CryptoStrategies {\n generateNewKeyForDataOwner(self: DataOwnerWithType, cryptoPrimitives: CryptoPrimitives): Promise<KeyPair<CryptoKey> | boolean> {\n return Promise.resolve(false)\n }\n\n recoverAndVerifySelfHierarchyKeys(\n keysData: { dataOwner: DataOwnerWithType; unknownKeys: string[]; unavailableKeys: string[] }[],\n cryptoPrimitives: CryptoPrimitives\n ): Promise<{ [p: string]: { recoveredKeys: { [p: string]: KeyPair<CryptoKey> }; keyAuthenticity: { [p: string]: boolean } } }> {\n return Promise.resolve(Object.fromEntries(keysData.map(({ dataOwner }) => [dataOwner.dataOwner.id, { recoveredKeys: {}, keyAuthenticity: {} }])))\n }\n\n verifyDelegatePublicKeys(delegate: CryptoActorStubWithType, publicKeys: string[], cryptoPrimitives: CryptoPrimitives): Promise<string[]> {\n return Promise.resolve(publicKeys)\n }\n\n dataOwnerRequiresAnonymousDelegation(dataOwner: CryptoActorStubWithType): boolean {\n return dataOwner.type !== 'hcp'\n }\n}\n\n\ndescribe('CSM-87', async function () {\n it('An hcp should be able to load his key with `loadKeyPairsAsJwkInBrowserLocalStorage` and then create shamir partitions for himself', async function () {\n const api = await IcureApi.initialise(\n \"https://api.icure.cloud\",\n new JwtAuthenticationProvider(\n new IccAuthApi(\"https://api.icure.cloud\", {}, new NoAuthenticationProvider(), fetch),\n \"fabien.zimmer@medispring.be\",\n \"Ztf993pf\",\n undefined,\n undefined\n ),\n new DiocaneCryptoStrategies(),\n webcrypto as any,\n fetch,\n {\n groupSelector: (availableGroupsInfo, currentGroupId) => {\n const testapp = availableGroupsInfo.filter(g => g.groupId?.startsWith('ms-testapppatient') == true)\n return Promise.resolve(currentGroupId!)\n // if (testapp.length != 1) throw new Error(`Found ${JSON.stringify(testapp)}`)\n // return Promise.resolve(testapp[0].groupId!)\n }\n }\n )\n console.log(\"Hello\")\n })\n})\n"]}