From 5869cd970287971fd4ebeb3e80093e382014c0ec Mon Sep 17 00:00:00 2001 From: Dmitry Chestnykh Date: Mon, 28 Mar 2016 19:47:36 +0200 Subject: [PATCH] Build --- nacl-fast.min.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/nacl-fast.min.js b/nacl-fast.min.js index 52a8721e..e6d18e60 100644 --- a/nacl-fast.min.js +++ b/nacl-fast.min.js @@ -1,2 +1 @@ -!function(r){"use strict";function t(r,t,n,e){r[t]=n>>24&255,r[t+1]=n>>16&255,r[t+2]=n>>8&255,r[t+3]=255&n,r[t+4]=e>>24&255,r[t+5]=e>>16&255,r[t+6]=e>>8&255,r[t+7]=255&e}function n(r,t,n,e,o){var i,h=0;for(i=0;o>i;i++)h|=r[t+i]^n[e+i];return(1&h-1>>>8)-1}function e(r,t,e,o){return n(r,t,e,o,16)}function o(r,t,e,o){return n(r,t,e,o,32)}function i(r,t,n,e){for(var o,i=255&e[0]|(255&e[1])<<8|(255&e[2])<<16|(255&e[3])<<24,h=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,f=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,s=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&e[4]|(255&e[5])<<8|(255&e[6])<<16|(255&e[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,y=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,l=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,w=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,p=255&e[8]|(255&e[9])<<8|(255&e[10])<<16|(255&e[11])<<24,v=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,b=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,g=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,_=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,A=255&e[12]|(255&e[13])<<8|(255&e[14])<<16|(255&e[15])<<24,d=i,U=h,E=a,x=f,M=s,m=u,B=c,S=y,K=l,T=w,Y=p,k=v,L=b,z=g,R=_,P=A,O=0;20>O;O+=2)o=d+L|0,M^=o<<7|o>>>25,o=M+d|0,K^=o<<9|o>>>23,o=K+M|0,L^=o<<13|o>>>19,o=L+K|0,d^=o<<18|o>>>14,o=m+U|0,T^=o<<7|o>>>25,o=T+m|0,z^=o<<9|o>>>23,o=z+T|0,U^=o<<13|o>>>19,o=U+z|0,m^=o<<18|o>>>14,o=Y+B|0,R^=o<<7|o>>>25,o=R+Y|0,E^=o<<9|o>>>23,o=E+R|0,B^=o<<13|o>>>19,o=B+E|0,Y^=o<<18|o>>>14,o=P+k|0,x^=o<<7|o>>>25,o=x+P|0,S^=o<<9|o>>>23,o=S+x|0,k^=o<<13|o>>>19,o=k+S|0,P^=o<<18|o>>>14,o=d+x|0,U^=o<<7|o>>>25,o=U+d|0,E^=o<<9|o>>>23,o=E+U|0,x^=o<<13|o>>>19,o=x+E|0,d^=o<<18|o>>>14,o=m+M|0,B^=o<<7|o>>>25,o=B+m|0,S^=o<<9|o>>>23,o=S+B|0,M^=o<<13|o>>>19,o=M+S|0,m^=o<<18|o>>>14,o=Y+T|0,k^=o<<7|o>>>25,o=k+Y|0,K^=o<<9|o>>>23,o=K+k|0,T^=o<<13|o>>>19,o=T+K|0,Y^=o<<18|o>>>14,o=P+R|0,L^=o<<7|o>>>25,o=L+P|0,z^=o<<9|o>>>23,o=z+L|0,R^=o<<13|o>>>19,o=R+z|0,P^=o<<18|o>>>14;d=d+i|0,U=U+h|0,E=E+a|0,x=x+f|0,M=M+s|0,m=m+u|0,B=B+c|0,S=S+y|0,K=K+l|0,T=T+w|0,Y=Y+p|0,k=k+v|0,L=L+b|0,z=z+g|0,R=R+_|0,P=P+A|0,r[0]=d>>>0&255,r[1]=d>>>8&255,r[2]=d>>>16&255,r[3]=d>>>24&255,r[4]=U>>>0&255,r[5]=U>>>8&255,r[6]=U>>>16&255,r[7]=U>>>24&255,r[8]=E>>>0&255,r[9]=E>>>8&255,r[10]=E>>>16&255,r[11]=E>>>24&255,r[12]=x>>>0&255,r[13]=x>>>8&255,r[14]=x>>>16&255,r[15]=x>>>24&255,r[16]=M>>>0&255,r[17]=M>>>8&255,r[18]=M>>>16&255,r[19]=M>>>24&255,r[20]=m>>>0&255,r[21]=m>>>8&255,r[22]=m>>>16&255,r[23]=m>>>24&255,r[24]=B>>>0&255,r[25]=B>>>8&255,r[26]=B>>>16&255,r[27]=B>>>24&255,r[28]=S>>>0&255,r[29]=S>>>8&255,r[30]=S>>>16&255,r[31]=S>>>24&255,r[32]=K>>>0&255,r[33]=K>>>8&255,r[34]=K>>>16&255,r[35]=K>>>24&255,r[36]=T>>>0&255,r[37]=T>>>8&255,r[38]=T>>>16&255,r[39]=T>>>24&255,r[40]=Y>>>0&255,r[41]=Y>>>8&255,r[42]=Y>>>16&255,r[43]=Y>>>24&255,r[44]=k>>>0&255,r[45]=k>>>8&255,r[46]=k>>>16&255,r[47]=k>>>24&255,r[48]=L>>>0&255,r[49]=L>>>8&255,r[50]=L>>>16&255,r[51]=L>>>24&255,r[52]=z>>>0&255,r[53]=z>>>8&255,r[54]=z>>>16&255,r[55]=z>>>24&255,r[56]=R>>>0&255,r[57]=R>>>8&255,r[58]=R>>>16&255,r[59]=R>>>24&255,r[60]=P>>>0&255,r[61]=P>>>8&255,r[62]=P>>>16&255,r[63]=P>>>24&255}function h(r,t,n,e){for(var o,i=255&e[0]|(255&e[1])<<8|(255&e[2])<<16|(255&e[3])<<24,h=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,f=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,s=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&e[4]|(255&e[5])<<8|(255&e[6])<<16|(255&e[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,y=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,l=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,w=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,p=255&e[8]|(255&e[9])<<8|(255&e[10])<<16|(255&e[11])<<24,v=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,b=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,g=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,_=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,A=255&e[12]|(255&e[13])<<8|(255&e[14])<<16|(255&e[15])<<24,d=i,U=h,E=a,x=f,M=s,m=u,B=c,S=y,K=l,T=w,Y=p,k=v,L=b,z=g,R=_,P=A,O=0;20>O;O+=2)o=d+L|0,M^=o<<7|o>>>25,o=M+d|0,K^=o<<9|o>>>23,o=K+M|0,L^=o<<13|o>>>19,o=L+K|0,d^=o<<18|o>>>14,o=m+U|0,T^=o<<7|o>>>25,o=T+m|0,z^=o<<9|o>>>23,o=z+T|0,U^=o<<13|o>>>19,o=U+z|0,m^=o<<18|o>>>14,o=Y+B|0,R^=o<<7|o>>>25,o=R+Y|0,E^=o<<9|o>>>23,o=E+R|0,B^=o<<13|o>>>19,o=B+E|0,Y^=o<<18|o>>>14,o=P+k|0,x^=o<<7|o>>>25,o=x+P|0,S^=o<<9|o>>>23,o=S+x|0,k^=o<<13|o>>>19,o=k+S|0,P^=o<<18|o>>>14,o=d+x|0,U^=o<<7|o>>>25,o=U+d|0,E^=o<<9|o>>>23,o=E+U|0,x^=o<<13|o>>>19,o=x+E|0,d^=o<<18|o>>>14,o=m+M|0,B^=o<<7|o>>>25,o=B+m|0,S^=o<<9|o>>>23,o=S+B|0,M^=o<<13|o>>>19,o=M+S|0,m^=o<<18|o>>>14,o=Y+T|0,k^=o<<7|o>>>25,o=k+Y|0,K^=o<<9|o>>>23,o=K+k|0,T^=o<<13|o>>>19,o=T+K|0,Y^=o<<18|o>>>14,o=P+R|0,L^=o<<7|o>>>25,o=L+P|0,z^=o<<9|o>>>23,o=z+L|0,R^=o<<13|o>>>19,o=R+z|0,P^=o<<18|o>>>14;r[0]=d>>>0&255,r[1]=d>>>8&255,r[2]=d>>>16&255,r[3]=d>>>24&255,r[4]=m>>>0&255,r[5]=m>>>8&255,r[6]=m>>>16&255,r[7]=m>>>24&255,r[8]=Y>>>0&255,r[9]=Y>>>8&255,r[10]=Y>>>16&255,r[11]=Y>>>24&255,r[12]=P>>>0&255,r[13]=P>>>8&255,r[14]=P>>>16&255,r[15]=P>>>24&255,r[16]=B>>>0&255,r[17]=B>>>8&255,r[18]=B>>>16&255,r[19]=B>>>24&255,r[20]=S>>>0&255,r[21]=S>>>8&255,r[22]=S>>>16&255,r[23]=S>>>24&255,r[24]=K>>>0&255,r[25]=K>>>8&255,r[26]=K>>>16&255,r[27]=K>>>24&255,r[28]=T>>>0&255,r[29]=T>>>8&255,r[30]=T>>>16&255,r[31]=T>>>24&255}function a(r,t,n,e){i(r,t,n,e)}function f(r,t,n,e){h(r,t,n,e)}function s(r,t,n,e,o,i,h){var f,s,u=new Uint8Array(16),c=new Uint8Array(64);for(s=0;16>s;s++)u[s]=0;for(s=0;8>s;s++)u[s]=i[s];for(;o>=64;){for(a(c,u,h,cr),s=0;64>s;s++)r[t+s]=n[e+s]^c[s];for(f=1,s=8;16>s;s++)f=f+(255&u[s])|0,u[s]=255&f,f>>>=8;o-=64,t+=64,e+=64}if(o>0)for(a(c,u,h,cr),s=0;o>s;s++)r[t+s]=n[e+s]^c[s];return 0}function u(r,t,n,e,o){var i,h,f=new Uint8Array(16),s=new Uint8Array(64);for(h=0;16>h;h++)f[h]=0;for(h=0;8>h;h++)f[h]=e[h];for(;n>=64;){for(a(s,f,o,cr),h=0;64>h;h++)r[t+h]=s[h];for(i=1,h=8;16>h;h++)i=i+(255&f[h])|0,f[h]=255&i,i>>>=8;n-=64,t+=64}if(n>0)for(a(s,f,o,cr),h=0;n>h;h++)r[t+h]=s[h];return 0}function c(r,t,n,e,o){var i=new Uint8Array(32);f(i,e,o,cr);for(var h=new Uint8Array(8),a=0;8>a;a++)h[a]=e[a+16];return u(r,t,n,h,i)}function y(r,t,n,e,o,i,h){var a=new Uint8Array(32);f(a,i,h,cr);for(var u=new Uint8Array(8),c=0;8>c;c++)u[c]=i[c+16];return s(r,t,n,e,o,u,a)}function l(r,t,n,e,o,i){var h=new yr(i);return h.update(n,e,o),h.finish(r,t),0}function w(r,t,n,o,i,h){var a=new Uint8Array(16);return l(a,0,n,o,i,h),e(r,t,a,0)}function p(r,t,n,e,o){var i;if(32>n)return-1;for(y(r,0,t,0,n,e,o),l(r,16,r,32,n-32,r),i=0;16>i;i++)r[i]=0;return 0}function v(r,t,n,e,o){var i,h=new Uint8Array(32);if(32>n)return-1;if(c(h,0,32,e,o),0!==w(t,16,t,32,n-32,h))return-1;for(y(r,0,t,0,n,e,o),i=0;32>i;i++)r[i]=0;return 0}function b(r,t){var n;for(n=0;16>n;n++)r[n]=0|t[n]}function g(r){var t,n,e=1;for(t=0;16>t;t++)n=r[t]+e+65535,e=Math.floor(n/65536),r[t]=n-65536*e;r[0]+=e-1+37*(e-1)}function _(r,t,n){for(var e,o=~(n-1),i=0;16>i;i++)e=o&(r[i]^t[i]),r[i]^=e,t[i]^=e}function A(r,t){var n,e,o,i=$(),h=$();for(n=0;16>n;n++)h[n]=t[n];for(g(h),g(h),g(h),e=0;2>e;e++){for(i[0]=h[0]-65517,n=1;15>n;n++)i[n]=h[n]-65535-(i[n-1]>>16&1),i[n-1]&=65535;i[15]=h[15]-32767-(i[14]>>16&1),o=i[15]>>16&1,i[14]&=65535,_(h,i,1-o)}for(n=0;16>n;n++)r[2*n]=255&h[n],r[2*n+1]=h[n]>>8}function d(r,t){var n=new Uint8Array(32),e=new Uint8Array(32);return A(n,r),A(e,t),o(n,0,e,0)}function U(r){var t=new Uint8Array(32);return A(t,r),1&t[0]}function E(r,t){var n;for(n=0;16>n;n++)r[n]=t[2*n]+(t[2*n+1]<<8);r[15]&=32767}function x(r,t,n){for(var e=0;16>e;e++)r[e]=t[e]+n[e]}function M(r,t,n){for(var e=0;16>e;e++)r[e]=t[e]-n[e]}function m(r,t,n){var e,o,i=0,h=0,a=0,f=0,s=0,u=0,c=0,y=0,l=0,w=0,p=0,v=0,b=0,g=0,_=0,A=0,d=0,U=0,E=0,x=0,M=0,m=0,B=0,S=0,K=0,T=0,Y=0,k=0,L=0,z=0,R=0,P=n[0],O=n[1],N=n[2],C=n[3],F=n[4],I=n[5],G=n[6],Z=n[7],j=n[8],q=n[9],V=n[10],X=n[11],D=n[12],H=n[13],J=n[14],Q=n[15];e=t[0],i+=e*P,h+=e*O,a+=e*N,f+=e*C,s+=e*F,u+=e*I,c+=e*G,y+=e*Z,l+=e*j,w+=e*q,p+=e*V,v+=e*X,b+=e*D,g+=e*H,_+=e*J,A+=e*Q,e=t[1],h+=e*P,a+=e*O,f+=e*N,s+=e*C,u+=e*F,c+=e*I,y+=e*G,l+=e*Z,w+=e*j,p+=e*q,v+=e*V,b+=e*X,g+=e*D,_+=e*H,A+=e*J,d+=e*Q,e=t[2],a+=e*P,f+=e*O,s+=e*N,u+=e*C,c+=e*F,y+=e*I,l+=e*G,w+=e*Z,p+=e*j,v+=e*q,b+=e*V,g+=e*X,_+=e*D,A+=e*H,d+=e*J,U+=e*Q,e=t[3],f+=e*P,s+=e*O,u+=e*N,c+=e*C,y+=e*F,l+=e*I,w+=e*G,p+=e*Z,v+=e*j,b+=e*q,g+=e*V,_+=e*X,A+=e*D,d+=e*H,U+=e*J,E+=e*Q,e=t[4],s+=e*P,u+=e*O,c+=e*N,y+=e*C,l+=e*F,w+=e*I,p+=e*G,v+=e*Z,b+=e*j,g+=e*q,_+=e*V,A+=e*X,d+=e*D,U+=e*H,E+=e*J,x+=e*Q,e=t[5],u+=e*P,c+=e*O,y+=e*N,l+=e*C,w+=e*F,p+=e*I,v+=e*G,b+=e*Z,g+=e*j,_+=e*q,A+=e*V,d+=e*X,U+=e*D,E+=e*H,x+=e*J,M+=e*Q,e=t[6],c+=e*P,y+=e*O,l+=e*N,w+=e*C,p+=e*F,v+=e*I,b+=e*G,g+=e*Z,_+=e*j,A+=e*q,d+=e*V,U+=e*X,E+=e*D,x+=e*H,M+=e*J,m+=e*Q,e=t[7],y+=e*P,l+=e*O,w+=e*N,p+=e*C,v+=e*F,b+=e*I,g+=e*G,_+=e*Z,A+=e*j,d+=e*q,U+=e*V,E+=e*X,x+=e*D,M+=e*H,m+=e*J,B+=e*Q,e=t[8],l+=e*P,w+=e*O,p+=e*N,v+=e*C,b+=e*F,g+=e*I,_+=e*G,A+=e*Z,d+=e*j,U+=e*q,E+=e*V,x+=e*X,M+=e*D,m+=e*H,B+=e*J,S+=e*Q,e=t[9],w+=e*P,p+=e*O,v+=e*N,b+=e*C,g+=e*F,_+=e*I,A+=e*G,d+=e*Z,U+=e*j,E+=e*q,x+=e*V,M+=e*X,m+=e*D,B+=e*H,S+=e*J,K+=e*Q,e=t[10],p+=e*P,v+=e*O,b+=e*N,g+=e*C,_+=e*F,A+=e*I,d+=e*G,U+=e*Z,E+=e*j,x+=e*q,M+=e*V,m+=e*X,B+=e*D,S+=e*H,K+=e*J,T+=e*Q,e=t[11],v+=e*P,b+=e*O,g+=e*N,_+=e*C,A+=e*F,d+=e*I,U+=e*G,E+=e*Z,x+=e*j,M+=e*q,m+=e*V,B+=e*X,S+=e*D,K+=e*H,T+=e*J,Y+=e*Q,e=t[12],b+=e*P,g+=e*O,_+=e*N,A+=e*C,d+=e*F,U+=e*I,E+=e*G,x+=e*Z,M+=e*j,m+=e*q,B+=e*V,S+=e*X,K+=e*D,T+=e*H,Y+=e*J,k+=e*Q,e=t[13],g+=e*P,_+=e*O,A+=e*N,d+=e*C,U+=e*F,E+=e*I,x+=e*G,M+=e*Z,m+=e*j,B+=e*q,S+=e*V,K+=e*X,T+=e*D,Y+=e*H,k+=e*J,L+=e*Q,e=t[14],_+=e*P,A+=e*O,d+=e*N,U+=e*C,E+=e*F,x+=e*I,M+=e*G,m+=e*Z,B+=e*j,S+=e*q,K+=e*V,T+=e*X,Y+=e*D,k+=e*H,L+=e*J,z+=e*Q,e=t[15],A+=e*P,d+=e*O,U+=e*N,E+=e*C,x+=e*F,M+=e*I,m+=e*G,B+=e*Z,S+=e*j,K+=e*q,T+=e*V,Y+=e*X,k+=e*D,L+=e*H,z+=e*J,R+=e*Q,i+=38*d,h+=38*U,a+=38*E,f+=38*x,s+=38*M,u+=38*m,c+=38*B,y+=38*S,l+=38*K,w+=38*T,p+=38*Y,v+=38*k,b+=38*L,g+=38*z,_+=38*R,o=1,e=i+o+65535,o=Math.floor(e/65536),i=e-65536*o,e=h+o+65535,o=Math.floor(e/65536),h=e-65536*o,e=a+o+65535,o=Math.floor(e/65536),a=e-65536*o,e=f+o+65535,o=Math.floor(e/65536),f=e-65536*o,e=s+o+65535,o=Math.floor(e/65536),s=e-65536*o,e=u+o+65535,o=Math.floor(e/65536),u=e-65536*o,e=c+o+65535,o=Math.floor(e/65536),c=e-65536*o,e=y+o+65535,o=Math.floor(e/65536),y=e-65536*o,e=l+o+65535,o=Math.floor(e/65536),l=e-65536*o,e=w+o+65535,o=Math.floor(e/65536),w=e-65536*o,e=p+o+65535,o=Math.floor(e/65536),p=e-65536*o,e=v+o+65535,o=Math.floor(e/65536),v=e-65536*o,e=b+o+65535,o=Math.floor(e/65536),b=e-65536*o,e=g+o+65535,o=Math.floor(e/65536),g=e-65536*o,e=_+o+65535,o=Math.floor(e/65536),_=e-65536*o,e=A+o+65535,o=Math.floor(e/65536),A=e-65536*o,i+=o-1+37*(o-1),o=1,e=i+o+65535,o=Math.floor(e/65536),i=e-65536*o,e=h+o+65535,o=Math.floor(e/65536),h=e-65536*o,e=a+o+65535,o=Math.floor(e/65536),a=e-65536*o,e=f+o+65535,o=Math.floor(e/65536),f=e-65536*o,e=s+o+65535,o=Math.floor(e/65536),s=e-65536*o,e=u+o+65535,o=Math.floor(e/65536),u=e-65536*o,e=c+o+65535,o=Math.floor(e/65536),c=e-65536*o,e=y+o+65535,o=Math.floor(e/65536),y=e-65536*o,e=l+o+65535,o=Math.floor(e/65536),l=e-65536*o,e=w+o+65535,o=Math.floor(e/65536),w=e-65536*o,e=p+o+65535,o=Math.floor(e/65536),p=e-65536*o,e=v+o+65535,o=Math.floor(e/65536),v=e-65536*o,e=b+o+65535,o=Math.floor(e/65536),b=e-65536*o,e=g+o+65535,o=Math.floor(e/65536),g=e-65536*o,e=_+o+65535,o=Math.floor(e/65536),_=e-65536*o,e=A+o+65535,o=Math.floor(e/65536),A=e-65536*o,i+=o-1+37*(o-1),r[0]=i,r[1]=h,r[2]=a,r[3]=f,r[4]=s,r[5]=u,r[6]=c,r[7]=y,r[8]=l,r[9]=w,r[10]=p,r[11]=v,r[12]=b,r[13]=g,r[14]=_,r[15]=A}function B(r,t){m(r,t,t)}function S(r,t){var n,e=$();for(n=0;16>n;n++)e[n]=t[n];for(n=253;n>=0;n--)B(e,e),2!==n&&4!==n&&m(e,e,t);for(n=0;16>n;n++)r[n]=e[n]}function K(r,t){var n,e=$();for(n=0;16>n;n++)e[n]=t[n];for(n=250;n>=0;n--)B(e,e),1!==n&&m(e,e,t);for(n=0;16>n;n++)r[n]=e[n]}function T(r,t,n){var e,o,i=new Uint8Array(32),h=new Float64Array(80),a=$(),f=$(),s=$(),u=$(),c=$(),y=$();for(o=0;31>o;o++)i[o]=t[o];for(i[31]=127&t[31]|64,i[0]&=248,E(h,n),o=0;16>o;o++)f[o]=h[o],u[o]=a[o]=s[o]=0;for(a[0]=u[0]=1,o=254;o>=0;--o)e=i[o>>>3]>>>(7&o)&1,_(a,f,e),_(s,u,e),x(c,a,s),M(a,a,s),x(s,f,u),M(f,f,u),B(u,c),B(y,a),m(a,s,a),m(s,f,c),x(c,a,s),M(a,a,s),B(f,a),M(s,u,y),m(a,s,ir),x(a,a,u),m(s,s,a),m(a,u,y),m(u,f,h),B(f,c),_(a,f,e),_(s,u,e);for(o=0;16>o;o++)h[o+16]=a[o],h[o+32]=s[o],h[o+48]=f[o],h[o+64]=u[o];var l=h.subarray(32),w=h.subarray(16);return S(l,l),m(w,w,l),A(r,w),0}function Y(r,t){return T(r,t,nr)}function k(r,t){return rr(t,32),Y(r,t)}function L(r,t,n){var e=new Uint8Array(32);return T(e,n,t),f(r,tr,e,cr)}function z(r,t,n,e,o,i){var h=new Uint8Array(32);return L(h,o,i),lr(r,t,n,e,h)}function R(r,t,n,e,o,i){var h=new Uint8Array(32);return L(h,o,i),wr(r,t,n,e,h)}function P(r,t,n,e){for(var o,i,h,a,f,s,u,c,y,l,w,p,v,b,g,_,A,d,U,E,x,M,m,B,S,K,T=new Int32Array(16),Y=new Int32Array(16),k=r[0],L=r[1],z=r[2],R=r[3],P=r[4],O=r[5],N=r[6],C=r[7],F=t[0],I=t[1],G=t[2],Z=t[3],j=t[4],q=t[5],V=t[6],X=t[7],D=0;e>=128;){for(U=0;16>U;U++)E=8*U+D,T[U]=n[E+0]<<24|n[E+1]<<16|n[E+2]<<8|n[E+3],Y[U]=n[E+4]<<24|n[E+5]<<16|n[E+6]<<8|n[E+7];for(U=0;80>U;U++)if(o=k,i=L,h=z,a=R,f=P,s=O,u=N,c=C,y=F,l=I,w=G,p=Z,v=j,b=q,g=V,_=X,x=C,M=X,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=(P>>>14|j<<18)^(P>>>18|j<<14)^(j>>>9|P<<23),M=(j>>>14|P<<18)^(j>>>18|P<<14)^(P>>>9|j<<23),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=P&O^~P&N,M=j&q^~j&V,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=pr[2*U],M=pr[2*U+1],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=T[U%16],M=Y[U%16],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,A=65535&S|K<<16,d=65535&m|B<<16,x=A,M=d,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=(k>>>28|F<<4)^(F>>>2|k<<30)^(F>>>7|k<<25),M=(F>>>28|k<<4)^(k>>>2|F<<30)^(k>>>7|F<<25),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=k&L^k&z^L&z,M=F&I^F&G^I&G,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,c=65535&S|K<<16,_=65535&m|B<<16,x=a,M=p,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=A,M=d,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,a=65535&S|K<<16,p=65535&m|B<<16,L=o,z=i,R=h,P=a,O=f,N=s,C=u,k=c,I=y,G=l,Z=w,j=p,q=v,V=b,X=g,F=_,U%16===15)for(E=0;16>E;E++)x=T[E],M=Y[E],m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=T[(E+9)%16],M=Y[(E+9)%16],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,A=T[(E+1)%16],d=Y[(E+1)%16],x=(A>>>1|d<<31)^(A>>>8|d<<24)^A>>>7,M=(d>>>1|A<<31)^(d>>>8|A<<24)^(d>>>7|A<<25),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,A=T[(E+14)%16],d=Y[(E+14)%16],x=(A>>>19|d<<13)^(d>>>29|A<<3)^A>>>6,M=(d>>>19|A<<13)^(A>>>29|d<<3)^(d>>>6|A<<26),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,T[E]=65535&S|K<<16,Y[E]=65535&m|B<<16;x=k,M=F,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[0],M=t[0],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[0]=k=65535&S|K<<16,t[0]=F=65535&m|B<<16,x=L,M=I,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[1],M=t[1],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[1]=L=65535&S|K<<16,t[1]=I=65535&m|B<<16,x=z,M=G,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[2],M=t[2],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[2]=z=65535&S|K<<16,t[2]=G=65535&m|B<<16,x=R,M=Z,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[3],M=t[3],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[3]=R=65535&S|K<<16,t[3]=Z=65535&m|B<<16,x=P,M=j,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[4],M=t[4],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[4]=P=65535&S|K<<16,t[4]=j=65535&m|B<<16,x=O,M=q,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[5],M=t[5],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[5]=O=65535&S|K<<16,t[5]=q=65535&m|B<<16,x=N,M=V,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[6],M=t[6],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[6]=N=65535&S|K<<16,t[6]=V=65535&m|B<<16,x=C,M=X,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[7],M=t[7],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[7]=C=65535&S|K<<16,t[7]=X=65535&m|B<<16,D+=128,e-=128}return e}function O(r,n,e){var o,i=new Int32Array(8),h=new Int32Array(8),a=new Uint8Array(256),f=e;for(i[0]=1779033703,i[1]=3144134277,i[2]=1013904242,i[3]=2773480762,i[4]=1359893119,i[5]=2600822924,i[6]=528734635,i[7]=1541459225,h[0]=4089235720,h[1]=2227873595,h[2]=4271175723,h[3]=1595750129,h[4]=2917565137,h[5]=725511199,h[6]=4215389547,h[7]=327033209,P(i,h,n,e),e%=128,o=0;e>o;o++)a[o]=n[f-e+o];for(a[e]=128,e=256-128*(112>e?1:0),a[e-9]=0,t(a,e-8,f/536870912|0,f<<3),P(i,h,a,e),o=0;8>o;o++)t(r,8*o,i[o],h[o]);return 0}function N(r,t){var n=$(),e=$(),o=$(),i=$(),h=$(),a=$(),f=$(),s=$(),u=$();M(n,r[1],r[0]),M(u,t[1],t[0]),m(n,n,u),x(e,r[0],r[1]),x(u,t[0],t[1]),m(e,e,u),m(o,r[3],t[3]),m(o,o,ar),m(i,r[2],t[2]),x(i,i,i),M(h,e,n),M(a,i,o),x(f,i,o),x(s,e,n),m(r[0],h,a),m(r[1],s,f),m(r[2],f,a),m(r[3],h,s)}function C(r,t,n){var e;for(e=0;4>e;e++)_(r[e],t[e],n)}function F(r,t){var n=$(),e=$(),o=$();S(o,t[2]),m(n,t[0],o),m(e,t[1],o),A(r,e),r[31]^=U(n)<<7}function I(r,t,n){var e,o;for(b(r[0],er),b(r[1],or),b(r[2],or),b(r[3],er),o=255;o>=0;--o)e=n[o/8|0]>>(7&o)&1,C(r,t,e),N(t,r),N(r,r),C(r,t,e)}function G(r,t){var n=[$(),$(),$(),$()];b(n[0],fr),b(n[1],sr),b(n[2],or),m(n[3],fr,sr),I(r,n,t)}function Z(r,t,n){var e,o=new Uint8Array(64),i=[$(),$(),$(),$()];for(n||rr(t,32),O(o,t,32),o[0]&=248,o[31]&=127,o[31]|=64,G(i,o),F(r,i),e=0;32>e;e++)t[e+32]=r[e];return 0}function j(r,t){var n,e,o,i;for(e=63;e>=32;--e){for(n=0,o=e-32,i=e-12;i>o;++o)t[o]+=n-16*t[e]*vr[o-(e-32)],n=t[o]+128>>8,t[o]-=256*n;t[o]+=n,t[e]=0}for(n=0,o=0;32>o;o++)t[o]+=n-(t[31]>>4)*vr[o],n=t[o]>>8,t[o]&=255;for(o=0;32>o;o++)t[o]-=n*vr[o];for(e=0;32>e;e++)t[e+1]+=t[e]>>8,r[e]=255&t[e]}function q(r){var t,n=new Float64Array(64);for(t=0;64>t;t++)n[t]=r[t];for(t=0;64>t;t++)r[t]=0;j(r,n)}function V(r,t,n,e){var o,i,h=new Uint8Array(64),a=new Uint8Array(64),f=new Uint8Array(64),s=new Float64Array(64),u=[$(),$(),$(),$()];O(h,e,32),h[0]&=248,h[31]&=127,h[31]|=64;var c=n+64;for(o=0;n>o;o++)r[64+o]=t[o];for(o=0;32>o;o++)r[32+o]=h[32+o];for(O(f,r.subarray(32),n+32),q(f),G(u,f),F(r,u),o=32;64>o;o++)r[o]=e[o];for(O(a,r,n+64),q(a),o=0;64>o;o++)s[o]=0;for(o=0;32>o;o++)s[o]=f[o];for(o=0;32>o;o++)for(i=0;32>i;i++)s[o+i]+=a[o]*h[i];return j(r.subarray(32),s),c}function X(r,t){var n=$(),e=$(),o=$(),i=$(),h=$(),a=$(),f=$();return b(r[2],or),E(r[1],t),B(o,r[1]),m(i,o,hr),M(o,o,r[2]),x(i,r[2],i),B(h,i),B(a,h),m(f,a,h),m(n,f,o),m(n,n,i),K(n,n),m(n,n,o),m(n,n,i),m(n,n,i),m(r[0],n,i),B(e,r[0]),m(e,e,i),d(e,o)&&m(r[0],r[0],ur),B(e,r[0]),m(e,e,i),d(e,o)?-1:(U(r[0])===t[31]>>7&&M(r[0],er,r[0]),m(r[3],r[0],r[1]),0)}function D(r,t,n,e){var i,h,a=new Uint8Array(32),f=new Uint8Array(64),s=[$(),$(),$(),$()],u=[$(),$(),$(),$()];if(h=-1,64>n)return-1;if(X(u,e))return-1;for(i=0;n>i;i++)r[i]=t[i];for(i=0;32>i;i++)r[i+32]=e[i];if(O(f,r,n),q(f),I(s,u,f),G(u,t.subarray(32)),N(s,u),F(a,s),n-=64,o(t,0,a,0)){for(i=0;n>i;i++)r[i]=0;return-1}for(i=0;n>i;i++)r[i]=t[i+64];return h=n}function H(r,t){if(r.length!==br)throw new Error("bad key size");if(t.length!==gr)throw new Error("bad nonce size")}function J(r,t){if(r.length!==Er)throw new Error("bad public key size");if(t.length!==xr)throw new Error("bad secret key size")}function Q(){var r,t;for(t=0;t>>13|n<<3),e=255&r[4]|(255&r[5])<<8,this.r[2]=7939&(n>>>10|e<<6),o=255&r[6]|(255&r[7])<<8,this.r[3]=8191&(e>>>7|o<<9),i=255&r[8]|(255&r[9])<<8,this.r[4]=255&(o>>>4|i<<12),this.r[5]=i>>>1&8190,h=255&r[10]|(255&r[11])<<8,this.r[6]=8191&(i>>>14|h<<2),a=255&r[12]|(255&r[13])<<8,this.r[7]=8065&(h>>>11|a<<5),f=255&r[14]|(255&r[15])<<8,this.r[8]=8191&(a>>>8|f<<8),this.r[9]=f>>>5&127,this.pad[0]=255&r[16]|(255&r[17])<<8,this.pad[1]=255&r[18]|(255&r[19])<<8,this.pad[2]=255&r[20]|(255&r[21])<<8,this.pad[3]=255&r[22]|(255&r[23])<<8,this.pad[4]=255&r[24]|(255&r[25])<<8,this.pad[5]=255&r[26]|(255&r[27])<<8,this.pad[6]=255&r[28]|(255&r[29])<<8,this.pad[7]=255&r[30]|(255&r[31])<<8};yr.prototype.blocks=function(r,t,n){for(var e,o,i,h,a,f,s,u,c,y,l,w,p,v,b,g,_,A,d,U=this.fin?0:2048,E=this.h[0],x=this.h[1],M=this.h[2],m=this.h[3],B=this.h[4],S=this.h[5],K=this.h[6],T=this.h[7],Y=this.h[8],k=this.h[9],L=this.r[0],z=this.r[1],R=this.r[2],P=this.r[3],O=this.r[4],N=this.r[5],C=this.r[6],F=this.r[7],I=this.r[8],G=this.r[9];n>=16;)e=255&r[t+0]|(255&r[t+1])<<8,E+=8191&e,o=255&r[t+2]|(255&r[t+3])<<8,x+=8191&(e>>>13|o<<3),i=255&r[t+4]|(255&r[t+5])<<8,M+=8191&(o>>>10|i<<6),h=255&r[t+6]|(255&r[t+7])<<8,m+=8191&(i>>>7|h<<9),a=255&r[t+8]|(255&r[t+9])<<8,B+=8191&(h>>>4|a<<12),S+=a>>>1&8191,f=255&r[t+10]|(255&r[t+11])<<8,K+=8191&(a>>>14|f<<2),s=255&r[t+12]|(255&r[t+13])<<8,T+=8191&(f>>>11|s<<5),u=255&r[t+14]|(255&r[t+15])<<8,Y+=8191&(s>>>8|u<<8),k+=u>>>5|U,c=0,y=c,y+=E*L,y+=x*(5*G),y+=M*(5*I),y+=m*(5*F),y+=B*(5*C),c=y>>>13,y&=8191,y+=S*(5*N),y+=K*(5*O),y+=T*(5*P),y+=Y*(5*R),y+=k*(5*z),c+=y>>>13,y&=8191,l=c,l+=E*z,l+=x*L,l+=M*(5*G),l+=m*(5*I),l+=B*(5*F),c=l>>>13,l&=8191,l+=S*(5*C),l+=K*(5*N),l+=T*(5*O),l+=Y*(5*P),l+=k*(5*R),c+=l>>>13,l&=8191,w=c,w+=E*R,w+=x*z,w+=M*L,w+=m*(5*G),w+=B*(5*I),c=w>>>13,w&=8191,w+=S*(5*F),w+=K*(5*C),w+=T*(5*N),w+=Y*(5*O),w+=k*(5*P),c+=w>>>13,w&=8191,p=c,p+=E*P,p+=x*R,p+=M*z,p+=m*L,p+=B*(5*G),c=p>>>13,p&=8191,p+=S*(5*I),p+=K*(5*F),p+=T*(5*C),p+=Y*(5*N),p+=k*(5*O),c+=p>>>13,p&=8191,v=c,v+=E*O,v+=x*P,v+=M*R,v+=m*z,v+=B*L,c=v>>>13,v&=8191,v+=S*(5*G),v+=K*(5*I),v+=T*(5*F),v+=Y*(5*C),v+=k*(5*N),c+=v>>>13,v&=8191,b=c,b+=E*N,b+=x*O,b+=M*P,b+=m*R,b+=B*z,c=b>>>13,b&=8191,b+=S*L,b+=K*(5*G),b+=T*(5*I),b+=Y*(5*F),b+=k*(5*C),c+=b>>>13,b&=8191,g=c,g+=E*C,g+=x*N,g+=M*O,g+=m*P,g+=B*R,c=g>>>13,g&=8191,g+=S*z,g+=K*L,g+=T*(5*G),g+=Y*(5*I),g+=k*(5*F),c+=g>>>13,g&=8191,_=c,_+=E*F,_+=x*C,_+=M*N,_+=m*O,_+=B*P,c=_>>>13,_&=8191,_+=S*R,_+=K*z,_+=T*L,_+=Y*(5*G),_+=k*(5*I),c+=_>>>13,_&=8191,A=c,A+=E*I,A+=x*F,A+=M*C,A+=m*N,A+=B*O,c=A>>>13,A&=8191,A+=S*P,A+=K*R,A+=T*z,A+=Y*L,A+=k*(5*G),c+=A>>>13,A&=8191,d=c,d+=E*G,d+=x*I,d+=M*F,d+=m*C,d+=B*N,c=d>>>13,d&=8191,d+=S*O,d+=K*P,d+=T*R,d+=Y*z,d+=k*L,c+=d>>>13,d&=8191,c=(c<<2)+c|0,c=c+y|0,y=8191&c,c>>>=13,l+=c,E=y,x=l,M=w,m=p,B=v,S=b,K=g,T=_,Y=A,k=d,t+=16,n-=16;this.h[0]=E,this.h[1]=x,this.h[2]=M,this.h[3]=m,this.h[4]=B,this.h[5]=S,this.h[6]=K,this.h[7]=T,this.h[8]=Y,this.h[9]=k},yr.prototype.finish=function(r,t){var n,e,o,i,h=new Uint16Array(10);if(this.leftover){for(i=this.leftover,this.buffer[i++]=1;16>i;i++)this.buffer[i]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(n=this.h[1]>>>13,this.h[1]&=8191,i=2;10>i;i++)this.h[i]+=n,n=this.h[i]>>>13,this.h[i]&=8191;for(this.h[0]+=5*n,n=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=n,n=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=n,h[0]=this.h[0]+5,n=h[0]>>>13,h[0]&=8191,i=1;10>i;i++)h[i]=this.h[i]+n,n=h[i]>>>13,h[i]&=8191;for(h[9]-=8192,e=(h[9]>>>15)-1,i=0;10>i;i++)h[i]&=e;for(e=~e,i=0;10>i;i++)this.h[i]=this.h[i]&e|h[i];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),o=this.h[0]+this.pad[0],this.h[0]=65535&o,i=1;8>i;i++)o=(this.h[i]+this.pad[i]|0)+(o>>>16)|0,this.h[i]=65535&o;r[t+0]=this.h[0]>>>0&255,r[t+1]=this.h[0]>>>8&255,r[t+2]=this.h[1]>>>0&255,r[t+3]=this.h[1]>>>8&255,r[t+4]=this.h[2]>>>0&255,r[t+5]=this.h[2]>>>8&255,r[t+6]=this.h[3]>>>0&255,r[t+7]=this.h[3]>>>8&255,r[t+8]=this.h[4]>>>0&255,r[t+9]=this.h[4]>>>8&255,r[t+10]=this.h[5]>>>0&255,r[t+11]=this.h[5]>>>8&255,r[t+12]=this.h[6]>>>0&255,r[t+13]=this.h[6]>>>8&255,r[t+14]=this.h[7]>>>0&255,r[t+15]=this.h[7]>>>8&255},yr.prototype.update=function(r,t,n){var e,o;if(this.leftover){for(o=16-this.leftover,o>n&&(o=n),e=0;o>e;e++)this.buffer[this.leftover+e]=r[t+e];if(n-=o,t+=o,this.leftover+=o,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(n>=16&&(o=n-n%16,this.blocks(r,t,o),t+=o,n-=o),n){for(e=0;n>e;e++)this.buffer[this.leftover+e]=r[t+e];this.leftover+=n}};var lr=p,wr=v,pr=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],vr=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]),br=32,gr=24,_r=32,Ar=16,dr=32,Ur=32,Er=32,xr=32,Mr=32,mr=gr,Br=_r,Sr=Ar,Kr=64,Tr=32,Yr=64,kr=32,Lr=64;r.lowlevel={crypto_core_hsalsa20:f,crypto_stream_xor:y,crypto_stream:c,crypto_stream_salsa20_xor:s,crypto_stream_salsa20:u,crypto_onetimeauth:l,crypto_onetimeauth_verify:w,crypto_verify_16:e,crypto_verify_32:o,crypto_secretbox:p,crypto_secretbox_open:v,crypto_scalarmult:T,crypto_scalarmult_base:Y,crypto_box_beforenm:L,crypto_box_afternm:lr,crypto_box:z,crypto_box_open:R,crypto_box_keypair:k,crypto_hash:O,crypto_sign:V,crypto_sign_keypair:Z,crypto_sign_open:D,crypto_secretbox_KEYBYTES:br,crypto_secretbox_NONCEBYTES:gr,crypto_secretbox_ZEROBYTES:_r,crypto_secretbox_BOXZEROBYTES:Ar,crypto_scalarmult_BYTES:dr,crypto_scalarmult_SCALARBYTES:Ur,crypto_box_PUBLICKEYBYTES:Er,crypto_box_SECRETKEYBYTES:xr,crypto_box_BEFORENMBYTES:Mr,crypto_box_NONCEBYTES:mr,crypto_box_ZEROBYTES:Br,crypto_box_BOXZEROBYTES:Sr,crypto_sign_BYTES:Kr,crypto_sign_PUBLICKEYBYTES:Tr,crypto_sign_SECRETKEYBYTES:Yr,crypto_sign_SEEDBYTES:kr,crypto_hash_BYTES:Lr},r.util||(r.util={},r.util.decodeUTF8=r.util.encodeUTF8=r.util.encodeBase64=r.util.decodeBase64=function(){throw new Error("nacl.util moved into separate package: https://github.com/dchest/tweetnacl-util-js")}),r.randomBytes=function(r){var t=new Uint8Array(r);return rr(t,r),t},r.secretbox=function(r,t,n){Q(r,t,n),H(n,t);for(var e=new Uint8Array(_r+r.length),o=new Uint8Array(e.length),i=0;ie)return null;for(var o=new Uint8Array(e),i=0;ie;e++)o[e]=t[e];for(e=0;e=0},r.sign.keyPair=function(){var r=new Uint8Array(Tr),t=new Uint8Array(Yr);return Z(r,t),{publicKey:r,secretKey:t}},r.sign.keyPair.fromSecretKey=function(r){if(Q(r),r.length!==Yr)throw new Error("bad secret key size");for(var t=new Uint8Array(Tr),n=0;ne;e++)n[e]=r[e];return Z(t,n,!0),{publicKey:t,secretKey:n}},r.sign.publicKeyLength=Tr,r.sign.secretKeyLength=Yr,r.sign.seedLength=kr,r.sign.signatureLength=Kr,r.hash=function(r){Q(r);var t=new Uint8Array(Lr);return O(t,r,r.length),t},r.hash.hashLength=Lr,r.verify=function(r,t){ -return Q(r,t),0===r.length||0===t.length?!1:r.length!==t.length?!1:0===n(r,0,t,0,r.length)?!0:!1},r.setPRNG=function(r){rr=r},function(){var t="undefined"!=typeof self?self.crypto||self.msCrypto:null;if(t&&t.getRandomValues){var n=65536;r.setPRNG(function(r,e){var o,i=new Uint8Array(e);for(o=0;e>o;o+=n)t.getRandomValues(i.subarray(o,o+Math.min(e-o,n)));for(o=0;e>o;o++)r[o]=i[o];W(i)})}else"undefined"!=typeof require&&(t=require("crypto"),t&&t.randomBytes&&r.setPRNG(function(r,n){var e,o=t.randomBytes(n);for(e=0;n>e;e++)r[e]=o[e];W(o)}))}()}("undefined"!=typeof module&&module.exports?module.exports:self.nacl=self.nacl||{}); \ No newline at end of file +!function(r){"use strict";function n(r,n,t,e){r[n]=t>>24&255,r[n+1]=t>>16&255,r[n+2]=t>>8&255,r[n+3]=255&t,r[n+4]=e>>24&255,r[n+5]=e>>16&255,r[n+6]=e>>8&255,r[n+7]=255&e}function t(r,n,t,e,o){var a,f=0;for(a=0;o>a;a++)f|=r[n+a]^t[e+a];return(1&f-1>>>8)-1}function e(r,n,e,o){return t(r,n,e,o,16)}function o(r,n,e,o){return t(r,n,e,o,32)}function a(r,n,t,e){for(var o,a=255&e[0]|(255&e[1])<<8|(255&e[2])<<16|(255&e[3])<<24,f=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,i=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,c=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,u=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,y=255&e[4]|(255&e[5])<<8|(255&e[6])<<16|(255&e[7])<<24,l=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,h=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,s=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,w=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,g=255&e[8]|(255&e[9])<<8|(255&e[10])<<16|(255&e[11])<<24,v=255&t[16]|(255&t[17])<<8|(255&t[18])<<16|(255&t[19])<<24,b=255&t[20]|(255&t[21])<<8|(255&t[22])<<16|(255&t[23])<<24,p=255&t[24]|(255&t[25])<<8|(255&t[26])<<16|(255&t[27])<<24,A=255&t[28]|(255&t[29])<<8|(255&t[30])<<16|(255&t[31])<<24,_=255&e[12]|(255&e[13])<<8|(255&e[14])<<16|(255&e[15])<<24,U=a,E=f,d=i,x=c,M=u,m=y,B=l,S=h,K=s,T=w,Y=g,L=v,k=b,z=p,R=A,P=_,O=0;20>O;O+=2)o=U+k|0,M^=o<<7|o>>>25,o=M+U|0,K^=o<<9|o>>>23,o=K+M|0,k^=o<<13|o>>>19,o=k+K|0,U^=o<<18|o>>>14,o=m+E|0,T^=o<<7|o>>>25,o=T+m|0,z^=o<<9|o>>>23,o=z+T|0,E^=o<<13|o>>>19,o=E+z|0,m^=o<<18|o>>>14,o=Y+B|0,R^=o<<7|o>>>25,o=R+Y|0,d^=o<<9|o>>>23,o=d+R|0,B^=o<<13|o>>>19,o=B+d|0,Y^=o<<18|o>>>14,o=P+L|0,x^=o<<7|o>>>25,o=x+P|0,S^=o<<9|o>>>23,o=S+x|0,L^=o<<13|o>>>19,o=L+S|0,P^=o<<18|o>>>14,o=U+x|0,E^=o<<7|o>>>25,o=E+U|0,d^=o<<9|o>>>23,o=d+E|0,x^=o<<13|o>>>19,o=x+d|0,U^=o<<18|o>>>14,o=m+M|0,B^=o<<7|o>>>25,o=B+m|0,S^=o<<9|o>>>23,o=S+B|0,M^=o<<13|o>>>19,o=M+S|0,m^=o<<18|o>>>14,o=Y+T|0,L^=o<<7|o>>>25,o=L+Y|0,K^=o<<9|o>>>23,o=K+L|0,T^=o<<13|o>>>19,o=T+K|0,Y^=o<<18|o>>>14,o=P+R|0,k^=o<<7|o>>>25,o=k+P|0,z^=o<<9|o>>>23,o=z+k|0,R^=o<<13|o>>>19,o=R+z|0,P^=o<<18|o>>>14;U=U+a|0,E=E+f|0,d=d+i|0,x=x+c|0,M=M+u|0,m=m+y|0,B=B+l|0,S=S+h|0,K=K+s|0,T=T+w|0,Y=Y+g|0,L=L+v|0,k=k+b|0,z=z+p|0,R=R+A|0,P=P+_|0,r[0]=U>>>0&255,r[1]=U>>>8&255,r[2]=U>>>16&255,r[3]=U>>>24&255,r[4]=E>>>0&255,r[5]=E>>>8&255,r[6]=E>>>16&255,r[7]=E>>>24&255,r[8]=d>>>0&255,r[9]=d>>>8&255,r[10]=d>>>16&255,r[11]=d>>>24&255,r[12]=x>>>0&255,r[13]=x>>>8&255,r[14]=x>>>16&255,r[15]=x>>>24&255,r[16]=M>>>0&255,r[17]=M>>>8&255,r[18]=M>>>16&255,r[19]=M>>>24&255,r[20]=m>>>0&255,r[21]=m>>>8&255,r[22]=m>>>16&255,r[23]=m>>>24&255,r[24]=B>>>0&255,r[25]=B>>>8&255,r[26]=B>>>16&255,r[27]=B>>>24&255,r[28]=S>>>0&255,r[29]=S>>>8&255,r[30]=S>>>16&255,r[31]=S>>>24&255,r[32]=K>>>0&255,r[33]=K>>>8&255,r[34]=K>>>16&255,r[35]=K>>>24&255,r[36]=T>>>0&255,r[37]=T>>>8&255,r[38]=T>>>16&255,r[39]=T>>>24&255,r[40]=Y>>>0&255,r[41]=Y>>>8&255,r[42]=Y>>>16&255,r[43]=Y>>>24&255,r[44]=L>>>0&255,r[45]=L>>>8&255,r[46]=L>>>16&255,r[47]=L>>>24&255,r[48]=k>>>0&255,r[49]=k>>>8&255,r[50]=k>>>16&255,r[51]=k>>>24&255,r[52]=z>>>0&255,r[53]=z>>>8&255,r[54]=z>>>16&255,r[55]=z>>>24&255,r[56]=R>>>0&255,r[57]=R>>>8&255,r[58]=R>>>16&255,r[59]=R>>>24&255,r[60]=P>>>0&255,r[61]=P>>>8&255,r[62]=P>>>16&255,r[63]=P>>>24&255}function f(r,n,t,e){for(var o,a=255&e[0]|(255&e[1])<<8|(255&e[2])<<16|(255&e[3])<<24,f=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,i=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,c=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,u=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,y=255&e[4]|(255&e[5])<<8|(255&e[6])<<16|(255&e[7])<<24,l=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,h=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,s=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,w=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,g=255&e[8]|(255&e[9])<<8|(255&e[10])<<16|(255&e[11])<<24,v=255&t[16]|(255&t[17])<<8|(255&t[18])<<16|(255&t[19])<<24,b=255&t[20]|(255&t[21])<<8|(255&t[22])<<16|(255&t[23])<<24,p=255&t[24]|(255&t[25])<<8|(255&t[26])<<16|(255&t[27])<<24,A=255&t[28]|(255&t[29])<<8|(255&t[30])<<16|(255&t[31])<<24,_=255&e[12]|(255&e[13])<<8|(255&e[14])<<16|(255&e[15])<<24,U=a,E=f,d=i,x=c,M=u,m=y,B=l,S=h,K=s,T=w,Y=g,L=v,k=b,z=p,R=A,P=_,O=0;20>O;O+=2)o=U+k|0,M^=o<<7|o>>>25,o=M+U|0,K^=o<<9|o>>>23,o=K+M|0,k^=o<<13|o>>>19,o=k+K|0,U^=o<<18|o>>>14,o=m+E|0,T^=o<<7|o>>>25,o=T+m|0,z^=o<<9|o>>>23,o=z+T|0,E^=o<<13|o>>>19,o=E+z|0,m^=o<<18|o>>>14,o=Y+B|0,R^=o<<7|o>>>25,o=R+Y|0,d^=o<<9|o>>>23,o=d+R|0,B^=o<<13|o>>>19,o=B+d|0,Y^=o<<18|o>>>14,o=P+L|0,x^=o<<7|o>>>25,o=x+P|0,S^=o<<9|o>>>23,o=S+x|0,L^=o<<13|o>>>19,o=L+S|0,P^=o<<18|o>>>14,o=U+x|0,E^=o<<7|o>>>25,o=E+U|0,d^=o<<9|o>>>23,o=d+E|0,x^=o<<13|o>>>19,o=x+d|0,U^=o<<18|o>>>14,o=m+M|0,B^=o<<7|o>>>25,o=B+m|0,S^=o<<9|o>>>23,o=S+B|0,M^=o<<13|o>>>19,o=M+S|0,m^=o<<18|o>>>14,o=Y+T|0,L^=o<<7|o>>>25,o=L+Y|0,K^=o<<9|o>>>23,o=K+L|0,T^=o<<13|o>>>19,o=T+K|0,Y^=o<<18|o>>>14,o=P+R|0,k^=o<<7|o>>>25,o=k+P|0,z^=o<<9|o>>>23,o=z+k|0,R^=o<<13|o>>>19,o=R+z|0,P^=o<<18|o>>>14;r[0]=U>>>0&255,r[1]=U>>>8&255,r[2]=U>>>16&255,r[3]=U>>>24&255,r[4]=m>>>0&255,r[5]=m>>>8&255,r[6]=m>>>16&255,r[7]=m>>>24&255,r[8]=Y>>>0&255,r[9]=Y>>>8&255,r[10]=Y>>>16&255,r[11]=Y>>>24&255,r[12]=P>>>0&255,r[13]=P>>>8&255,r[14]=P>>>16&255,r[15]=P>>>24&255,r[16]=B>>>0&255,r[17]=B>>>8&255,r[18]=B>>>16&255,r[19]=B>>>24&255,r[20]=S>>>0&255,r[21]=S>>>8&255,r[22]=S>>>16&255,r[23]=S>>>24&255,r[24]=K>>>0&255,r[25]=K>>>8&255,r[26]=K>>>16&255,r[27]=K>>>24&255,r[28]=T>>>0&255,r[29]=T>>>8&255,r[30]=T>>>16&255,r[31]=T>>>24&255}function i(r,n,t,e){a(r,n,t,e)}function c(r,n,t,e){f(r,n,t,e)}function u(r,n,t,e,o,a,f){var c,u,y=new Uint8Array(16),l=new Uint8Array(64);for(u=0;16>u;u++)y[u]=0;for(u=0;8>u;u++)y[u]=a[u];for(;o>=64;){for(i(l,y,f,hr),u=0;64>u;u++)r[n+u]=t[e+u]^l[u];for(c=1,u=8;16>u;u++)c=c+(255&y[u])|0,y[u]=255&c,c>>>=8;o-=64,n+=64,e+=64}if(o>0)for(i(l,y,f,hr),u=0;o>u;u++)r[n+u]=t[e+u]^l[u];return 0}function y(r,n,t,e,o){var a,f,c=new Uint8Array(16),u=new Uint8Array(64);for(f=0;16>f;f++)c[f]=0;for(f=0;8>f;f++)c[f]=e[f];for(;t>=64;){for(i(u,c,o,hr),f=0;64>f;f++)r[n+f]=u[f];for(a=1,f=8;16>f;f++)a=a+(255&c[f])|0,c[f]=255&a,a>>>=8;t-=64,n+=64}if(t>0)for(i(u,c,o,hr),f=0;t>f;f++)r[n+f]=u[f];return 0}function l(r,n,t,e,o){var a=new Uint8Array(32);c(a,e,o,hr);for(var f=new Uint8Array(8),i=0;8>i;i++)f[i]=e[i+16];return y(r,n,t,f,a)}function h(r,n,t,e,o,a,f){var i=new Uint8Array(32);c(i,a,f,hr);for(var y=new Uint8Array(8),l=0;8>l;l++)y[l]=a[l+16];return u(r,n,t,e,o,y,i)}function s(r,n){var t,e=0;for(t=0;17>t;t++)e=e+(r[t]+n[t]|0)|0,r[t]=255&e,e>>>=8}function w(r,n,t,e,o,a){var f,i,c,u,y=new Uint32Array(17),l=new Uint32Array(17),h=new Uint32Array(17),w=new Uint32Array(17),g=new Uint32Array(17);for(c=0;17>c;c++)l[c]=h[c]=0;for(c=0;16>c;c++)l[c]=a[c];for(l[3]&=15,l[4]&=252,l[7]&=15,l[8]&=252,l[11]&=15,l[12]&=252,l[15]&=15;o>0;){for(c=0;17>c;c++)w[c]=0;for(c=0;16>c&&o>c;++c)w[c]=t[e+c];for(w[c]=1,e+=c,o-=c,s(h,w),i=0;17>i;i++)for(y[i]=0,c=0;17>c;c++)y[i]=y[i]+h[c]*(i>=c?l[i-c]:320*l[i+17-c]|0)|0|0;for(i=0;17>i;i++)h[i]=y[i];for(u=0,c=0;16>c;c++)u=u+h[c]|0,h[c]=255&u,u>>>=8;for(u=u+h[16]|0,h[16]=3&u,u=5*(u>>>2)|0,c=0;16>c;c++)u=u+h[c]|0,h[c]=255&u,u>>>=8;u=u+h[16]|0,h[16]=u}for(c=0;17>c;c++)g[c]=h[c];for(s(h,sr),f=0|-(h[16]>>>7),c=0;17>c;c++)h[c]^=f&(g[c]^h[c]);for(c=0;16>c;c++)w[c]=a[c+16];for(w[16]=0,s(h,w),c=0;16>c;c++)r[n+c]=h[c];return 0}function g(r,n,t,o,a,f){var i=new Uint8Array(16);return w(i,0,t,o,a,f),e(r,n,i,0)}function v(r,n,t,e,o){var a;if(32>t)return-1;for(h(r,0,n,0,t,e,o),w(r,16,r,32,t-32,r),a=0;16>a;a++)r[a]=0;return 0}function b(r,n,t,e,o){var a,f=new Uint8Array(32);if(32>t)return-1;if(l(f,0,32,e,o),0!==g(n,16,n,32,t-32,f))return-1;for(h(r,0,n,0,t,e,o),a=0;32>a;a++)r[a]=0;return 0}function p(r,n){var t;for(t=0;16>t;t++)r[t]=0|n[t]}function A(r){var n,t,e=1;for(n=0;16>n;n++)t=r[n]+e+65535,e=Math.floor(t/65536),r[n]=t-65536*e;r[0]+=e-1+37*(e-1)}function _(r,n,t){for(var e,o=~(t-1),a=0;16>a;a++)e=o&(r[a]^n[a]),r[a]^=e,n[a]^=e}function U(r,n){var t,e,o,a=rr(),f=rr();for(t=0;16>t;t++)f[t]=n[t];for(A(f),A(f),A(f),e=0;2>e;e++){for(a[0]=f[0]-65517,t=1;15>t;t++)a[t]=f[t]-65535-(a[t-1]>>16&1),a[t-1]&=65535;a[15]=f[15]-32767-(a[14]>>16&1),o=a[15]>>16&1,a[14]&=65535,_(f,a,1-o)}for(t=0;16>t;t++)r[2*t]=255&f[t],r[2*t+1]=f[t]>>8}function E(r,n){var t=new Uint8Array(32),e=new Uint8Array(32);return U(t,r),U(e,n),o(t,0,e,0)}function d(r){var n=new Uint8Array(32);return U(n,r),1&n[0]}function x(r,n){var t;for(t=0;16>t;t++)r[t]=n[2*t]+(n[2*t+1]<<8);r[15]&=32767}function M(r,n,t){for(var e=0;16>e;e++)r[e]=n[e]+t[e]}function m(r,n,t){for(var e=0;16>e;e++)r[e]=n[e]-t[e]}function B(r,n,t){var e,o,a=0,f=0,i=0,c=0,u=0,y=0,l=0,h=0,s=0,w=0,g=0,v=0,b=0,p=0,A=0,_=0,U=0,E=0,d=0,x=0,M=0,m=0,B=0,S=0,K=0,T=0,Y=0,L=0,k=0,z=0,R=0,P=t[0],O=t[1],N=t[2],C=t[3],F=t[4],I=t[5],G=t[6],Z=t[7],j=t[8],q=t[9],V=t[10],X=t[11],D=t[12],H=t[13],J=t[14],Q=t[15];e=n[0],a+=e*P,f+=e*O,i+=e*N,c+=e*C,u+=e*F,y+=e*I,l+=e*G,h+=e*Z,s+=e*j,w+=e*q,g+=e*V,v+=e*X,b+=e*D,p+=e*H,A+=e*J,_+=e*Q,e=n[1],f+=e*P,i+=e*O,c+=e*N,u+=e*C,y+=e*F,l+=e*I,h+=e*G,s+=e*Z,w+=e*j,g+=e*q,v+=e*V,b+=e*X,p+=e*D,A+=e*H,_+=e*J,U+=e*Q,e=n[2],i+=e*P,c+=e*O,u+=e*N,y+=e*C,l+=e*F,h+=e*I,s+=e*G,w+=e*Z,g+=e*j,v+=e*q,b+=e*V,p+=e*X,A+=e*D,_+=e*H,U+=e*J,E+=e*Q,e=n[3],c+=e*P,u+=e*O,y+=e*N,l+=e*C,h+=e*F,s+=e*I,w+=e*G,g+=e*Z,v+=e*j,b+=e*q,p+=e*V,A+=e*X,_+=e*D,U+=e*H,E+=e*J,d+=e*Q,e=n[4],u+=e*P,y+=e*O,l+=e*N,h+=e*C,s+=e*F,w+=e*I,g+=e*G,v+=e*Z,b+=e*j,p+=e*q,A+=e*V,_+=e*X,U+=e*D,E+=e*H,d+=e*J,x+=e*Q,e=n[5],y+=e*P,l+=e*O,h+=e*N,s+=e*C,w+=e*F,g+=e*I,v+=e*G,b+=e*Z,p+=e*j,A+=e*q,_+=e*V,U+=e*X,E+=e*D,d+=e*H,x+=e*J,M+=e*Q,e=n[6],l+=e*P,h+=e*O,s+=e*N,w+=e*C,g+=e*F,v+=e*I,b+=e*G,p+=e*Z,A+=e*j,_+=e*q,U+=e*V,E+=e*X,d+=e*D,x+=e*H,M+=e*J,m+=e*Q,e=n[7],h+=e*P,s+=e*O,w+=e*N,g+=e*C,v+=e*F,b+=e*I,p+=e*G,A+=e*Z,_+=e*j,U+=e*q,E+=e*V,d+=e*X,x+=e*D,M+=e*H,m+=e*J,B+=e*Q,e=n[8],s+=e*P,w+=e*O,g+=e*N,v+=e*C,b+=e*F,p+=e*I,A+=e*G,_+=e*Z,U+=e*j,E+=e*q,d+=e*V,x+=e*X,M+=e*D,m+=e*H,B+=e*J,S+=e*Q,e=n[9],w+=e*P,g+=e*O,v+=e*N,b+=e*C,p+=e*F,A+=e*I,_+=e*G,U+=e*Z,E+=e*j,d+=e*q,x+=e*V,M+=e*X,m+=e*D,B+=e*H,S+=e*J,K+=e*Q,e=n[10],g+=e*P,v+=e*O,b+=e*N,p+=e*C,A+=e*F,_+=e*I,U+=e*G,E+=e*Z,d+=e*j,x+=e*q,M+=e*V,m+=e*X,B+=e*D,S+=e*H,K+=e*J,T+=e*Q,e=n[11],v+=e*P,b+=e*O,p+=e*N,A+=e*C,_+=e*F,U+=e*I,E+=e*G,d+=e*Z,x+=e*j,M+=e*q,m+=e*V,B+=e*X,S+=e*D,K+=e*H,T+=e*J,Y+=e*Q,e=n[12],b+=e*P,p+=e*O,A+=e*N,_+=e*C,U+=e*F,E+=e*I,d+=e*G,x+=e*Z,M+=e*j,m+=e*q,B+=e*V,S+=e*X,K+=e*D,T+=e*H,Y+=e*J,L+=e*Q,e=n[13],p+=e*P,A+=e*O,_+=e*N,U+=e*C,E+=e*F,d+=e*I,x+=e*G,M+=e*Z,m+=e*j,B+=e*q,S+=e*V,K+=e*X,T+=e*D,Y+=e*H,L+=e*J,k+=e*Q,e=n[14],A+=e*P,_+=e*O,U+=e*N,E+=e*C,d+=e*F,x+=e*I,M+=e*G,m+=e*Z,B+=e*j,S+=e*q,K+=e*V,T+=e*X,Y+=e*D,L+=e*H,k+=e*J,z+=e*Q,e=n[15],_+=e*P,U+=e*O,E+=e*N,d+=e*C,x+=e*F,M+=e*I,m+=e*G,B+=e*Z,S+=e*j,K+=e*q,T+=e*V,Y+=e*X,L+=e*D,k+=e*H,z+=e*J,R+=e*Q,a+=38*U,f+=38*E,i+=38*d,c+=38*x,u+=38*M,y+=38*m,l+=38*B,h+=38*S,s+=38*K,w+=38*T,g+=38*Y,v+=38*L,b+=38*k,p+=38*z,A+=38*R,o=1,e=a+o+65535,o=Math.floor(e/65536),a=e-65536*o,e=f+o+65535,o=Math.floor(e/65536),f=e-65536*o,e=i+o+65535,o=Math.floor(e/65536),i=e-65536*o,e=c+o+65535,o=Math.floor(e/65536),c=e-65536*o,e=u+o+65535,o=Math.floor(e/65536),u=e-65536*o,e=y+o+65535,o=Math.floor(e/65536),y=e-65536*o,e=l+o+65535,o=Math.floor(e/65536),l=e-65536*o,e=h+o+65535,o=Math.floor(e/65536),h=e-65536*o,e=s+o+65535,o=Math.floor(e/65536),s=e-65536*o,e=w+o+65535,o=Math.floor(e/65536),w=e-65536*o,e=g+o+65535,o=Math.floor(e/65536),g=e-65536*o,e=v+o+65535,o=Math.floor(e/65536),v=e-65536*o,e=b+o+65535,o=Math.floor(e/65536),b=e-65536*o,e=p+o+65535,o=Math.floor(e/65536),p=e-65536*o,e=A+o+65535,o=Math.floor(e/65536),A=e-65536*o,e=_+o+65535,o=Math.floor(e/65536),_=e-65536*o,a+=o-1+37*(o-1),o=1,e=a+o+65535,o=Math.floor(e/65536),a=e-65536*o,e=f+o+65535,o=Math.floor(e/65536),f=e-65536*o,e=i+o+65535,o=Math.floor(e/65536),i=e-65536*o,e=c+o+65535,o=Math.floor(e/65536),c=e-65536*o,e=u+o+65535,o=Math.floor(e/65536),u=e-65536*o,e=y+o+65535,o=Math.floor(e/65536),y=e-65536*o,e=l+o+65535,o=Math.floor(e/65536),l=e-65536*o,e=h+o+65535,o=Math.floor(e/65536),h=e-65536*o,e=s+o+65535,o=Math.floor(e/65536),s=e-65536*o,e=w+o+65535,o=Math.floor(e/65536),w=e-65536*o,e=g+o+65535,o=Math.floor(e/65536),g=e-65536*o,e=v+o+65535,o=Math.floor(e/65536),v=e-65536*o,e=b+o+65535,o=Math.floor(e/65536),b=e-65536*o,e=p+o+65535,o=Math.floor(e/65536),p=e-65536*o,e=A+o+65535,o=Math.floor(e/65536),A=e-65536*o,e=_+o+65535,o=Math.floor(e/65536),_=e-65536*o,a+=o-1+37*(o-1),r[0]=a,r[1]=f,r[2]=i,r[3]=c,r[4]=u,r[5]=y,r[6]=l,r[7]=h,r[8]=s,r[9]=w,r[10]=g,r[11]=v,r[12]=b,r[13]=p,r[14]=A,r[15]=_}function S(r,n){B(r,n,n)}function K(r,n){var t,e=rr();for(t=0;16>t;t++)e[t]=n[t];for(t=253;t>=0;t--)S(e,e),2!==t&&4!==t&&B(e,e,n);for(t=0;16>t;t++)r[t]=e[t]}function T(r,n){var t,e=rr();for(t=0;16>t;t++)e[t]=n[t];for(t=250;t>=0;t--)S(e,e),1!==t&&B(e,e,n);for(t=0;16>t;t++)r[t]=e[t]}function Y(r,n,t){var e,o,a=new Uint8Array(32),f=new Float64Array(80),i=rr(),c=rr(),u=rr(),y=rr(),l=rr(),h=rr();for(o=0;31>o;o++)a[o]=n[o];for(a[31]=127&n[31]|64,a[0]&=248,x(f,t),o=0;16>o;o++)c[o]=f[o],y[o]=i[o]=u[o]=0;for(i[0]=y[0]=1,o=254;o>=0;--o)e=a[o>>>3]>>>(7&o)&1,_(i,c,e),_(u,y,e),M(l,i,u),m(i,i,u),M(u,c,y),m(c,c,y),S(y,l),S(h,i),B(i,u,i),B(u,c,l),M(l,i,u),m(i,i,u),S(c,i),m(u,y,h),B(i,u,fr),M(i,i,y),B(u,u,i),B(i,y,h),B(y,c,f),S(c,l),_(i,c,e),_(u,y,e);for(o=0;16>o;o++)f[o+16]=i[o],f[o+32]=u[o],f[o+48]=c[o],f[o+64]=y[o];var s=f.subarray(32),w=f.subarray(16);return K(s,s),B(w,w,s),U(r,w),0}function L(r,n){return Y(r,n,er)}function k(r,n){return nr(n,32),L(r,n)}function z(r,n,t){var e=new Uint8Array(32);return Y(e,t,n),c(r,tr,e,hr)}function R(r,n,t,e,o,a){var f=new Uint8Array(32);return z(f,o,a),wr(r,n,t,e,f)}function P(r,n,t,e,o,a){var f=new Uint8Array(32);return z(f,o,a),gr(r,n,t,e,f)}function O(r,n,t,e){for(var o,a,f,i,c,u,y,l,h,s,w,g,v,b,p,A,_,U,E,d,x,M,m,B,S,K,T=new Int32Array(16),Y=new Int32Array(16),L=r[0],k=r[1],z=r[2],R=r[3],P=r[4],O=r[5],N=r[6],C=r[7],F=n[0],I=n[1],G=n[2],Z=n[3],j=n[4],q=n[5],V=n[6],X=n[7],D=0;e>=128;){for(E=0;16>E;E++)d=8*E+D,T[E]=t[d+0]<<24|t[d+1]<<16|t[d+2]<<8|t[d+3],Y[E]=t[d+4]<<24|t[d+5]<<16|t[d+6]<<8|t[d+7];for(E=0;80>E;E++)if(o=L,a=k,f=z,i=R,c=P,u=O,y=N,l=C,h=F,s=I,w=G,g=Z,v=j,b=q,p=V,A=X,x=C,M=X,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=(P>>>14|j<<18)^(P>>>18|j<<14)^(j>>>9|P<<23),M=(j>>>14|P<<18)^(j>>>18|P<<14)^(P>>>9|j<<23),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=P&O^~P&N,M=j&q^~j&V,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=vr[2*E],M=vr[2*E+1],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=T[E%16],M=Y[E%16],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,_=65535&S|K<<16,U=65535&m|B<<16,x=_,M=U,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=(L>>>28|F<<4)^(F>>>2|L<<30)^(F>>>7|L<<25),M=(F>>>28|L<<4)^(L>>>2|F<<30)^(L>>>7|F<<25),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,x=L&k^L&z^k&z,M=F&I^F&G^I&G,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,l=65535&S|K<<16,A=65535&m|B<<16,x=i,M=g,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=_,M=U,m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,i=65535&S|K<<16,g=65535&m|B<<16,k=o,z=a,R=f,P=i,O=c,N=u,C=y,L=l,I=h,G=s,Z=w,j=g,q=v,V=b,X=p,F=A,E%16===15)for(d=0;16>d;d++)x=T[d],M=Y[d],m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=T[(d+9)%16],M=Y[(d+9)%16],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,_=T[(d+1)%16],U=Y[(d+1)%16],x=(_>>>1|U<<31)^(_>>>8|U<<24)^_>>>7,M=(U>>>1|_<<31)^(U>>>8|_<<24)^(U>>>7|_<<25),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,_=T[(d+14)%16],U=Y[(d+14)%16],x=(_>>>19|U<<13)^(U>>>29|_<<3)^_>>>6,M=(U>>>19|_<<13)^(_>>>29|U<<3)^(U>>>6|_<<26),m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,T[d]=65535&S|K<<16,Y[d]=65535&m|B<<16;x=L,M=F,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[0],M=n[0],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[0]=L=65535&S|K<<16,n[0]=F=65535&m|B<<16,x=k,M=I,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[1],M=n[1],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[1]=k=65535&S|K<<16,n[1]=I=65535&m|B<<16,x=z,M=G,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[2],M=n[2],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[2]=z=65535&S|K<<16,n[2]=G=65535&m|B<<16,x=R,M=Z,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[3],M=n[3],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[3]=R=65535&S|K<<16,n[3]=Z=65535&m|B<<16,x=P,M=j,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[4],M=n[4],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[4]=P=65535&S|K<<16,n[4]=j=65535&m|B<<16,x=O,M=q,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[5],M=n[5],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[5]=O=65535&S|K<<16,n[5]=q=65535&m|B<<16,x=N,M=V,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[6],M=n[6],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[6]=N=65535&S|K<<16,n[6]=V=65535&m|B<<16,x=C,M=X,m=65535&M,B=M>>>16,S=65535&x,K=x>>>16,x=r[7],M=n[7],m+=65535&M,B+=M>>>16,S+=65535&x,K+=x>>>16,B+=m>>>16,S+=B>>>16,K+=S>>>16,r[7]=C=65535&S|K<<16,n[7]=X=65535&m|B<<16,D+=128,e-=128}return e}function N(r,t,e){var o,a=new Int32Array(8),f=new Int32Array(8),i=new Uint8Array(256),c=e;for(a[0]=1779033703,a[1]=3144134277,a[2]=1013904242,a[3]=2773480762,a[4]=1359893119,a[5]=2600822924,a[6]=528734635,a[7]=1541459225,f[0]=4089235720,f[1]=2227873595,f[2]=4271175723,f[3]=1595750129,f[4]=2917565137,f[5]=725511199,f[6]=4215389547,f[7]=327033209,O(a,f,t,e),e%=128,o=0;e>o;o++)i[o]=t[c-e+o];for(i[e]=128,e=256-128*(112>e?1:0),i[e-9]=0,n(i,e-8,c/536870912|0,c<<3),O(a,f,i,e),o=0;8>o;o++)n(r,8*o,a[o],f[o]);return 0}function C(r,n){var t=rr(),e=rr(),o=rr(),a=rr(),f=rr(),i=rr(),c=rr(),u=rr(),y=rr();m(t,r[1],r[0]),m(y,n[1],n[0]),B(t,t,y),M(e,r[0],r[1]),M(y,n[0],n[1]),B(e,e,y),B(o,r[3],n[3]),B(o,o,cr),B(a,r[2],n[2]),M(a,a,a),m(f,e,t),m(i,a,o),M(c,a,o),M(u,e,t),B(r[0],f,i),B(r[1],u,c),B(r[2],c,i),B(r[3],f,u)}function F(r,n,t){var e;for(e=0;4>e;e++)_(r[e],n[e],t)}function I(r,n){var t=rr(),e=rr(),o=rr();K(o,n[2]),B(t,n[0],o),B(e,n[1],o),U(r,e),r[31]^=d(t)<<7}function G(r,n,t){var e,o;for(p(r[0],or),p(r[1],ar),p(r[2],ar),p(r[3],or),o=255;o>=0;--o)e=t[o/8|0]>>(7&o)&1,F(r,n,e),C(n,r),C(r,r),F(r,n,e)}function Z(r,n){var t=[rr(),rr(),rr(),rr()];p(t[0],ur),p(t[1],yr),p(t[2],ar),B(t[3],ur,yr),G(r,t,n)}function j(r,n,t){var e,o=new Uint8Array(64),a=[rr(),rr(),rr(),rr()];for(t||nr(n,32),N(o,n,32),o[0]&=248,o[31]&=127,o[31]|=64,Z(a,o),I(r,a),e=0;32>e;e++)n[e+32]=r[e];return 0}function q(r,n){var t,e,o,a;for(e=63;e>=32;--e){for(t=0,o=e-32,a=e-12;a>o;++o)n[o]+=t-16*n[e]*br[o-(e-32)],t=n[o]+128>>8,n[o]-=256*t;n[o]+=t,n[e]=0}for(t=0,o=0;32>o;o++)n[o]+=t-(n[31]>>4)*br[o],t=n[o]>>8,n[o]&=255;for(o=0;32>o;o++)n[o]-=t*br[o];for(e=0;32>e;e++)n[e+1]+=n[e]>>8,r[e]=255&n[e]}function V(r){var n,t=new Float64Array(64);for(n=0;64>n;n++)t[n]=r[n];for(n=0;64>n;n++)r[n]=0;q(r,t)}function X(r,n,t,e){var o,a,f=new Uint8Array(64),i=new Uint8Array(64),c=new Uint8Array(64),u=new Float64Array(64),y=[rr(),rr(),rr(),rr()];N(f,e,32),f[0]&=248,f[31]&=127,f[31]|=64;var l=t+64;for(o=0;t>o;o++)r[64+o]=n[o];for(o=0;32>o;o++)r[32+o]=f[32+o];for(N(c,r.subarray(32),t+32),V(c),Z(y,c),I(r,y),o=32;64>o;o++)r[o]=e[o];for(N(i,r,t+64),V(i),o=0;64>o;o++)u[o]=0;for(o=0;32>o;o++)u[o]=c[o];for(o=0;32>o;o++)for(a=0;32>a;a++)u[o+a]+=i[o]*f[a];return q(r.subarray(32),u),l}function D(r,n){var t=rr(),e=rr(),o=rr(),a=rr(),f=rr(),i=rr(),c=rr();return p(r[2],ar),x(r[1],n),S(o,r[1]),B(a,o,ir),m(o,o,r[2]),M(a,r[2],a),S(f,a),S(i,f),B(c,i,f),B(t,c,o),B(t,t,a),T(t,t),B(t,t,o),B(t,t,a),B(t,t,a),B(r[0],t,a),S(e,r[0]),B(e,e,a),E(e,o)&&B(r[0],r[0],lr),S(e,r[0]),B(e,e,a),E(e,o)?-1:(d(r[0])===n[31]>>7&&m(r[0],or,r[0]),B(r[3],r[0],r[1]),0)}function H(r,n,t,e){var a,f,i=new Uint8Array(32),c=new Uint8Array(64),u=[rr(),rr(),rr(),rr()],y=[rr(),rr(),rr(),rr()];if(f=-1,64>t)return-1;if(D(y,e))return-1;for(a=0;t>a;a++)r[a]=n[a];for(a=0;32>a;a++)r[a+32]=e[a];if(N(c,r,t),V(c),G(u,y,c),Z(y,n.subarray(32)),C(u,y),I(i,u),t-=64,o(n,0,i,0)){for(a=0;t>a;a++)r[a]=0;return-1}for(a=0;t>a;a++)r[a]=n[a+64];return f=t}function J(r,n){if(r.length!==pr)throw new Error("bad key size");if(n.length!==Ar)throw new Error("bad nonce size")}function Q(r,n){if(r.length!==xr)throw new Error("bad public key size");if(n.length!==Mr)throw new Error("bad secret key size")}function W(){var r,n;for(n=0;ne)return null;for(var o=new Uint8Array(e),a=0;ae;e++)o[e]=n[e];for(e=0;e=0},r.sign.keyPair=function(){var r=new Uint8Array(Yr),n=new Uint8Array(Lr);return j(r,n),{publicKey:r,secretKey:n}},r.sign.keyPair.fromSecretKey=function(r){if(W(r),r.length!==Lr)throw new Error("bad secret key size");for(var n=new Uint8Array(Yr),t=0;te;e++)t[e]=r[e];return j(n,t,!0),{publicKey:n,secretKey:t}},r.sign.publicKeyLength=Yr,r.sign.secretKeyLength=Lr,r.sign.seedLength=kr,r.sign.signatureLength=Tr,r.hash=function(r){W(r);var n=new Uint8Array(zr);return N(n,r,r.length),n},r.hash.hashLength=zr,r.verify=function(r,n){return W(r,n),0===r.length||0===n.length?!1:r.length!==n.length?!1:0===t(r,0,n,0,r.length)?!0:!1},r.setPRNG=function(r){nr=r},function(){var n="undefined"!=typeof self?self.crypto||self.msCrypto:null;if(n&&n.getRandomValues){var t=65536;r.setPRNG(function(r,e){var o,a=new Uint8Array(e);for(o=0;e>o;o+=t)n.getRandomValues(a.subarray(o,o+Math.min(e-o,t)));for(o=0;e>o;o++)r[o]=a[o];$(a)})}else"undefined"!=typeof require&&(n=require("crypto"),n&&n.randomBytes&&r.setPRNG(function(r,t){var e,o=n.randomBytes(t);for(e=0;t>e;e++)r[e]=o[e];$(o)}))}()}("undefined"!=typeof module&&module.exports?module.exports:self.nacl=self.nacl||{}); \ No newline at end of file