Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@dfns/blockchain-integration

Package Overview
Dependencies
Maintainers
2
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 1.1.0 to 1.1.1

3

lib/signing-group/signing-group.d.ts

@@ -7,5 +7,6 @@ /// <reference types="node" />

getPublicKey(): Buffer;
getPublicKeyAsync(asHex?: boolean): Promise<Buffer>;
getPublicKeyAsHex(): Buffer;
getPublicKeyAsync(asHex: boolean): Promise<Buffer>;
sign(hash: Buffer): Promise<any>;
}
export declare function createSigningGroup(t: number, n: number): Promise<string>;

@@ -18,3 +18,3 @@ "use strict";

};
var _groupId, _publicKey, _isInitialized;
var _groupId, _publicKey, _publicKeyAsHex, _isInitialized;
Object.defineProperty(exports, "__esModule", { value: true });

@@ -29,2 +29,3 @@ exports.createSigningGroup = exports.SigningGroup = void 0;

_publicKey.set(this, void 0);
_publicKeyAsHex.set(this, void 0);
_isInitialized.set(this, void 0);

@@ -35,3 +36,4 @@ __classPrivateFieldSet(this, _groupId, groupId);

async init() {
__classPrivateFieldSet(this, _publicKey, await this.getPublicKeyAsync());
__classPrivateFieldSet(this, _publicKeyAsHex, await this.getPublicKeyAsync(true));
__classPrivateFieldSet(this, _publicKey, await this.getPublicKeyAsync(false));
__classPrivateFieldSet(this, _isInitialized, true);

@@ -45,3 +47,9 @@ }

}
async getPublicKeyAsync(asHex = true) {
getPublicKeyAsHex() {
if (!__classPrivateFieldGet(this, _isInitialized)) {
throw new SigningGroupNotInitializedError_1.SigningGroupNotInitializedError();
}
return __classPrivateFieldGet(this, _publicKeyAsHex);
}
async getPublicKeyAsync(asHex) {
const res = await node_fetch_1.default(`${API_URL}/groups/${__classPrivateFieldGet(this, _groupId)}/config`, {

@@ -74,3 +82,3 @@ headers: {

exports.SigningGroup = SigningGroup;
_groupId = new WeakMap(), _publicKey = new WeakMap(), _isInitialized = new WeakMap();
_groupId = new WeakMap(), _publicKey = new WeakMap(), _publicKeyAsHex = new WeakMap(), _isInitialized = new WeakMap();
async function createSigningGroup(t, n) {

@@ -100,4 +108,4 @@ const res = await node_fetch_1.default(`${API_URL}/start`, {

return new Promise((resolve) => {
setTimeout(() => resolve(true), ms);
setTimeout(resolve, ms);
});
};
{
"name": "@dfns/blockchain-integration",
"version": "1.1.0",
"version": "1.1.1",
"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