Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

210
Views
how to extract password-protected zip in Node Js
const unzipper = require("unzipper");
const fs = require("fs-extra");

async function test() {
  const file = "old.zip";
  const password = "abc";
  const directory = await unzipper.Open.file(file);
  console.log("password", password);
  const extracted = await directory.files[0].buffer(password);
  fs.writeFileSync("extracted/", extracted);
}
test();

I have two files, old.zip and new.zip. The only difference is that when I created old zip using winrar, I checked legacy encryption. You can see the picture below.

enter image description here

My code works for old zip, but not new.zip. Is there any other way to extract the new.zip file?

edit: change title from using javascript => in Node js

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!