Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
fs-chunk-store
Advanced tools
Filesystem (fs) chunk store that is abstract-chunk-store compliant
npm install fs-chunk-store
var FSChunkStore = require('fs-chunk-store')
var chunks = new FSChunkStore(10, {
path: '/tmp/my_file', // optional: path to file (default: temp file will be used)
length: 100 // optional: file length in bytes (default: file expands based on `put`s)
})
var FSChunkStore = require('fs-chunk-store')
var chunks = new FSChunkStore(10, {
files: [
{ path: 'folder/file1.txt', length: 12 },
{ path: 'folder/file2.txt', length: 8 },
{ path: 'folder/file3.txt', length: 30 }
],
path: 'C:/user/' // optional: if specified the file paths will be treated as relative, not absolute
})
Specifying a path to the store will create a folder in that path, and on destroy, will delete the folder along with all it's contents
chunks.put(0, Buffer.from('0123456789'), function (err) {
if (err) throw err
chunks.get(0, function (err, chunk) {
if (err) throw err
console.log(chunk) // '0123456789' as a buffer
chunks.close(function (err) {
if (err) throw err
console.log('/tmp/my_file file descriptor is closed')
chunks.destroy(function (err) {
if (err) throw err
console.log('/tmp/my_file file is deleted')
})
})
})
})
MIT. Copyright (c) Feross Aboukhadijeh.
FAQs
Filesystem (fs) chunk store that is abstract-chunk-store compliant
The npm package fs-chunk-store receives a total of 5,431 weekly downloads. As such, fs-chunk-store popularity was classified as popular.
We found that fs-chunk-store demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 9 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.
Security News
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.