Renames util.js to crypto.js

This commit is contained in:
Daniel Cousens 2014-04-08 22:00:28 +10:00
parent a4c2cc6dd4
commit 81d9c8e759
7 changed files with 16 additions and 16 deletions

9
src/crypto.js Normal file
View file

@ -0,0 +1,9 @@
var convert = require('./convert.js')
var Crypto = require('crypto-js')
var RIPEMD160 = Crypto.RIPEMD160
var SHA256 = Crypto.SHA256
exports.sha256ripe160 = function (data) {
var wordArray = RIPEMD160(SHA256(convert.bytesToWordArray(data)))
return convert.wordArrayToBytes(wordArray)
}