@canton-network/core-signing-participant 1.14.0 → 1.16.0
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.
- package/dist/controller.d.ts +1 -1
- package/dist/controller.d.ts.map +1 -1
- package/dist/index.cjs +6 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -12
- package/dist/index.js.map +1 -1
- package/package.json +13 -16
package/dist/controller.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import type { AuthContext } from '@canton-network/core-wallet-auth';
|
|
|
3
3
|
export declare class ParticipantSigningDriver implements SigningDriverInterface {
|
|
4
4
|
partyMode: PartyMode;
|
|
5
5
|
signingProvider: SigningProvider;
|
|
6
|
-
controller: (_userId: AuthContext[
|
|
6
|
+
controller: (_userId: AuthContext['userId'] | undefined) => {
|
|
7
7
|
signTransaction: import("@canton-network/core-signing-lib").SignTransaction;
|
|
8
8
|
signMessage: import("@canton-network/core-signing-lib").SignMessage;
|
|
9
9
|
getTransaction: import("@canton-network/core-signing-lib").GetTransaction;
|
package/dist/controller.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"controller.d.ts","sourceRoot":"","sources":["../src/controller.ts"],"names":[],"mappings":"AAGA,OAAO,EAOH,SAAS,EAET,KAAK,sBAAsB,EAC3B,eAAe,EAKlB,MAAM,kCAAkC,CAAA;AACzC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAA;
|
|
1
|
+
{"version":3,"file":"controller.d.ts","sourceRoot":"","sources":["../src/controller.ts"],"names":[],"mappings":"AAGA,OAAO,EAOH,SAAS,EAET,KAAK,sBAAsB,EAC3B,eAAe,EAKlB,MAAM,kCAAkC,CAAA;AACzC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAA;AAEnE,qBAAa,wBAAyB,YAAW,sBAAsB;IAC5D,SAAS,YAAqB;IAC9B,eAAe,kBAA8B;IAE7C,UAAU,YAAa,WAAW,CAAC,QAAQ,CAAC,GAAG,SAAS;;;;;;;;;;MAwCzD;CACT"}
|
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
let _canton_network_core_signing_lib = require("@canton-network/core-signing-lib");
|
|
3
|
-
|
|
4
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/typeof.js
|
|
3
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/typeof.js
|
|
5
4
|
function _typeof(o) {
|
|
6
5
|
"@babel/helpers - typeof";
|
|
7
6
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
@@ -10,8 +9,7 @@ function _typeof(o) {
|
|
|
10
9
|
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
11
10
|
}, _typeof(o);
|
|
12
11
|
}
|
|
13
|
-
|
|
14
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/toPrimitive.js
|
|
12
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/toPrimitive.js
|
|
15
13
|
function toPrimitive(t, r) {
|
|
16
14
|
if ("object" != _typeof(t) || !t) return t;
|
|
17
15
|
var e = t[Symbol.toPrimitive];
|
|
@@ -22,14 +20,12 @@ function toPrimitive(t, r) {
|
|
|
22
20
|
}
|
|
23
21
|
return ("string" === r ? String : Number)(t);
|
|
24
22
|
}
|
|
25
|
-
|
|
26
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/toPropertyKey.js
|
|
23
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/toPropertyKey.js
|
|
27
24
|
function toPropertyKey(t) {
|
|
28
25
|
var i = toPrimitive(t, "string");
|
|
29
26
|
return "symbol" == _typeof(i) ? i : i + "";
|
|
30
27
|
}
|
|
31
|
-
|
|
32
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/defineProperty.js
|
|
28
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/defineProperty.js
|
|
33
29
|
function _defineProperty(e, r, t) {
|
|
34
30
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
35
31
|
value: t,
|
|
@@ -38,8 +34,7 @@ function _defineProperty(e, r, t) {
|
|
|
38
34
|
writable: !0
|
|
39
35
|
}) : e[r] = t, e;
|
|
40
36
|
}
|
|
41
|
-
|
|
42
|
-
//#region src/controller.ts
|
|
37
|
+
// src/controller.ts
|
|
43
38
|
var ParticipantSigningDriver = class {
|
|
44
39
|
constructor() {
|
|
45
40
|
_defineProperty(this, "partyMode", _canton_network_core_signing_lib.PartyMode.INTERNAL);
|
|
@@ -47,7 +42,7 @@ var ParticipantSigningDriver = class {
|
|
|
47
42
|
_defineProperty(this, "controller", (_userId) => (0, _canton_network_core_signing_lib.buildController)({
|
|
48
43
|
signTransaction: async (params) => {
|
|
49
44
|
return Promise.resolve({
|
|
50
|
-
txId: params.internalTxId ||
|
|
45
|
+
txId: params.internalTxId || crypto.randomUUID(),
|
|
51
46
|
status: "signed",
|
|
52
47
|
signature: "none"
|
|
53
48
|
});
|
|
@@ -82,7 +77,6 @@ var ParticipantSigningDriver = class {
|
|
|
82
77
|
}));
|
|
83
78
|
}
|
|
84
79
|
};
|
|
85
|
-
//#endregion
|
|
86
80
|
exports.ParticipantSigningDriver = ParticipantSigningDriver;
|
|
87
81
|
|
|
88
82
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":["PartyMode","SigningProvider","buildController"
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["PartyMode","SigningProvider","buildController"],"sources":["../src/controller.ts"],"sourcesContent":["// Copyright (c) 2025-2026 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport {\n buildController,\n type CreateKeyResult,\n type GetConfigurationResult,\n type GetKeysResult,\n type GetTransactionResult,\n type GetTransactionsResult,\n PartyMode,\n type SetConfigurationResult,\n type SigningDriverInterface,\n SigningProvider,\n type SignMessageResult,\n type SignTransactionParams,\n type SignTransactionResult,\n type SubscribeTransactionsResult,\n} from '@canton-network/core-signing-lib'\nimport type { AuthContext } from '@canton-network/core-wallet-auth'\n\nexport class ParticipantSigningDriver implements SigningDriverInterface {\n public partyMode = PartyMode.INTERNAL\n public signingProvider = SigningProvider.PARTICIPANT\n\n public controller = (_userId: AuthContext['userId'] | undefined) =>\n buildController({\n signTransaction: async (\n params: SignTransactionParams\n ): Promise<SignTransactionResult> => {\n return Promise.resolve({\n txId: params.internalTxId || crypto.randomUUID(),\n status: 'signed',\n signature: 'none',\n })\n },\n signMessage: async (): Promise<SignMessageResult> => {\n return Promise.resolve({\n error: 'not_allowed',\n error_description:\n 'Signing messages is not supported with Participant.',\n })\n },\n getTransaction: function (): Promise<GetTransactionResult> {\n throw new Error('Function not implemented.')\n },\n getTransactions: function (): Promise<GetTransactionsResult> {\n throw new Error('Function not implemented.')\n },\n getKeys: function (): Promise<GetKeysResult> {\n throw new Error('Function not implemented.')\n },\n createKey: function (): Promise<CreateKeyResult> {\n throw new Error('Function not implemented.')\n },\n getConfiguration: function (): Promise<GetConfigurationResult> {\n throw new Error('Function not implemented.')\n },\n setConfiguration: function (): Promise<SetConfigurationResult> {\n throw new Error('Function not implemented.')\n },\n subscribeTransactions:\n function (): Promise<SubscribeTransactionsResult> {\n throw new Error('Function not implemented.')\n },\n })\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,IAAa,2BAAb,MAAwE;;EAC7D,gBAAA,MAAA,aAAYA,iCAAAA,UAAU,QAAA;EACtB,gBAAA,MAAA,mBAAkBC,iCAAAA,gBAAgB,WAAA;EAElC,gBAAA,MAAA,eAAc,aAAA,GACjBC,iCAAAA,gBAAAA,CAAgB;GACZ,iBAAiB,OACb,WACiC;IACjC,OAAO,QAAQ,QAAQ;KACnB,MAAM,OAAO,gBAAgB,OAAO,WAAW;KAC/C,QAAQ;KACR,WAAW;IACf,CAAC;GACL;GACA,aAAa,YAAwC;IACjD,OAAO,QAAQ,QAAQ;KACnB,OAAO;KACP,mBACI;IACR,CAAC;GACL;GACA,gBAAgB,WAA2C;IACvD,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,iBAAiB,WAA4C;IACzD,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,SAAS,WAAoC;IACzC,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,WAAW,WAAsC;IAC7C,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,kBAAkB,WAA6C;IAC3D,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,kBAAkB,WAA6C;IAC3D,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,uBACI,WAAkD;IAC9C,MAAM,IAAI,MAAM,2BAA2B;GAC/C;EACR,CAAC,CAAA;;AACT"}
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { PartyMode, SigningProvider, buildController } from "@canton-network/core-signing-lib";
|
|
2
|
-
|
|
3
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/typeof.js
|
|
2
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/typeof.js
|
|
4
3
|
function _typeof(o) {
|
|
5
4
|
"@babel/helpers - typeof";
|
|
6
5
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
@@ -9,8 +8,7 @@ function _typeof(o) {
|
|
|
9
8
|
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
10
9
|
}, _typeof(o);
|
|
11
10
|
}
|
|
12
|
-
|
|
13
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/toPrimitive.js
|
|
11
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/toPrimitive.js
|
|
14
12
|
function toPrimitive(t, r) {
|
|
15
13
|
if ("object" != _typeof(t) || !t) return t;
|
|
16
14
|
var e = t[Symbol.toPrimitive];
|
|
@@ -21,14 +19,12 @@ function toPrimitive(t, r) {
|
|
|
21
19
|
}
|
|
22
20
|
return ("string" === r ? String : Number)(t);
|
|
23
21
|
}
|
|
24
|
-
|
|
25
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/toPropertyKey.js
|
|
22
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/toPropertyKey.js
|
|
26
23
|
function toPropertyKey(t) {
|
|
27
24
|
var i = toPrimitive(t, "string");
|
|
28
25
|
return "symbol" == _typeof(i) ? i : i + "";
|
|
29
26
|
}
|
|
30
|
-
|
|
31
|
-
//#region \0@oxc-project+runtime@0.153.0/helpers/esm/defineProperty.js
|
|
27
|
+
// \0@oxc-project+runtime@0.155.0/helpers/esm/defineProperty.js
|
|
32
28
|
function _defineProperty(e, r, t) {
|
|
33
29
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
34
30
|
value: t,
|
|
@@ -37,8 +33,7 @@ function _defineProperty(e, r, t) {
|
|
|
37
33
|
writable: !0
|
|
38
34
|
}) : e[r] = t, e;
|
|
39
35
|
}
|
|
40
|
-
|
|
41
|
-
//#region src/controller.ts
|
|
36
|
+
// src/controller.ts
|
|
42
37
|
var ParticipantSigningDriver = class {
|
|
43
38
|
constructor() {
|
|
44
39
|
_defineProperty(this, "partyMode", PartyMode.INTERNAL);
|
|
@@ -46,7 +41,7 @@ var ParticipantSigningDriver = class {
|
|
|
46
41
|
_defineProperty(this, "controller", (_userId) => buildController({
|
|
47
42
|
signTransaction: async (params) => {
|
|
48
43
|
return Promise.resolve({
|
|
49
|
-
txId: params.internalTxId || randomUUID(),
|
|
44
|
+
txId: params.internalTxId || crypto.randomUUID(),
|
|
50
45
|
status: "signed",
|
|
51
46
|
signature: "none"
|
|
52
47
|
});
|
|
@@ -81,7 +76,6 @@ var ParticipantSigningDriver = class {
|
|
|
81
76
|
}));
|
|
82
77
|
}
|
|
83
78
|
};
|
|
84
|
-
//#endregion
|
|
85
79
|
export { ParticipantSigningDriver };
|
|
86
80
|
|
|
87
81
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/controller.ts"],"sourcesContent":["// Copyright (c) 2025-2026 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport {\n buildController,\n type CreateKeyResult,\n type GetConfigurationResult,\n type GetKeysResult,\n type GetTransactionResult,\n type GetTransactionsResult,\n PartyMode,\n type SetConfigurationResult,\n type SigningDriverInterface,\n SigningProvider,\n type SignMessageResult,\n type SignTransactionParams,\n type SignTransactionResult,\n type SubscribeTransactionsResult,\n} from '@canton-network/core-signing-lib'\nimport type { AuthContext } from '@canton-network/core-wallet-auth'\
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/controller.ts"],"sourcesContent":["// Copyright (c) 2025-2026 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport {\n buildController,\n type CreateKeyResult,\n type GetConfigurationResult,\n type GetKeysResult,\n type GetTransactionResult,\n type GetTransactionsResult,\n PartyMode,\n type SetConfigurationResult,\n type SigningDriverInterface,\n SigningProvider,\n type SignMessageResult,\n type SignTransactionParams,\n type SignTransactionResult,\n type SubscribeTransactionsResult,\n} from '@canton-network/core-signing-lib'\nimport type { AuthContext } from '@canton-network/core-wallet-auth'\n\nexport class ParticipantSigningDriver implements SigningDriverInterface {\n public partyMode = PartyMode.INTERNAL\n public signingProvider = SigningProvider.PARTICIPANT\n\n public controller = (_userId: AuthContext['userId'] | undefined) =>\n buildController({\n signTransaction: async (\n params: SignTransactionParams\n ): Promise<SignTransactionResult> => {\n return Promise.resolve({\n txId: params.internalTxId || crypto.randomUUID(),\n status: 'signed',\n signature: 'none',\n })\n },\n signMessage: async (): Promise<SignMessageResult> => {\n return Promise.resolve({\n error: 'not_allowed',\n error_description:\n 'Signing messages is not supported with Participant.',\n })\n },\n getTransaction: function (): Promise<GetTransactionResult> {\n throw new Error('Function not implemented.')\n },\n getTransactions: function (): Promise<GetTransactionsResult> {\n throw new Error('Function not implemented.')\n },\n getKeys: function (): Promise<GetKeysResult> {\n throw new Error('Function not implemented.')\n },\n createKey: function (): Promise<CreateKeyResult> {\n throw new Error('Function not implemented.')\n },\n getConfiguration: function (): Promise<GetConfigurationResult> {\n throw new Error('Function not implemented.')\n },\n setConfiguration: function (): Promise<SetConfigurationResult> {\n throw new Error('Function not implemented.')\n },\n subscribeTransactions:\n function (): Promise<SubscribeTransactionsResult> {\n throw new Error('Function not implemented.')\n },\n })\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,IAAa,2BAAb,MAAwE;;EAC7D,gBAAA,MAAA,aAAY,UAAU,QAAA;EACtB,gBAAA,MAAA,mBAAkB,gBAAgB,WAAA;EAElC,gBAAA,MAAA,eAAc,YACjB,gBAAgB;GACZ,iBAAiB,OACb,WACiC;IACjC,OAAO,QAAQ,QAAQ;KACnB,MAAM,OAAO,gBAAgB,OAAO,WAAW;KAC/C,QAAQ;KACR,WAAW;IACf,CAAC;GACL;GACA,aAAa,YAAwC;IACjD,OAAO,QAAQ,QAAQ;KACnB,OAAO;KACP,mBACI;IACR,CAAC;GACL;GACA,gBAAgB,WAA2C;IACvD,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,iBAAiB,WAA4C;IACzD,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,SAAS,WAAoC;IACzC,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,WAAW,WAAsC;IAC7C,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,kBAAkB,WAA6C;IAC3D,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,kBAAkB,WAA6C;IAC3D,MAAM,IAAI,MAAM,2BAA2B;GAC/C;GACA,uBACI,WAAkD;IAC9C,MAAM,IAAI,MAAM,2BAA2B;GAC/C;EACR,CAAC,CAAA;;AACT"}
|
package/package.json
CHANGED
|
@@ -1,34 +1,31 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@canton-network/core-signing-participant",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.16.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Wallet Gateway driver for Canton participant internal parties",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"sideEffects": false,
|
|
8
8
|
"main": "dist/index.cjs",
|
|
9
9
|
"module": "dist/index.js",
|
|
10
|
-
"types": "dist/
|
|
10
|
+
"types": "dist/index.d.ts",
|
|
11
11
|
"exports": {
|
|
12
12
|
".": {
|
|
13
|
-
"types": "./dist/
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
14
|
"import": "./dist/index.js",
|
|
15
15
|
"require": "./dist/index.cjs",
|
|
16
16
|
"default": "./dist/index.js"
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@canton-network/core-
|
|
21
|
-
"@canton-network/core-
|
|
22
|
-
"@canton-network/core-wallet-auth": "1.14.0"
|
|
20
|
+
"@canton-network/core-signing-lib": "1.16.0",
|
|
21
|
+
"@canton-network/core-wallet-auth": "2.2.0"
|
|
23
22
|
},
|
|
24
23
|
"devDependencies": {
|
|
25
|
-
"@types/
|
|
26
|
-
"@
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"typescript": "^6.0.3",
|
|
31
|
-
"vitest": "^5.0.1"
|
|
24
|
+
"@types/node": "^25.9.9",
|
|
25
|
+
"@vitest/coverage-v8": "^5.0.5",
|
|
26
|
+
"tsdown": "^0.23.2",
|
|
27
|
+
"typescript": "npm:@typescript/typescript6@^6.0.2",
|
|
28
|
+
"vitest": "^5.0.5"
|
|
32
29
|
},
|
|
33
30
|
"files": [
|
|
34
31
|
"dist/**"
|
|
@@ -46,9 +43,9 @@
|
|
|
46
43
|
"url": "https://github.com/canton-network/wallet/issues"
|
|
47
44
|
},
|
|
48
45
|
"scripts": {
|
|
49
|
-
"build": "tsdown --onSuccess \"tsc\"",
|
|
50
|
-
"dev": "tsdown --watch --onSuccess \"tsc\"",
|
|
51
|
-
"clean": "
|
|
46
|
+
"build": "tsdown --onSuccess \"tsc -p tsconfig.lib.json\"",
|
|
47
|
+
"dev": "tsdown --watch --onSuccess \"tsc -p tsconfig.lib.json\"",
|
|
48
|
+
"clean": "rm -rf dist",
|
|
52
49
|
"flatpack": "pnpm pack --pack-destination \"$FLATPACK_OUTDIR\""
|
|
53
50
|
}
|
|
54
51
|
}
|