New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

did-auth-lowversion

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

did-auth-lowversion

const finDID = require('did-auth-lowversion');

latest
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

const finDID = require('did-auth-lowversion');

async function test() {

const privateKey = 'your publicKey'; const data = {'key1':'value1', 'key2':'value2'}; const JsonData = JSON.stringify(data); const keyType = 'EcdsaSecp256k1RecoveryMethod2020 or 2019' /* findid sign */ const signature = await finDID.sign(JsonData, keyType, privateKey)

const authInfo = { 'did':'did:kt:...', 'pubKeyID':'did:kt:..#key-..', 'pubKey':{'keyType':'EcdsaSecp256k1RecoveryMethod2020 or 2019','pubKeyData':'your publicKey'},
'signature': signature.signature, 'data':JsonData };

/* findid auth */ const isValid = await finDID.didAuth(authInfo.pubKey,authInfo.signature,authInfo.data); console.log(isValid); }

test();

FAQs

Package last updated on 22 Apr 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts