依赖 isolated-vm,官方不建议使用奇数版本 Node.js,需用 22 或 24;README 未说明其他依赖或端口要求。
webcrack
j4k0xbMIT活跃维护把 obfuscator.io 混淆过的 JavaScript 还原成可读代码,同时解包 browserify 等打包产物并格式化压缩代码,方便逆向分析前端逻辑。
Deobfuscate obfuscator.io, unminify and unpack bundled javascript
npm install -g webcrack@latest
webcrack input.js > output.jsREADME 未说明;仅要求 Node.js 22 或 24,不涉及 GPU 或显存。
反混淆 obfuscator.io 代码、还原 webpack/browserify 打包的 JavaScript 逆向工具
把 obfuscator.io 混淆过的 JavaScript 还原成可读代码,同时解包 browserify 等打包产物并格式化压缩代码,方便逆向分析前端逻辑。
核心能力
- 反混淆 obfuscator.io 生成的代码
- 还原 webpack 与 browserify 打包产物
- 自动识别代码模式,无需额外配置
- 去混淆时考虑变量引用与作用域
- 去除混淆器和打包器留下的痕迹
容易踩的坑
- v2.16.0最新正式版2026-04-25 · 2026-04-25 16:34 UTC
🚨 Breaking Changes
- Node 18 and 20 is no longer supported. Requires Node 22 or 24.
Plugin API for manipulating the AST
See https://webcrack.netlify.app/docs/guide/api.html#plugins
Unpack Bundle
- Detect more browserify variations. (#142)
- Detect more webpack variations. (#145)
Unminify
- Truncate number literal in binary expressions with bitwise operators. (#168)
- Fix incorrect binding in split-for-loop-vars. (#188)
- Transform string literal in template expression. (#191)
Deobfuscate
- Return early if no decoder calls found. (#203)
JSX
- Detect indirect calls:
(0, r.jsx)("div", {})-><div />. (#10) - Detect jsx/jsxs in object:
r.jsxs(...). (#175)
Mangle
- Mangle with additional sources for init names. (#155)
- Mangle catch clause identifiers. (#156)
- Change string limit from 100 to 20. (#167)
- v2.15.12025-02-27 · 2025-02-27 17:32 UTC
查看更新说明
Deobfuscate
- Fix: Don't inline objects into function etc
- Fix: Avoid false positives when detecting read-only object accesses
- Fix: inline function call with too few args (#139)
Unpack Bundle
- Fix error when output directory has a trailing slash (#141)
Playground
- Download zip (#130)
- Add setting for word wrap and sticky scroll
- v2.15.02024-12-05 · 2024-12-05 19:43 UTC
查看更新说明
General
- CommonJS support: now
require("webcrack")also works without errors
Deobfuscate
- Evaluate
atob,unescape,decodeURIanddecodeURIComponentcalls (#53) - Inline variable with multiple assignments (#121)
- Log original string array name, length and decoder function names:
- Detect arrow-function iife (#127)
- Fixed a bug where inlining string arrays and merging strings could mess them up
- Fixed a bug where not all decoder aliases were detected (#119)
Playground
- Open file from URL:
- Show syntax error alerts with line/col:
- CommonJS support: now
- v2.14.12024-08-14 · 2024-08-14 16:50 UTC
查看更新说明
Security
- Fixed an arbitrary file write vulnerability: https://github.com/j4k0xb/webcrack/security/advisories/GHSA-ccqh-278p-xq6w
Who's affected: Windows users which run the CLI with
--outputor(await webcrack(input)).save(dir)in JS Credits to @SteakEnthusiast for finding it
Unminify
- Fixed a
Maximum call stack size exceedederror on some comparisons (NaN == NaN)
- Fixed an arbitrary file write vulnerability: https://github.com/j4k0xb/webcrack/security/advisories/GHSA-ccqh-278p-xq6w
Who's affected: Windows users which run the CLI with
- v2.14.02024-08-04 · 2024-08-04 01:21 UTC
查看更新说明
Unminify
- No longer extract sequence from
while (a(), b()) c(); - No longer invert relational operators (
!(a > b);->a <= b) due to breaking with NaN - Faster unminify (mainly string merging and numeric expressions)
- Remove double negations:
if (!!a) b();->if (a) b();in if, ternary, array.filter - Extract sequence from for-of:
for (let value of (a = 1, array)) {}->a = 1; for (let value of array) {} - Mangle: names are inferred based on type (variable, function, parameter, class) and some expressions:
var iîiíiîï = exports; function iìíïîíï(iïîiïîï, iìíìïîî, iìiiïiî) { var iïíïíiî = Array(Math.max(iïîiïîï.bitLength(), iìiiïiî) + 1); iïíïíiî.fill(0); var iiïiïîï = 1 << iìíìïîî + 1; var iìîíiîí = iïîiïîï.clone();->
var vExports = exports; function f(p, p2, p3) { var vArray = Array(Math.max(p.bitLength(), p3) + 1); vArray.fill(0); var v = 1 << p2 + 1; var v2 = p.clone();Transpile
- Fixed default parameters offset issue
- Transpile default parameter with value
trueorfalse - Transpile default destructuring parameters:
function f() { let { x, y } = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; let [z] = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : []; }->
function f({ x, y } = {}, [z] = []) {}Deobfuscate
- Inline objects like
var obj = ({ x: 1 }).x; decode(obj)todecode(1) - Support inlined control flow objects:
({ QuFtJ: function (n, r) { return n === r; }}).QuFtJ(u, v);->u === v
Playground
- Menu bar
- Error alerts
- CSP to disallow network requests etc in sandbox
- Mangle filter presets:
CLI
- Added
--no-jsx,--no-unpack,--no-deobfuscate,--no-unminifyarguments
(the playground always has the latest changes, but the npm release was a bit outdated)
- No longer extract sequence from
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
webcrack is a tool for reverse engineering javascript. It can deobfuscate obfuscator.io, unminify, transpile, and unpack webpack/browserify, to resemble the original source code as much as possible.
Try it in the online playground or view the documentation.
- 🚀 Performance - Various optimizations to make it fast
- 🛡️ Safety - Considers variable references and scope
- 🔬 Auto-detection - Finds code patterns without needing a config
- ✍🏻 Readability - Removes obfuscator/bundler artifacts
- ⌨️ TypeScript - All code is written in TypeScript
- 🧪 Tests - To make sure nothing breaks
Requirements
Node.js 22 or 24.
[!NOTE] webcrack depends on
isolated-vm, which does not recommend using odd-numbered Node.js releases because they frequently break ABI/API compatibility with V8.
Command Line Interface
npm install -g webcrack@latest
Examples:
webcrack input.js
webcrack input.js > output.js
webcrack bundle.js -o output-dir
API
npm install webcrack@latest
Examples:
import fs from 'fs';
import { webcrack } from 'webcrack';
const input = fs.readFileSync('bundle.js', 'utf8');
const result = await webcrack(input);
console.log(result.code);
console.log(result.bundle);
await result.save('output-dir');
Donations
If this project has helped you, consider donating to support its development:
- GitHub Sponsors
- Ethereum:
0xb3eFD474Dd8aFA715F563EfA322F6ae9Ae9DfCeA - Bitcoin:
bc1qc3u7ef2rue75f6t8x290r0qk0u84f0ln8ndjun - Solana:
6w9SFAYBxCKdtuj8DEAV9YT5zP68g4PyEkb21AmdxcBq - Monero:
87iYegrerGf1DUsTvUnbsv8gjTMJmzS3idRxHWkCy4iz1Xz5CUnDXy3VkTToSg32LUW3cwNrgLKd1TXRJqJY7MnvVR9yidm