crypto: support custom pbkdf2 digest methods
authorBen Noordhuis <info@bnoordhuis.nl>
Thu, 21 Nov 2013 10:29:07 +0000 (11:29 +0100)
committerFedor Indutny <fedor.indutny@gmail.com>
Wed, 22 Jan 2014 11:58:07 +0000 (15:58 +0400)
commit74d9aa49d57d2c505d1d3712414ca245a805173d
tree70f29529c7ea4d19fe0e275b9edb2043d64f5d4a
parente6016dae348cf105be435abf4b8b318801c09900
crypto: support custom pbkdf2 digest methods

Make the HMAC digest method configurable.  Update crypto.pbkdf2() and
crypto.pbkdf2Sync() to take an extra, optional digest argument.

Before this commit, SHA-1 (admittedly the most common method) was used
exclusively.

Fixes #6553.
doc/api/crypto.markdown
lib/crypto.js
src/node_crypto.cc
test/simple/test-crypto.js