From 40083923ed74eb026135d78600ebf55ff0a9e32c Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 1 Sep 2014 15:12:27 -0700 Subject: Support BIP32 HD Wallets --- public/js/sha512.js | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 public/js/sha512.js (limited to 'public/js/sha512.js') diff --git a/public/js/sha512.js b/public/js/sha512.js new file mode 100644 index 00000000..f98481af --- /dev/null +++ b/public/js/sha512.js @@ -0,0 +1,32 @@ +(function() {/* + A JavaScript implementation of the SHA family of hashes, as defined in FIPS + PUB 180-2 as well as the corresponding HMAC implementation as defined in + FIPS PUB 198a + + Copyright Brian Turek 2008-2012 + Distributed under the BSD License + See http://caligatio.github.com/jsSHA/ for more information + + Several functions taken from Paul Johnson +*/ +function n(a){throw a;}var q=null;function s(a,b){this.a=a;this.b=b}function u(a,b){var d=[],h=(1<>>5]|=(a.charCodeAt(g/b)&h)<<32-b-g%32;return{value:d,binLen:f}}function x(a){var b=[],d=a.length,h,f;0!==d%2&&n("String of HEX type must be in byte increments");for(h=0;h>>3]|=f<<24-4*(h%8);return{value:b,binLen:4*d}} +function B(a){var b=[],d=0,h,f,g,k,m;-1===a.search(/^[a-zA-Z0-9=+\/]+$/)&&n("Invalid character in base-64 string");h=a.indexOf("=");a=a.replace(/\=/g,"");-1!==h&&h