Socket
Book a DemoInstallSign in
Socket

secure-remove

Package Overview
Dependencies
Maintainers
3
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

secure-remove

Removing files securely

Source
npmnpm
Version
1.0.1
Version published
Weekly downloads
1
-50%
Maintainers
3
Weekly downloads
 
Created
Source

secure-remove

NPM Package Build Status Dependency status JavaScript Style Guide

API

polyfill(file[, options])

Securely remove a file, using a pure JS implementation.

  • file (String) - Filepath to securely remove
  • options (Object)
    • iterations (Number) - Overwrite the contents N times instead of the default (3).
    • randomSource (String) - Filename to read random bytes from (i.e. /dev/urandom). By default, crypto.randomBytes() is used as the source of random data.
    • size (String|Number) - Shred this many bytes (suffixes like K, M, G accepted). By default, all of the file is shredded.
    • remove (Boolean) - Truncate and remove file after overwriting. Default false.
    • zero (Boolean) - Add a final overwrite with zeros to hide shredding. Default false.

shred(path[, options])

Remove a file by shelling out to shred. Works on Linux ONLY!

  • file (String) - Filepath to securely remove
  • options (Object)
    • force (Boolean) - Change permissions to allow writing if necessary.
    • exact (Boolean) - Do not round file sizes up to the next full block; this is the default for non-regular files.
    • Supports all options supported by polyfill()...

LICENSE

MIT

Keywords

sdelete

FAQs

Package last updated on 28 May 2018

Did you know?

Socket

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.

Install

Related posts