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

eosjs

Package Overview
Dependencies
Maintainers
1
Versions
292
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eosjs - npm Package Compare versions

Comparing version 1.4.0 to 1.4.1

8

package.json
{
"name": "eosjs",
"version": "1.4.0",
"version": "1.4.1",
"description": "General purpose library for the EOS blockchain.",

@@ -20,3 +20,3 @@ "main": "index.js",

"author": "",
"license": "ISC",
"license": "MIT",
"bugs": {

@@ -34,4 +34,4 @@ "url": "https://github.com/EOSIO/eosjs/issues"

"create-hash": "^1.1.3",
"eosjs-api": "^1.2.2",
"eosjs-ecc": "^1.2.0",
"eosjs-api": "^1.2.3",
"eosjs-ecc": "^1.3.2",
"eosjs-json": "^1.3.0",

@@ -38,0 +38,0 @@ "fcbuffer": "^1.2.0"

@@ -39,2 +39,4 @@ [![Build Status](https://travis-ci.org/EOSIO/eosjs.svg?branch=master)](https://travis-ci.org/EOSIO/eosjs)

Read-only API methods and documentation are generated from [chain.json](https://github.com/EOSIO/eosjs-json/blob/master/api/v1/chain.json).
### Usage (read/write)

@@ -61,2 +63,4 @@

Read-write API methods and documentation are generated from this [schema](https://github.com/EOSIO/eosjs-json/blob/master/schema/generated.json).
For more advanced signing, see `keyProvider` in the [unit test](./index.test.js).

@@ -63,0 +67,0 @@

@@ -8,3 +8,3 @@ const ecc = require('eosjs-ecc')

const {Signature} = ecc
const {sign} = ecc

@@ -222,20 +222,2 @@ function writeApiGen(Network, network, structs, config) {

/**
The transaction function signs already. This is for signing other types
of data.
@arg {string|Buffer} data - Never sign anything without 100% validation or
unless prefixing with a string constant.
@arg {string|ecc.PrivateKey} key - string must be a valid WIF format
@return {string} hex signature
*/
function sign(data, key) {
const privateKey = key.d ? key : ecc.PrivateKey.fromWif(key)
const h = createHash('sha256').update(data).digest();
const sig = Signature.signBufferSha256(h, privateKey)
return sig.toHex()
}
const checkError = (parentErr, parrentRes) => (error, result) => {

@@ -242,0 +224,0 @@ if (error) {

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