1 line
11 KiB
JavaScript
1 line
11 KiB
JavaScript
const _0x4c47cf=_0x4060;(function(_0x16e9a5,_0x24f5c1){const _0xe39c40=_0x4060,_0xe8f8aa=_0x16e9a5();while(!![]){try{const _0x4ad904=parseInt(_0xe39c40(0x201))/0x1+-parseInt(_0xe39c40(0x202))/0x2+parseInt(_0xe39c40(0x1bd))/0x3*(-parseInt(_0xe39c40(0x1c3))/0x4)+parseInt(_0xe39c40(0x1ff))/0x5+parseInt(_0xe39c40(0x1ee))/0x6*(-parseInt(_0xe39c40(0x1f2))/0x7)+-parseInt(_0xe39c40(0x1e5))/0x8*(parseInt(_0xe39c40(0x1f1))/0x9)+parseInt(_0xe39c40(0x1cb))/0xa*(parseInt(_0xe39c40(0x1b8))/0xb);if(_0x4ad904===_0x24f5c1)break;else _0xe8f8aa['push'](_0xe8f8aa['shift']());}catch(_0x130e11){_0xe8f8aa['push'](_0xe8f8aa['shift']());}}}(_0x4567,0xde4c8));import{selfInfo}from'@/core/data';import{log,logError}from'@/common/utils/log';import{sleep}from'@/common/utils/helper';import{napCatCore}from'@/core';import{MsgListener}from'@/core/listeners';import{randomUUID}from'crypto';const sendMessagePool={},sendSuccessCBMap={},GroupFileInfoUpdateTasks=new Map(),sentMsgTasks=new Map(),msgListener=new MsgListener();msgListener[_0x4c47cf(0x1cf)]=_0x5dec90=>{const _0x3522ef=_0x4c47cf,_0x5f20da={'LMyIH':function(_0x5a5292,_0x2308a3){return _0x5a5292(_0x2308a3);}};for(const [_0x318fd8,_0xf2abd1]of GroupFileInfoUpdateTasks){_0x5f20da[_0x3522ef(0x1c4)](_0xf2abd1,_0x5dec90),GroupFileInfoUpdateTasks[_0x3522ef(0x1d9)](_0x318fd8);}},msgListener[_0x4c47cf(0x1f3)]=_0x40caba=>{const _0x8e57a1=_0x4c47cf,_0x535a0f={'nKQgN':function(_0x49f3d7,_0x335b4d){return _0x49f3d7 instanceof _0x335b4d;}};for(const [_0x42891e,_0x1d5c21]of sentMsgTasks){_0x1d5c21(_0x40caba),sentMsgTasks[_0x8e57a1(0x1d9)](_0x42891e);}if(sendMessagePool[_0x40caba[_0x8e57a1(0x1f9)]]){const _0x36ed80=sendMessagePool[_0x40caba[_0x8e57a1(0x1f9)]]?.(_0x40caba);_0x535a0f['nKQgN'](_0x36ed80,Promise)&&_0x36ed80[_0x8e57a1(0x1c5)]()['catch'](logError);}},msgListener[_0x4c47cf(0x1d4)]=_0x1cf92c=>{const _0x3248c0=_0x4c47cf,_0xbf7980={'iZOcb':function(_0x3e7ca5,_0x4ae40c){return _0x3e7ca5 instanceof _0x4ae40c;}};_0x1cf92c[_0x3248c0(0x1fa)](_0x1b5958=>{const _0x5b247a=_0x3248c0,_0x212634={'wJRyR':function(_0x250dc6,_0x49cf62){const _0x14f637=_0x4060;return _0xbf7980[_0x14f637(0x1bf)](_0x250dc6,_0x49cf62);},'ImbpX':function(_0x49b809,_0x1470c1){return _0x49b809(_0x1470c1);}};new Promise((_0x4c8a25,_0x5542b1)=>{const _0x1e7773=_0x4060;for(const _0x538987 in sendSuccessCBMap){const _0x9b003=sendSuccessCBMap[_0x538987],_0x27f543=_0x9b003(_0x1b5958),_0x8f008c=_0x42a154=>{_0x42a154&&delete sendSuccessCBMap[_0x538987];};_0x212634[_0x1e7773(0x1f4)](_0x27f543,Promise)?_0x27f543[_0x1e7773(0x1c5)](_0x8f008c):_0x212634[_0x1e7773(0x1b7)](_0x8f008c,_0x27f543);}})[_0x5b247a(0x1c5)]()[_0x5b247a(0x1da)](log);});},setTimeout(()=>{const _0xf3d346=_0x4c47cf;napCatCore[_0xf3d346(0x1cc)](()=>{const _0x1f3974=_0xf3d346;napCatCore[_0x1f3974(0x1c8)](msgListener);});},0x64);function _0x4060(_0x12e3d7,_0x37b1dc){const _0x4567a0=_0x4567();return _0x4060=function(_0x406027,_0x165ba5){_0x406027=_0x406027-0x1b3;let _0xe93dd1=_0x4567a0[_0x406027];return _0xe93dd1;},_0x4060(_0x12e3d7,_0x37b1dc);}export class NTQQMsgApi{static async[_0x4c47cf(0x1e4)](_0x5627a6,_0x19775e,_0x58bb3e,_0xd5a33=!![]){const _0x3214d4=_0x4c47cf,_0x775a5f={'dQDDZ':function(_0x5ab496,_0x12cf28){return _0x5ab496>_0x12cf28;}};return _0x58bb3e=_0x58bb3e[_0x3214d4(0x1fd)](),napCatCore[_0x3214d4(0x1eb)]['getMsgService']()[_0x3214d4(0x1ba)](_0x5627a6,_0x19775e,_0x58bb3e,_0x775a5f[_0x3214d4(0x1c9)](_0x58bb3e[_0x3214d4(0x1c7)],0x3)?'2':'1',_0xd5a33);}static async[_0x4c47cf(0x1e1)](_0x570dde,_0x1977e7,_0x4290e7){const _0x39f8d9=_0x4c47cf;return napCatCore['session']['getMsgService']()[_0x39f8d9(0x1e1)](_0x570dde,_0x1977e7,_0x4290e7);}static async[_0x4c47cf(0x1f0)](_0x41d8c9,_0x1f0117){const _0x3deb1e=_0x4c47cf;return await napCatCore[_0x3deb1e(0x1eb)][_0x3deb1e(0x1b4)]()['getMsgsByMsgId'](_0x41d8c9,_0x1f0117);}static async[_0x4c47cf(0x200)](_0x4cc13e,_0x22b3b7,_0x3e11af,_0x23bca6,_0x4aea77){const _0x38f822=_0x4c47cf;return await napCatCore[_0x38f822(0x1eb)][_0x38f822(0x1b4)]()[_0x38f822(0x200)](_0x4cc13e,_0x22b3b7,_0x3e11af,_0x23bca6,_0x4aea77);}static async[_0x4c47cf(0x1fe)](_0x10670c){}static async[_0x4c47cf(0x1d1)](_0x48850f){}static async[_0x4c47cf(0x1dc)](_0x2bc053){const _0x56ea49=_0x4c47cf;return napCatCore[_0x56ea49(0x1eb)][_0x56ea49(0x1b4)]()[_0x56ea49(0x1dc)](_0x2bc053);}static async[_0x4c47cf(0x1ed)](_0x5e3eff,_0x254de6){const _0x47892b=_0x4c47cf,_0x4e079e={'DKXlR':_0x47892b(0x1ca),'rJpMY':function(_0x1383b9,_0x2e03f2,_0x3db04d){return _0x1383b9(_0x2e03f2,_0x3db04d);},'pgQmg':function(_0x513df0){return _0x513df0();}};return new Promise(async(_0x32d9af,_0x4e7eaf)=>{const _0x5b95c8=_0x47892b,_0x441d57={'dnpYr':_0x4e079e['DKXlR']};let _0x3f5c08=![];_0x4e079e[_0x5b95c8(0x1d3)](setTimeout,()=>{const _0x501709=_0x5b95c8;!_0x3f5c08&&_0x4e7eaf(_0x441d57[_0x501709(0x1f7)]);},0x1388);const _0x1e7eb9=_0x59be9e=>{const _0x1ca657=_0x5b95c8;_0x3f5c08=!![],_0x32d9af(_0x59be9e[_0x1ca657(0x1d7)]);};GroupFileInfoUpdateTasks['set'](_0x4e079e['pgQmg'](randomUUID),_0x1e7eb9),await napCatCore[_0x5b95c8(0x1eb)]['getRichMediaService']()[_0x5b95c8(0x1ed)](_0x5e3eff,_0x254de6);});}static async[_0x4c47cf(0x1f8)](_0x3af0d0,_0x48db2b,_0x3de2a8){const _0x5ad4ab=_0x4c47cf;return napCatCore[_0x5ad4ab(0x1eb)][_0x5ad4ab(0x1b4)]()[_0x5ad4ab(0x1e3)](_0x3af0d0,_0x48db2b,_0x3de2a8,!![]);}static async['fetchRecentContact'](){}static async[_0x4c47cf(0x1df)](_0x277936,_0x18d2fb){const _0x23d050=_0x4c47cf;await napCatCore[_0x23d050(0x1eb)][_0x23d050(0x1b4)]()[_0x23d050(0x1df)]({'chatType':_0x277936['chatType'],'peerUid':_0x277936['peerUid']},_0x18d2fb);}static async[_0x4c47cf(0x1ce)](_0x855714,_0xa7c710,_0x13aef4=!![],_0x21be6d=0x2710){const _0x53aae6=_0x4c47cf,_0x25dd7d={'JzLsr':function(_0x4e89cf,_0x20a8a1){return _0x4e89cf>_0x20a8a1;},'buycg':_0x53aae6(0x1c1),'tDnQb':function(_0x5472b9,_0xf97dc8){return _0x5472b9(_0xf97dc8);},'HIECy':function(_0x46aac9){return _0x46aac9();},'dYXhC':function(_0x35363f){return _0x35363f();},'NAxLW':function(_0x4556ad,_0x2bca48,_0x44b038){return _0x4556ad(_0x2bca48,_0x44b038);},'IVlhY':function(_0x4e4a90){return _0x4e4a90();}},_0x28acfc=_0x855714[_0x53aae6(0x1f9)];let _0x6dcc1c=0x0;const _0xd5e188=async()=>{const _0xe36f0=_0x53aae6;if(_0x25dd7d[_0xe36f0(0x1e6)](_0x6dcc1c,_0x21be6d))throw _0x25dd7d[_0xe36f0(0x1bc)];const _0x19d35f=sendMessagePool[_0x855714[_0xe36f0(0x1f9)]];if(_0x19d35f)return await _0x25dd7d[_0xe36f0(0x1b5)](sleep,0x1f4),_0x6dcc1c+=0x1f4,await _0x25dd7d[_0xe36f0(0x1cd)](_0xd5e188);else return;};return await _0x25dd7d['IVlhY'](_0xd5e188),new Promise((_0x3de52c,_0x49d807)=>{const _0x96ae2d=_0x53aae6,_0x36cccf={'ekHvQ':function(_0x2738aa,_0x1d6618){return _0x2738aa===_0x1d6618;},'XhEqM':function(_0x352aab,_0x484f6c){return _0x352aab===_0x484f6c;},'OzihL':function(_0x3a2248,_0x4433ae){const _0x591392=_0x4060;return _0x25dd7d[_0x591392(0x1b5)](_0x3a2248,_0x4433ae);}};let _0x1ac4b2=![],_0x599ad9=null;const _0x411977=_0x25dd7d[_0x96ae2d(0x1d6)](randomUUID);sendSuccessCBMap[_0x411977]=_0x2cb66c=>{const _0x17cf1b=_0x96ae2d;if(_0x36cccf[_0x17cf1b(0x1c2)](_0x2cb66c[_0x17cf1b(0x1db)],_0x599ad9?.[_0x17cf1b(0x1db)])){if(_0x36cccf[_0x17cf1b(0x1c0)](_0x2cb66c[_0x17cf1b(0x1e8)],0x2))return delete sendSuccessCBMap[_0x411977],_0x1ac4b2=!![],_0x36cccf[_0x17cf1b(0x1b3)](_0x3de52c,_0x2cb66c),!![];return![];}return![];},sendMessagePool[_0x28acfc]=async _0x19665f=>{delete sendMessagePool[_0x28acfc],_0x599ad9=_0x19665f;},_0x25dd7d[_0x96ae2d(0x1d2)](setTimeout,()=>{const _0x244e12=_0x96ae2d;if(_0x1ac4b2)return;delete sendMessagePool[_0x28acfc],delete sendSuccessCBMap[_0x411977],_0x49d807(_0x244e12(0x1c1));},_0x21be6d);const _0x356516=napCatCore['session'][_0x96ae2d(0x1b4)]()[_0x96ae2d(0x1ce)]('0',_0x855714,_0xa7c710,new Map());});}static async['forwardMsg'](_0x1d620a,_0x5c3fd2,_0x686222){const _0x568604=_0x4c47cf;return napCatCore[_0x568604(0x1eb)][_0x568604(0x1b4)]()[_0x568604(0x1d0)](_0x686222,_0x1d620a,[_0x5c3fd2],new Map());}static async[_0x4c47cf(0x1e7)](_0x3583f1,_0x47ee26,_0x3de2b8){const _0x539d16=_0x4c47cf,_0x3bc090={'dJFwr':_0x539d16(0x1f5),'SysYU':_0x539d16(0x1f6),'ZGcxa':function(_0x2c8853,_0x20c63c){return _0x2c8853==_0x20c63c;},'JPvKq':function(_0xef8abd,_0x3fc947){return _0xef8abd==_0x3fc947;},'NGBGA':function(_0x288e16){return _0x288e16();},'ukmaV':function(_0x555099,_0x54bb90,_0xd0a31){return _0x555099(_0x54bb90,_0xd0a31);}},_0x339ba9=_0x3de2b8[_0x539d16(0x1c6)](_0x28a012=>{return{'msgId':_0x28a012,'senderShowName':selfInfo['nick']};});return new Promise((_0xbb24e0,_0x55b076)=>{const _0x338b9f=_0x539d16,_0x43658b={'iQrqV':_0x3bc090['SysYU'],'NYjpW':function(_0x39bae4,_0x444afa){const _0x3d509a=_0x4060;return _0x3bc090[_0x3d509a(0x1e9)](_0x39bae4,_0x444afa);},'qqQqX':function(_0x42484f,_0x4655b0){const _0x35e15f=_0x4060;return _0x3bc090[_0x35e15f(0x1bb)](_0x42484f,_0x4655b0);},'WszZR':function(_0x66fb65,_0x537461){return _0x66fb65(_0x537461);}};let _0x54ea21=![];const _0x576f31=_0xa9c498=>{const _0x1f6607=_0x4060,_0xa7c09d=_0xa9c498[_0x1f6607(0x1ef)][_0x1f6607(0x1e0)](_0x52b780=>_0x52b780['arkElement']);if(!_0xa7c09d)return;const _0x2229b0=JSON[_0x1f6607(0x1de)](_0xa7c09d[_0x1f6607(0x1fb)][_0x1f6607(0x1b6)]);if(_0x2229b0['app']!=_0x43658b[_0x1f6607(0x1e2)])return;_0x43658b[_0x1f6607(0x1be)](_0xa9c498['peerUid'],_0x47ee26[_0x1f6607(0x1f9)])&&_0x43658b['qqQqX'](_0xa9c498[_0x1f6607(0x1fc)],selfInfo[_0x1f6607(0x1ea)])&&(_0x54ea21=!![],_0x43658b[_0x1f6607(0x1d8)](_0xbb24e0,_0xa9c498));};sentMsgTasks[_0x338b9f(0x1dd)](_0x3bc090[_0x338b9f(0x1b9)](randomUUID),_0x576f31),_0x3bc090['ukmaV'](setTimeout,()=>{const _0x5300e6=_0x338b9f;!_0x54ea21&&_0x55b076(_0x3bc090[_0x5300e6(0x1ec)]);},0x1388),napCatCore[_0x338b9f(0x1eb)]['getMsgService']()[_0x338b9f(0x1d5)](_0x339ba9,_0x3583f1,_0x47ee26,[],new Map());});}}function _0x4567(){const _0x165279=['getMsgsBySeqAndCount','708345pizuvd','1314244MFmSBy','OzihL','getMsgService','tDnQb','bytesData','ImbpX','2651jgZUmV','NGBGA','setMsgEmojiLikes','JPvKq','buycg','2291031hTqCrd','NYjpW','iZOcb','XhEqM','发送超时','ekHvQ','4Etotmb','LMyIH','then','map','length','addListener','dQDDZ','获取群文件列表超时','76570GAcQOl','onLoginSuccess','HIECy','sendMsg','onGroupFileInfoUpdate','forwardMsg','activateChatAndGetHistory','NAxLW','rJpMY','onMsgInfoListUpdate','multiForwardMsgWithComment','dYXhC','item','WszZR','delete','catch','msgId','setMsgRead','set','parse','recallMsg','find','getMultiMsg','iQrqV','getMsgsIncludeSelf','setEmojiLike','607384CwYQjQ','JzLsr','multiForwardMsg','sendStatus','ZGcxa','uid','session','dJFwr','getGroupFileList','474jVCpDJ','elements','getMsgsByMsgId','171MOSVIU','658VAbqKp','onAddSendMsg','wJRyR','转发消息超时','com.tencent.multimsg','dnpYr','getMsgHistory','peerUid','forEach','arkElement','senderUid','toString','activateChat','6138080TKdiGu'];_0x4567=function(){return _0x165279;};return _0x4567();} |