Socket
Socket
Sign inDemoInstall

@contrast/protect

Package Overview
Dependencies
Maintainers
17
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contrast/protect - npm Package Compare versions

Comparing version 1.6.0 to 1.6.1

1

lib/error-handlers/install/hapi.js

@@ -43,3 +43,2 @@ /*

const [mode, ruleId] = sourceContext.findings.securityException;
sourceContext.block('block', 'cmd-injection');

@@ -46,0 +45,0 @@ err.output.statusCode = 403;

6

lib/input-analysis/install/hapi.js

@@ -74,5 +74,5 @@ /*

if (req.cookies && Object.keys(req.cookies).length) {
sourceContext.parsedCookies = req.cookies;
inputAnalysis.handleCookies(sourceContext, req.cookies);
if (req.state && Object.keys(req.state).length) {
sourceContext.parsedCookies = req.state;
inputAnalysis.handleCookies(sourceContext, req.state);
}

@@ -79,0 +79,0 @@

@@ -46,5 +46,9 @@ /*

const evalCheck = buildEvaluationCheck(evaluation);
const keyIndex = reqHeaders.indexOf(name.toLowerCase());
const headersArray = Array.isArray(reqHeaders) ? reqHeaders : Object.entries(reqHeaders).reduce((acc, entry) => {
acc.push(...entry);
return acc;
}, []);
const keyIndex = headersArray.indexOf(name.toLowerCase());
result = keyIndex !== -1 && evalCheck(reqHeaders[keyIndex + 1], value);
result = keyIndex !== -1 && evalCheck(headersArray[keyIndex + 1], value);
if (!result) break;

@@ -51,0 +55,0 @@ }

{
"name": "@contrast/protect",
"version": "1.6.0",
"version": "1.6.1",
"description": "Contrast service providing framework-agnostic Protect support",

@@ -24,5 +24,5 @@ "license": "SEE LICENSE IN LICENSE",

"@contrast/common": "1.1.2",
"@contrast/core": "1.5.0",
"@contrast/esm-hooks": "1.1.6",
"@contrast/scopes": "1.1.1",
"@contrast/core": "1.5.1",
"@contrast/esm-hooks": "1.1.7",
"@contrast/scopes": "1.1.2",
"builtin-modules": "^3.2.0",

@@ -29,0 +29,0 @@ "ipaddr.js": "^2.0.1",

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