Socket
Socket
Sign inDemoInstall

md5-file

Package Overview
Dependencies
0
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    md5-file

return an md5sum of a given file


Version published
Maintainers
1
Install size
4.58 kB
Created

Readme

Source

md5-file Build Status js-standard-style

Simply return an md5 sum of a given file. If using async version (by including callback), it will stream; successfully tested on files 4 GB+.

Installation

$ npm install md5-file

Test:

$ npm test

API

md5File(path, [callback])

var md5File = require('md5-file')

// sync (no callback)

md5File('./path/to/a_file') // '18e904aae79b5642ed7975c0a0074936'

// async/streamed (if using callback)

md5File('./path/to/a_file', function (error, sum) {
  if (error) return console.log(error)
  console.log(sum) // '18e904aae79b5642ed7975c0a0074936'
})

License

MIT

Keywords

FAQs

Last updated on 20 Jun 2015

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc