0.3.2 • Published 6 years ago

sandboxed-fs v0.3.2

Weekly downloads
5
License
MIT
Repository
github
Last release
6 years ago

sandboxedFs

npm version Build Status NPM Downloads/Month NPM Downloads

sandboxedFs is a sandboxed wrapper for Node.js file system module implementing the same API but bound to a certain directory, reliably locked in it.

Usage

  • Install: npm install sandboxed-fs
  • Require: const fs = require('sandboxed-fs').bind(path);

Examples:

const fs = require('sandboxed-fs').bind(path);

fs.readFile('file.ext', (err, data) => {
  if (err) return console.log('Cannot read file');
});

fs.readFile('../../file.ext', (err, data) => {
  if (err) return console.log('Cannot read file');
});
0.3.2

6 years ago

0.3.1

6 years ago

0.3.0

6 years ago

0.2.0

6 years ago

0.1.0

7 years ago

0.0.1

7 years ago