Socket
Socket
Sign inDemoInstall

@metamask/eth-sig-util

Package Overview
Dependencies
Maintainers
7
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@metamask/eth-sig-util - npm Package Compare versions

Comparing version 4.0.0 to 4.0.1

8

CHANGELOG.md

@@ -9,2 +9,7 @@ # Changelog

## [4.0.1]
### Fixed
- Fix mistake in TYPED_MESSAGE_SCHEMA ([#243](https://github.com/MetaMask/eth-sig-util/pull/243))
- The schema changed in v4 in a way that accidentally disallowed "reference types" (i.e. custom types) apart from the primary type. Reference types are now once again allowed.
## [4.0.0]

@@ -86,3 +91,4 @@ ### Added

[Unreleased]: https://github.com/MetaMask/eth-sig-util/compare/v4.0.0...HEAD
[Unreleased]: https://github.com/MetaMask/eth-sig-util/compare/v4.0.1...HEAD
[4.0.1]: https://github.com/MetaMask/eth-sig-util/compare/v4.0.0...v4.0.1
[4.0.0]: https://github.com/MetaMask/eth-sig-util/compare/v3.0.1...v4.0.0

@@ -89,0 +95,0 @@ [3.0.1]: https://github.com/MetaMask/eth-sig-util/compare/v3.0.0...v3.0.1

1

dist/sign-typed-data.d.ts

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

type: string;
enum: string[];
};

@@ -89,0 +88,0 @@ };

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

name: { type: 'string' },
type: { type: 'string', enum: getSolidityTypes() },
type: { type: 'string' },
},

@@ -49,14 +49,2 @@ required: ['name', 'type'],

/**
* Get a list of all Solidity types.
*
* @returns A list of all Solidity types.
*/
function getSolidityTypes() {
const types = ['bool', 'address', 'string', 'bytes'];
const ints = Array.from(new Array(32)).map((_, index) => `int${(index + 1) * 8}`);
const uints = Array.from(new Array(32)).map((_, index) => `uint${(index + 1) * 8}`);
const bytes = Array.from(new Array(32)).map((_, index) => `bytes${index + 1}`);
return [...types, ...ints, ...uints, ...bytes];
}
/**
* Validate that the given value is a valid version string.

@@ -63,0 +51,0 @@ *

{
"name": "@metamask/eth-sig-util",
"version": "4.0.0",
"version": "4.0.1",
"description": "A few useful functions for signing ethereum data",

@@ -57,6 +57,6 @@ "keywords": [

"@metamask/auto-changelog": "^2.4.0",
"@metamask/eslint-config": "^7.0.1",
"@metamask/eslint-config-jest": "^7.0.0",
"@metamask/eslint-config-nodejs": "^7.0.0",
"@metamask/eslint-config-typescript": "^7.0.1",
"@metamask/eslint-config": "^9.0.0",
"@metamask/eslint-config-jest": "^9.0.0",
"@metamask/eslint-config-nodejs": "^9.0.0",
"@metamask/eslint-config-typescript": "^9.0.1",
"@types/jest": "^26.0.24",

@@ -66,2 +66,3 @@ "@types/node": "^14.14.25",

"@typescript-eslint/parser": "^4.28.2",
"ajv": "^8.11.0",
"eslint": "^7.30.0",

@@ -68,0 +69,0 @@ "eslint-config-prettier": "^8.3.0",

Sorry, the diff of this file is not supported yet

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