
Security News
minimatch Patches 3 High-Severity ReDoS Vulnerabilities
minimatch patched three high-severity ReDoS vulnerabilities that can stall the Node.js event loop, and Socket has released free certified patches.
@sid-max1996/upload
Advanced tools
Node js file upload package with the ability to limit the download speed, tracking download progress and continue downloading from where it stopped.
const { Uploader } = require('@sid-max1996/upload');
const fs = require('fs');
const path = require('path');
const ProxyAgent = require('proxy-agent');
const url = 'https://klike.net/uploads/posts/2019-07/1564314090_3.jpg';
const uploadDir = path.join(__dirname, 'download');
if (!fs.existsSync(uploadDir)) {
fs.mkdirSync(uploadDir);
}
const uploader = new Uploader({
// byteLimit: 500, // bytes per second limit for download
// proxyAgent: ProxyAgent('http://51.91.157.66:80'), // to use proxy
uploadDir, // path to the folder where files are uploaded
// continueUploading: true, // continue downloading from where it stopped
// headers: { 'User-Agent': 'App' }
});
// uploader.emitter.on('debug', text => console.log(text));
uploader.emitter.on('log', (text) => console.log(text));
// tracking download progress
uploader.emitter.on('progress', (value) => console.log(`Progress (value: ${value}).`));
async function start() {
const filePath = await uploader.upload({
url,
// uploadDir: __dirname, // change uploaded file dir
// fileName: 'hello.jpg', // change uploaded file name
// filePath: path.join(uploadDir, 'hello1.jpg'), // change uploaded file path
// continueUploading: true, // change continue downloading from where it stopped
// headers: { 'User-Agent': 'App' }
});
console.log(`Uploaded (path: ${filePath}).`);
uploader.emitter.removeAllListeners(); // remove all event subscriptions
}
start();
FAQs
Node js file upload package.
The npm package @sid-max1996/upload receives a total of 1 weekly downloads. As such, @sid-max1996/upload popularity was classified as not popular.
We found that @sid-max1996/upload demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
minimatch patched three high-severity ReDoS vulnerabilities that can stall the Node.js event loop, and Socket has released free certified patches.

Research
/Security News
Socket uncovered 26 malicious npm packages tied to North Korea's Contagious Interview campaign, retrieving a live 9-module infostealer and RAT from the adversary's C2.

Research
An impersonated golang.org/x/crypto clone exfiltrates passwords, executes a remote shell stager, and delivers a Rekoobe backdoor on Linux.