tvbox/cat/js/lib/quark.js
2023-11-16 14:48:39 +08:00

1 line
4.4 KiB
JavaScript

(function(_0x4c5c03,_0x45bbe8){const _0x3ea5c5=_0x3957,_0x32f017=_0x4c5c03();while(!![]){try{const _0x3c6532=-parseInt(_0x3ea5c5(0xb9))/0x1*(parseInt(_0x3ea5c5(0xc9))/0x2)+-parseInt(_0x3ea5c5(0xd2))/0x3+parseInt(_0x3ea5c5(0xce))/0x4*(-parseInt(_0x3ea5c5(0xbb))/0x5)+-parseInt(_0x3ea5c5(0xca))/0x6*(-parseInt(_0x3ea5c5(0xd4))/0x7)+parseInt(_0x3ea5c5(0xc2))/0x8+-parseInt(_0x3ea5c5(0xba))/0x9+parseInt(_0x3ea5c5(0xcb))/0xa*(parseInt(_0x3ea5c5(0xb6))/0xb);if(_0x3c6532===_0x45bbe8)break;else _0x32f017['push'](_0x32f017['shift']());}catch(_0xb33a49){_0x32f017['push'](_0x32f017['shift']());}}}(_0x32bf,0xcc44f));const _0x450f56=(function(){let _0x21c5bf=!![];return function(_0x21cea6,_0x391ea8){const _0x205406=_0x21c5bf?function(){if(_0x391ea8){const _0x51f9aa=_0x391ea8['apply'](_0x21cea6,arguments);return _0x391ea8=null,_0x51f9aa;}}:function(){};return _0x21c5bf=![],_0x205406;};}()),_0x54a78c=_0x450f56(this,function(){const _0x4c865d=_0x3957;let _0x27bd2f;try{const _0x2345fb=Function(_0x4c865d(0xc7)+_0x4c865d(0xc3)+('{}.constru'+_0x4c865d(0xb5)+_0x4c865d(0xbd)+'\x20)')+');');_0x27bd2f=_0x2345fb();}catch(_0x401ad4){_0x27bd2f=window;}const _0x1204fc=_0x27bd2f['console']=_0x27bd2f['console']||{},_0x505caf=[_0x4c865d(0xbe),'warn',_0x4c865d(0xc1),'error','exception',_0x4c865d(0xc6),_0x4c865d(0xb7)];for(let _0x30ac70=0x0;_0x30ac70<_0x505caf[_0x4c865d(0xc4)];_0x30ac70++){const _0x308b73=_0x450f56[_0x4c865d(0xb2)+'r'][_0x4c865d(0xcf)][_0x4c865d(0xcd)](_0x450f56),_0x20f0f9=_0x505caf[_0x30ac70],_0x140884=_0x1204fc[_0x20f0f9]||_0x308b73;_0x308b73['__proto__']=_0x450f56[_0x4c865d(0xcd)](_0x450f56),_0x308b73[_0x4c865d(0xd3)]=_0x140884[_0x4c865d(0xd3)][_0x4c865d(0xcd)](_0x140884),_0x1204fc[_0x20f0f9]=_0x308b73;}});_0x54a78c();import{_}from'assets://js/lib/cat.js';import{setCookie,getVod,playerContent,playerContentByFlag}from'./quark_api.js';const quarkPattern=/pan.quark.cn\/s\/([^\/\?#]+)/;async function initQuark(_0x507ed0){await setCookie(_0x507ed0);}async function detailContent(_0x3c0bde){const _0x551b3d=_0x3957;let _0x3a59a7=_0x3c0bde['match'](quarkPattern),_0x1ba526=await parseVod(_0x3a59a7,_0x3c0bde);const _0x14294c={};_0x14294c[_0x551b3d(0xc8)]=[_0x1ba526];let _0x27eeb=JSON[_0x551b3d(0xbc)](_0x14294c);return console['debug'](_0x27eeb),_0x27eeb;}async function parseVod(_0x2f218d,_0x3c8dfe){if(_['isEmpty'](_0x2f218d))return{};let _0x51f8dd=_0x2f218d[0x1];return await getVod(_0x51f8dd,_0x3c8dfe);}async function playContent(_0x25f4bc,_0x1327ee,_0x1c091b){const _0xeed556=_0x3957;let _0x2e077b=_0x1327ee[_0xeed556(0xc0)]('+');_0x25f4bc=_0x25f4bc['split']('#')[0x0];let _0x2a0229=_0x25f4bc=='原画'?await playerContent(_0x2e077b):await playerContentByFlag(_0x2e077b,_0x25f4bc);return console[_0xeed556(0xcc)](_0xeed556(0xb3)+'ontent----'+'---'),console[_0xeed556(0xcc)](_0x2a0229),_0x2a0229;}function _0x32bf(){const _0x5d4548=['prototype','match','vod_play_u','2078325FdacNT','toString','7vAhLMH','constructo','-----playC','isEmpty','ctor(\x22retu','10586785pRxyHq','trace','join','3257WjWMrY','13754799bEqCTL','835LkOWae','stringify','rn\x20this\x22)(','log','$$$','split','info','8829440UaBHOS','nction()\x20','length','push','table','return\x20(fu','list','122naccBu','1506594qXMmDN','30yLHADS','debug','bind','23608tdvGOH'];_0x32bf=function(){return _0x5d4548;};return _0x32bf();}function detailContentVodPlayFrom(_0x4017ee){const _0x2119b1=_0x3957;let _0x2baf78=[];if(_0x4017ee['length']<0x2)return['原画','普画'][_0x2119b1(0xb8)](_0x2119b1(0xbf));for(let _0x58f659=0x1;_0x58f659<=_0x4017ee[_0x2119b1(0xc4)];_0x58f659++){_0x2baf78[_0x2119b1(0xc5)]('原画#'+_0x58f659),_0x2baf78[_0x2119b1(0xc5)]('普画#'+_0x58f659);}return _0x2baf78[_0x2119b1(0xb8)](_0x2119b1(0xbf));}async function detailContentVodPlayUrl(_0x57cee4){const _0x28fd9b=_0x3957;console[_0x28fd9b(0xcc)](_0x57cee4);let _0x3807d8=[];for(var _0x2abc63 of _0x57cee4){let _0xdac588=_0x2abc63[_0x28fd9b(0xd0)](quarkPattern);console[_0x28fd9b(0xcc)](_0xdac588);if(!_[_0x28fd9b(0xb4)](_0xdac588)){let _0x581274=await parseVod(_0xdac588,_0x2abc63);_0x3807d8[_0x28fd9b(0xc5)](_0x581274[_0x28fd9b(0xd1)+'rl']);}}return _0x3807d8[_0x28fd9b(0xb8)](_0x28fd9b(0xbf));}function _0x3957(_0x93218d,_0x328719){const _0x34dd0c=_0x32bf();return _0x3957=function(_0x54a78c,_0x450f56){_0x54a78c=_0x54a78c-0xb2;let _0xc784f1=_0x34dd0c[_0x54a78c];return _0xc784f1;},_0x3957(_0x93218d,_0x328719);}export{initQuark,detailContent,playContent,detailContentVodPlayFrom,detailContentVodPlayUrl};