AcoDev/zip-bomb-detector-module

Node.js module to detect potential zip bomb files safely.

★ 0Forks 0JavaScriptGitHub ↗Compare

README

Zip Bomb Detector

Installation

npm install github:acodev/zip-bomb-detector-module

Usage

import { analyzeZip } from '@acodev/zip-bomb-detector';

(async () => {
  try {
    const result = await analyzeZip('./path/to/your.zip');
    console.log(result);
  } catch (error) {
    console.error('Error analyzing ZIP:', error);
  }
})();

Output

{
  "isBomb": true,
  "details": {
    "reason": "Too many entries",
    "entryCount": 15000
  }
}

Contributors

AcoDev

Issues