!function(t){if("object"==typeof exports)module.exports=t();else if("function"==typeof define&&define.amd)define(t);else{var r;try{r=window}catch(n){r=self}r.SparkMD5=t()}}(function(){"use strict";var t=function(t,r){return t+r&4294967295},r=function(r,n,e,i,f,o){return n=t(t(n,r),t(i,o)),t(n<>>32-f,e)},n=function(t,n,e,i,f,o,s){return r(n&e|~n&i,t,n,f,o,s)},e=function(t,n,e,i,f,o,s){return r(n&i|e&~i,t,n,f,o,s)},i=function(t,n,e,i,f,o,s){return r(n^e^i,t,n,f,o,s)},f=function(t,n,e,i,f,o,s){return r(e^(n|~i),t,n,f,o,s)},o=function(r,o){var s=r[0],u=r[1],a=r[2],h=r[3];s=n(s,u,a,h,o[0],7,-680876936),h=n(h,s,u,a,o[1],12,-389564586),a=n(a,h,s,u,o[2],17,606105819),u=n(u,a,h,s,o[3],22,-1044525330),s=n(s,u,a,h,o[4],7,-176418897),h=n(h,s,u,a,o[5],12,1200080426),a=n(a,h,s,u,o[6],17,-1473231341),u=n(u,a,h,s,o[7],22,-45705983),s=n(s,u,a,h,o[8],7,1770035416),h=n(h,s,u,a,o[9],12,-1958414417),a=n(a,h,s,u,o[10],17,-42063),u=n(u,a,h,s,o[11],22,-1990404162),s=n(s,u,a,h,o[12],7,1804603682),h=n(h,s,u,a,o[13],12,-40341101),a=n(a,h,s,u,o[14],17,-1502002290),u=n(u,a,h,s,o[15],22,1236535329),s=e(s,u,a,h,o[1],5,-165796510),h=e(h,s,u,a,o[6],9,-1069501632),a=e(a,h,s,u,o[11],14,643717713),u=e(u,a,h,s,o[0],20,-373897302),s=e(s,u,a,h,o[5],5,-701558691),h=e(h,s,u,a,o[10],9,38016083),a=e(a,h,s,u,o[15],14,-660478335),u=e(u,a,h,s,o[4],20,-405537848),s=e(s,u,a,h,o[9],5,568446438),h=e(h,s,u,a,o[14],9,-1019803690),a=e(a,h,s,u,o[3],14,-187363961),u=e(u,a,h,s,o[8],20,1163531501),s=e(s,u,a,h,o[13],5,-1444681467),h=e(h,s,u,a,o[2],9,-51403784),a=e(a,h,s,u,o[7],14,1735328473),u=e(u,a,h,s,o[12],20,-1926607734),s=i(s,u,a,h,o[5],4,-378558),h=i(h,s,u,a,o[8],11,-2022574463),a=i(a,h,s,u,o[11],16,1839030562),u=i(u,a,h,s,o[14],23,-35309556),s=i(s,u,a,h,o[1],4,-1530992060),h=i(h,s,u,a,o[4],11,1272893353),a=i(a,h,s,u,o[7],16,-155497632),u=i(u,a,h,s,o[10],23,-1094730640),s=i(s,u,a,h,o[13],4,681279174),h=i(h,s,u,a,o[0],11,-358537222),a=i(a,h,s,u,o[3],16,-722521979),u=i(u,a,h,s,o[6],23,76029189),s=i(s,u,a,h,o[9],4,-640364487),h=i(h,s,u,a,o[12],11,-421815835),a=i(a,h,s,u,o[15],16,530742520),u=i(u,a,h,s,o[2],23,-995338651),s=f(s,u,a,h,o[0],6,-198630844),h=f(h,s,u,a,o[7],10,1126891415),a=f(a,h,s,u,o[14],15,-1416354905),u=f(u,a,h,s,o[5],21,-57434055),s=f(s,u,a,h,o[12],6,1700485571),h=f(h,s,u,a,o[3],10,-1894986606),a=f(a,h,s,u,o[10],15,-1051523),u=f(u,a,h,s,o[1],21,-2054922799),s=f(s,u,a,h,o[8],6,1873313359),h=f(h,s,u,a,o[15],10,-30611744),a=f(a,h,s,u,o[6],15,-1560198380),u=f(u,a,h,s,o[13],21,1309151649),s=f(s,u,a,h,o[4],6,-145523070),h=f(h,s,u,a,o[11],10,-1120210379),a=f(a,h,s,u,o[2],15,718787259),u=f(u,a,h,s,o[9],21,-343485551),r[0]=t(s,r[0]),r[1]=t(u,r[1]),r[2]=t(a,r[2]),r[3]=t(h,r[3])},s=function(t){var r,n=[];for(r=0;64>r;r+=4)n[r>>2]=t.charCodeAt(r)+(t.charCodeAt(r+1)<<8)+(t.charCodeAt(r+2)<<16)+(t.charCodeAt(r+3)<<24);return n},u=function(t){var r,n=[];for(r=0;64>r;r+=4)n[r>>2]=t[r]+(t[r+1]<<8)+(t[r+2]<<16)+(t[r+3]<<24);return n},a=function(t){var r,n,e,i,f,u,a=t.length,h=[1732584193,-271733879,-1732584194,271733878];for(r=64;a>=r;r+=64)o(h,s(t.substring(r-64,r)));for(t=t.substring(r-64),n=t.length,e=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],r=0;n>r;r+=1)e[r>>2]|=t.charCodeAt(r)<<(r%4<<3);if(e[r>>2]|=128<<(r%4<<3),r>55)for(o(h,e),r=0;16>r;r+=1)e[r]=0;return i=8*a,i=i.toString(16).match(/(.*?)(.{0,8})$/),f=parseInt(i[2],16),u=parseInt(i[1],16)||0,e[14]=f,e[15]=u,o(h,e),h},h=function(t){var r,n,e,i,f,s,a=t.length,h=[1732584193,-271733879,-1732584194,271733878];for(r=64;a>=r;r+=64)o(h,u(t.subarray(r-64,r)));for(t=a>r-64?t.subarray(r-64):new Uint8Array(0),n=t.length,e=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],r=0;n>r;r+=1)e[r>>2]|=t[r]<<(r%4<<3);if(e[r>>2]|=128<<(r%4<<3),r>55)for(o(h,e),r=0;16>r;r+=1)e[r]=0;return i=8*a,i=i.toString(16).match(/(.*?)(.{0,8})$/),f=parseInt(i[2],16),s=parseInt(i[1],16)||0,e[14]=f,e[15]=s,o(h,e),h},c=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],p=function(t){var r,n="";for(r=0;4>r;r+=1)n+=c[t>>8*r+4&15]+c[t>>8*r&15];return n},y=function(t){var r;for(r=0;r>16)+(r>>16)+(n>>16);return e<<16|65535&n}),d.prototype.append=function(t){return/[\u0080-\uFFFF]/.test(t)&&(t=unescape(encodeURIComponent(t))),this.appendBinary(t),this},d.prototype.appendBinary=function(t){this._buff+=t,this._length+=t.length;var r,n=this._buff.length;for(r=64;n>=r;r+=64)o(this._state,s(this._buff.substring(r-64,r)));return this._buff=this._buff.substr(r-64),this},d.prototype.end=function(t){var r,n,e=this._buff,i=e.length,f=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;i>r;r+=1)f[r>>2]|=e.charCodeAt(r)<<(r%4<<3);return this._finish(f,i),n=t?this._state:y(this._state),this.reset(),n},d.prototype.sign=function(t){return this.appendBinary(t),this.end()},d.prototype._finish=function(t,r){var n,e,i,f=r;if(t[f>>2]|=128<<(f%4<<3),f>55)for(o(this._state,t),f=0;16>f;f+=1)t[f]=0;n=8*this._length,n=n.toString(16).match(/(.*?)(.{0,8})$/),e=parseInt(n[2],16),i=parseInt(n[1],16)||0,t[14]=e,t[15]=i,o(this._state,t)},d.prototype.reset=function(){return this._buff="",this._length=0,this._state=[1732584193,-271733879,-1732584194,271733878],this},d.prototype.destroy=function(){delete this._state,delete this._buff,delete this._length},d.hash=function(t,r){/[\u0080-\uFFFF]/.test(t)&&(t=unescape(encodeURIComponent(t)));var n=a(t);return r?n:y(n)},d.hashBinary=function(t,r){var n=a(t);return r?n:y(n)},d.ArrayBuffer=function(){this.reset()},d.ArrayBuffer.prototype.append=function(t){var r,n=this._concatArrayBuffer(this._buff,t),e=n.length;for(this._length+=t.byteLength,r=64;e>=r;r+=64)o(this._state,u(n.subarray(r-64,r)));return this._buff=e>r-64?n.subarray(r-64):new Uint8Array(0),this},d.ArrayBuffer.prototype.end=function(t){var r,n,e=this._buff,i=e.length,f=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;i>r;r+=1)f[r>>2]|=e[r]<<(r%4<<3);return this._finish(f,i),n=t?this._state:y(this._state),this.reset(),n},d.ArrayBuffer.prototype._finish=d.prototype._finish,d.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._state=[1732584193,-271733879,-1732584194,271733878],this},d.ArrayBuffer.prototype.destroy=d.prototype.destroy,d.ArrayBuffer.prototype._concatArrayBuffer=function(t,r){var n=t.length,e=new Uint8Array(n+r.byteLength);return e.set(t),e.set(new Uint8Array(r),n),e},d.ArrayBuffer.hash=function(t,r){var n=h(new Uint8Array(t));return r?n:y(n)},d});