New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@dfns/blockchain-integration

Package Overview
Dependencies
Maintainers
4
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dfns/blockchain-integration - npm Package Compare versions

Comparing version 2.4.4 to 2.5.0

5

lib/signing-group/index.d.ts

@@ -0,2 +1,7 @@

import { ApiClient } from '../api-client/api-client';
export { SigningGroup } from "./SigningGroup";
export { SigningGroupNotInitializedError } from "./SigningGroupNotInitializedError";
export declare function createSigningGroup(t: number, n: number, apiClient: ApiClient, groupId?: string): Promise<{
groupId: string;
walletId: string;
}>;

9

lib/signing-group/index.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.SigningGroupNotInitializedError = exports.SigningGroup = void 0;
exports.createSigningGroup = exports.SigningGroupNotInitializedError = exports.SigningGroup = void 0;
var SigningGroup_1 = require("./SigningGroup");

@@ -8,1 +8,8 @@ Object.defineProperty(exports, "SigningGroup", { enumerable: true, get: function () { return SigningGroup_1.SigningGroup; } });

Object.defineProperty(exports, "SigningGroupNotInitializedError", { enumerable: true, get: function () { return SigningGroupNotInitializedError_1.SigningGroupNotInitializedError; } });
async function createSigningGroup(t, n, apiClient, groupId = 'one') {
const { data: { id: walletId } } = await apiClient.post(`groups/${groupId}/keygen`, {
body: { parties: n.toString(), threshold: t.toString() },
});
return { groupId, walletId };
}
exports.createSigningGroup = createSigningGroup;

2

lib/signing-group/SigningGroup.d.ts

@@ -11,3 +11,3 @@ /// <reference types="node" />

getPublicKeyAsync(asHex: boolean): Promise<Buffer>;
sign(hash: Buffer): Promise<any>;
sign(message: Buffer): Promise<any>;
}

@@ -61,4 +61,4 @@ "use strict";

}
async sign(hash) {
const message = hash.toString("hex");
async sign(message) {
// do not convert to string as JSON.stringify() converts it one more time
const { data } = await __classPrivateFieldGet(this, _SigningGroup_api, "f").post(`groups/${__classPrivateFieldGet(this, _SigningGroup_groupId, "f")}/sign/${__classPrivateFieldGet(this, _SigningGroup_walletId, "f")}`, {

@@ -65,0 +65,0 @@ body: { message },

{
"name": "@dfns/blockchain-integration",
"version": "2.4.4",
"version": "2.5.0",
"description": "Blockchain integration Kit for DFNS",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc