|
|
-`);let s=xE.HmacSHA256(i,this.PRIVATEKEY);return xE.enc.Base64.stringify(s)}_utc(){return Math.round(Date.now()/1e3)}_isNumber(t){return t!==null&&(typeof t=="number"&&!isNaN(t-0)||typeof t=="object"&&t.constructor===Number)}_isString(t){return typeof t=="string"}genSigWithUserbuf(t,n,r){let o=this._utc(),i={"TLS.ver":"2.0","TLS.identifier":t,"TLS.sdkappid":this.SDKAPPID,"TLS.time":o,"TLS.expire":n},s="";if(r!=null){let g=this.base64encode(r);i["TLS.userbuf"]=g,s=this._hmacsha256(t,o,n,g)}else s=this._hmacsha256(t,o,n,null);i["TLS.sig"]=s;let u=JSON.stringify(i),d=VA.deflateSync(this.newBuffer(u)).toString("base64"),f=this.escape(d);return console.log("ret="+f),f}validate(t){let n=this.decode(t),r=VA.inflateSync(n);console.log("validate ret="+r)}}const Dbe=604800;function Ebe(e){const{SDKAppID:t,secretKey:n,userID:r}=e,i=new kbe(t,n,Dbe).genTestUserSig(r);return{SDKAppID:t,userSig:i}}const Abe=LY({components:[oY,EY,wY,jK,dK,TY]}),Ig=bN.parse(location.search),u0=bN.parse(location.hash.split("?")[1]),Lbe=Ig.Authorization||u0.Authorization||"";sessionStorage.setItem("Authorization",Lbe);sessionStorage.setItem("platform",Ig.platform||u0.platform||"");console.log(!1,"false");const P3=Ig.appId||u0.appId?1400805079:1400799837,Obe=Ig.secretKey||u0.secretKey?"c5f4ea6140128a36c842990446a2c89249ab886b5e1ea6893555aa635a0b3c30":"37bfb220843e25e78768cadd0dc06756e460e55bd631354930a4149565a1d0c9",zA=Ig.userID,ow=LI.init({SDKAppID:P3});ow.use(F_e);ow.login({userID:zA,userSig:Ebe({SDKAppID:P3,secretKey:Obe,userID:zA}).userSig});w7(fF).use(Abe).use(hF).use(ow).mount("#app");
|
|
|
+`);let s=xE.HmacSHA256(i,this.PRIVATEKEY);return xE.enc.Base64.stringify(s)}_utc(){return Math.round(Date.now()/1e3)}_isNumber(t){return t!==null&&(typeof t=="number"&&!isNaN(t-0)||typeof t=="object"&&t.constructor===Number)}_isString(t){return typeof t=="string"}genSigWithUserbuf(t,n,r){let o=this._utc(),i={"TLS.ver":"2.0","TLS.identifier":t,"TLS.sdkappid":this.SDKAPPID,"TLS.time":o,"TLS.expire":n},s="";if(r!=null){let g=this.base64encode(r);i["TLS.userbuf"]=g,s=this._hmacsha256(t,o,n,g)}else s=this._hmacsha256(t,o,n,null);i["TLS.sig"]=s;let u=JSON.stringify(i),d=VA.deflateSync(this.newBuffer(u)).toString("base64"),f=this.escape(d);return console.log("ret="+f),f}validate(t){let n=this.decode(t),r=VA.inflateSync(n);console.log("validate ret="+r)}}const Dbe=604800;function Ebe(e){const{SDKAppID:t,secretKey:n,userID:r}=e,i=new kbe(t,n,Dbe).genTestUserSig(r);return{SDKAppID:t,userSig:i}}const Abe=LY({components:[oY,EY,wY,jK,dK,TY]}),Ig=bN.parse(location.search),u0=bN.parse(location.hash.split("?")[1]),Lbe=Ig.Authorization||u0.Authorization||"";sessionStorage.setItem("Authorization",Lbe);sessionStorage.setItem("platform",Ig.platform||u0.platform||"");console.log(!1,"false");const P3=Ig.appId||u0.appId||1400805079,Obe=Ig.secretKey||u0.secretKey||"c5f4ea6140128a36c842990446a2c89249ab886b5e1ea6893555aa635a0b3c30",zA=Ig.userID,ow=LI.init({SDKAppID:P3});ow.use(F_e);ow.login({userID:zA,userSig:Ebe({SDKAppID:P3,secretKey:Obe,userID:zA}).userSig});w7(fF).use(Abe).use(hF).use(ow).mount("#app");
|