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

module-keys

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

module-keys - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

9

index.js

@@ -170,3 +170,3 @@ /**

* an approved unboxer.
* @param {function(function():boolean):boolean} mayOpen
* @param {!function(function():boolean):boolean} mayOpen
* receives the public key of the opener.

@@ -196,3 +196,3 @@ * Should return `true` to allow.

* @param {*} box the box to unbox.
* @param {function(function():boolean):boolean} ifFrom
* @param {?function(function():boolean):boolean} ifFrom
* if the box may be opened by this unboxer's owner,

@@ -206,2 +206,5 @@ * then ifFrom receives the publicKey of the box creator.

function unbox(box, ifFrom, fallback) { // eslint-disable-line no-shadow
if (ifFrom == null) { // eslint-disable-line
ifFrom = () => true;
}
if (typeof ifFrom !== 'function') {

@@ -229,3 +232,3 @@ throw new Error(`Expected function not ${ ifFrom }`);

* @param {*} box the box to unbox.
* @param {function(function():boolean):boolean} ifFrom
* @param {?function(function():boolean):boolean} ifFrom
* if the box may be opened by this unboxer's owner,

@@ -232,0 +235,0 @@ * then ifFrom receives the publicKey of the box creator.

{
"name": "module-keys",
"description": "Module identity as a basis for privilege separation for ESM & CommonJS modules",
"version": "1.0.3",
"version": "1.0.4",
"keywords": [

@@ -6,0 +6,0 @@ "design-patterns",

@@ -10,2 +10,3 @@ # Module Keys

[![Coverage Status](https://coveralls.io/repos/github/mikesamuel/module-keys/badge.svg?branch=master)](https://coveralls.io/github/mikesamuel/module-keys?branch=master)
[![Known Vulnerabilities](https://snyk.io/test/github/mikesamuel/module-keys/badge.svg?targetFile=package.json)](https://snyk.io/test/github/mikesamuel/module-keys?targetFile=package.json)

@@ -12,0 +13,0 @@ * [Why Module Keys?](#why-module-keys)

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