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

restringer

Package Overview
Dependencies
Maintainers
2
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

restringer - npm Package Compare versions

Comparing version 1.5.2 to 1.5.3

2

package.json
{
"name": "restringer",
"version": "1.5.2",
"version": "1.5.3",
"description": "Deobfuscate Javascript with emphasis on reconstructing strings",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -37,2 +37,8 @@ const logger = require(__dirname + '/logger');

};
} else if (Object.is(value, -0)) {
newNode = {
type: 'UnaryExpression',
operator: '-',
argument: createNewNode(0),
};
} else {

@@ -39,0 +45,0 @@ newNode = {

@@ -0,0 +0,0 @@ /*

@@ -156,4 +156,4 @@ const {generateFlatAST} = require('flast');

func: __dirname + '/../src/modules/safe/replaceEvalCallsWithLiteralContent',
source: `function q() {return (eval('a; b;'));}`,
expected: `function q() {\n return {\n a;\n b;\n };\n}`,
source: `function q() {return (eval('a, b;'));}`,
expected: `function q() {\n return a, b;\n}`,
},

@@ -653,4 +653,4 @@ {

func: __dirname + '/../src/modules/unsafe/resolveMinimalAlphabet',
source: `+true; -true; +false; +[]; ~true; ~false; ~[]; +[3]; +['']; -[4]; ![]; +[[]];`,
expected: `1;\n-'1';\n0;\n0;\n-'2';\n-'1';\n-'1';\n3;\n0;\n-'4';\nfalse;\n0;`,
source: `+true; -true; +false; -false; +[]; ~true; ~false; ~[]; +[3]; +['']; -[4]; ![]; +[[]];`,
expected: `1;\n-'1';\n0;\n-0;\n0;\n-'2';\n-'1';\n-'1';\n3;\n0;\n-'4';\nfalse;\n0;`,
},

@@ -669,3 +669,3 @@ {

source: `-false; -[]; +{}; -{}; -'a'; ~{}; -['']; +[1, 2]; +this; +[this];`,
expected: `-false;\n-[];\n+{};\n-{};\nNaN;\n~{};\n-[''];\nNaN;\n+this;\n+[this];`,
expected: `-0;\n-0;\n+{};\n-{};\nNaN;\n~{};\n-0;\nNaN;\n+this;\n+[this];`,
},

@@ -672,0 +672,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