Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
s3-stream-upload
Advanced tools
A writable stream which uploads to Amazon S3 using the multipart file upload API.
A writable stream which uploads to Amazon S3 using the multipart file upload API.
Inspired by s3-upload-stream.
npm install s3-stream-upload
var UploadStream = require("s3-stream-upload");
var S3 = require("aws-sdk").S3;
var key = "file.mp3";
var s3 = new S3();
fs.readFileStream(__dirname + "/file.mp3")
.pipe(UploadStream(s3, { Bucket: "my-bucket", Key: key }))
.on("error", function (err) {
console.error(err);
})
.on("finish", function () {
console.log("File uploaded!");
});
UploadStream(s3, s3Config, config)
Creates and returns a WritableStream for uploading to S3. Takes an S3 instance, and a s3Config
object, which takes the same options as S3.createMultipartUpload. Additional, non-S3 config options may be set on config
, listed below:
concurrent
How many chunks can be sent to S3 concurrently. 1
by default.chunk-uploaded
- Emitted when a MPU chunk has been uploaded to S3, with the number of chunks uploaded at this point.bytesWritten
- Like fs.WriteStream, bytes uploaded to S3 currently.To run unit tests, run:
npm test
MIT License, Copyright (c) 2014 Jordan Santell
FAQs
A writable stream which uploads to Amazon S3 using the multipart file upload API.
The npm package s3-stream-upload receives a total of 35,542 weekly downloads. As such, s3-stream-upload popularity was classified as popular.
We found that s3-stream-upload demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.