
Research
/Security News
9 Malicious NuGet Packages Deliver Time-Delayed Destructive Payloads
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.
@cloudcmd/fileop
Advanced tools
File operations emitter middleware.
npm i @cloudcmd/fileop
Could be loaded from url /fileop/fileop.js.
Initialize operator.
options:
prefix - prefix of fileop (/fileop by default)socketPrefix - prefix of socket.io (`` by default)Returns operator in callback.
It is EventEmitter from the inide produce next types of events:
errorprogressfileendSupports next types of operations:
operator.copy(from, to, names)operator.move(from, to, names)opreator.remove(from, names)opreator.extract(from, to)operator.zip(from, to)operator.tar(from, to)const prefix = '/fileop';
const operator = await fileop({
prefix,
});
const from = '/';
const to = '/tmp';
const names = ['bin'];
const progress = (value) => {
console.log('progress:', value);
};
const end = (op) => () => {
console.log('end');
op.removelistener('progress', progress);
op.removelistener('end', end);
};
const error = (op) => (data) => {
const msg = `${data}\n continue?`;
const is = confirm(msg);
if (is)
return op.continue();
op.abort();
};
const op = await operator.copy(from, to, names);
op.on('progress', progress);
op.on('end', end(op)); op.on('error', error(op));
const fileop = require('fileop');
const http = require('node:http');
const express = require('express');
const io = require('socket.io');
const app = express();
const port = 1337;
const server = http.createServer(app);
const socket = io.listen(server);
server.listen(port);
app.use(fileop({
prefix: '/fileop', /* default */
}));
fileop.listen(socket, {
// default
prefix: '/fileop', // string or a function
root: '/',
auth: (accept, reject) => (username, password) => {
if (username === 'root' && password === 'toor')
accept();
reject();
},
});
socket.io and copymitterMIT
FAQs
file operations emitter middleware
We found that @cloudcmd/fileop 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.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.

Security News
Learn the essential steps every developer should take to stay secure on npm and reduce exposure to supply chain attacks.