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

@metamask/utils

Package Overview
Dependencies
Maintainers
9
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@metamask/utils - npm Package Compare versions

Comparing version 6.0.0 to 6.0.1

7

CHANGELOG.md

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

## [6.0.1]
### Fixed
- Strip `__proto__` and `constructor` JSON properties in `getSafeJson` ([#105](https://github.com/MetaMask/utils/pull/105))
## [6.0.0]

@@ -154,3 +158,4 @@ ### Changed

[Unreleased]: https://github.com/MetaMask/utils/compare/v6.0.0...HEAD
[Unreleased]: https://github.com/MetaMask/utils/compare/v6.0.1...HEAD
[6.0.1]: https://github.com/MetaMask/utils/compare/v6.0.0...v6.0.1
[6.0.0]: https://github.com/MetaMask/utils/compare/v5.0.2...v6.0.0

@@ -157,0 +162,0 @@ [5.0.2]: https://github.com/MetaMask/utils/compare/v5.0.1...v5.0.2

@@ -37,3 +37,9 @@ "use strict";

(0, assert_1.assertStruct)(value, exports.UnsafeJsonStruct);
return JSON.parse(JSON.stringify(value));
return JSON.parse(JSON.stringify(value, (propKey, propValue) => {
// Strip __proto__ and constructor properties to prevent prototype pollution.
if (propKey === '__proto__' || propKey === 'constructor') {
return undefined;
}
return propValue;
}));
});

@@ -40,0 +46,0 @@ /**

2

package.json
{
"name": "@metamask/utils",
"version": "6.0.0",
"version": "6.0.1",
"description": "Various JavaScript/TypeScript utilities of wide relevance to the MetaMask codebase",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/MetaMask/utils#readme",

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