Built motion from commit 1038d87.|0.0.141
[motion.git] / server / config / license / license.service.js
index 1ba8226..d937f4e 100644 (file)
@@ -1 +1 @@
-var _0x850e=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x63\x6F\x6D\x70\x6F\x73\x61\x62\x6C\x65\x2D\x6D\x69\x64\x64\x6C\x65\x77\x61\x72\x65","\x6D\x6F\x6D\x65\x6E\x74","\x63\x72\x79\x70\x74\x6F","\x75\x74\x69\x6C","\x6F\x73","\x2E\x2E\x2F\x65\x6E\x76\x69\x72\x6F\x6E\x6D\x65\x6E\x74","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x54\x65\x6C\x65\x70\x68\x6F\x6E\x65","\x53\x65\x74\x74\x69\x6E\x67\x73","\x44\x45\x4D\x4F\x20\x4C\x49\x43\x45\x4E\x53\x45","\x70\x6C\x61\x74\x66\x6F\x72\x6D","\x6C\x69\x6E\x75\x78","\x6F\x75\x74\x70\x75\x74","\x64\x6D\x69\x64\x65\x63\x6F\x64\x65\x20\x2D\x2D\x73\x74\x72\x69\x6E\x67\x20\x73\x79\x73\x74\x65\x6D\x2D\x75\x75\x69\x64","\x73\x6C\x69\x63\x65","\x0A","\x73\x70\x6C\x69\x74","\x62\x6C\x6B\x69\x64\x20\x2D\x67\x20\x26\x26\x20\x62\x6C\x6B\x69\x64","\x6D\x61\x74\x63\x68","\x74\x6F\x4C\x6F\x77\x65\x72\x43\x61\x73\x65","\x65\x78\x65\x63","\x6D\x61\x70","\x75\x75\x69\x64","\x63\x61\x74\x63\x68","\x6C\x69\x63\x65\x6E\x73\x65","\x70\x61\x72\x73\x65","\x63\x68\x61\x74","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x73\x70\x72\x65\x61\x64","\x66\x69\x6E\x64\x4F\x72\x43\x72\x65\x61\x74\x65","\x75\x73\x65","\x6D\x61\x69\x6C","\x66\x61\x78","\x65\x78\x70\x69\x72\x61\x74\x69\x6F\x6E","\x69\x73\x53\x61\x6D\x65\x4F\x72\x42\x65\x66\x6F\x72\x65","\x75\x73\x65\x72\x73","\x4D\x61\x78\x69\x6D\x75\x6D\x20\x75\x73\x65\x72\x73\x20\x6C\x69\x6D\x69\x74\x20\x68\x61\x76\x65\x20\x62\x65\x65\x6E\x20\x72\x65\x61\x63\x68\x65\x64","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x61\x64\x6D\x69\x6E","\x75\x73\x65\x72","\x63\x6F\x75\x6E\x74","\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73","\x4D\x61\x78\x69\x6D\x75\x6D\x20\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73\x20\x6C\x69\x6D\x69\x74\x20\x68\x61\x76\x65\x20\x62\x65\x65\x6E\x20\x72\x65\x61\x63\x68\x65\x64","\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65","\x72\x6F\x6C\x65","\x61\x67\x65\x6E\x74","\x6F\x6E\x6C\x69\x6E\x65","\x61\x67\x65\x6E\x74\x73","\x2D","\x61\x65\x73\x2D\x32\x35\x36\x2D\x63\x74\x72","\x25\x73\x3A\x25\x73\x3A\x25\x73","\x66\x6F\x72\x6D\x61\x74","\x63\x72\x65\x61\x74\x65\x44\x65\x63\x69\x70\x68\x65\x72","\x62\x61\x73\x65\x36\x34","\x75\x74\x66\x38","\x75\x70\x64\x61\x74\x65","\x66\x69\x6E\x61\x6C","\x67\x65\x74\x55\x75\x69\x64","\x69\x73\x56\x61\x6C\x69\x64\x44\x61\x74\x65","\x69\x73\x55\x73\x65\x72\x73\x4C\x69\x6D\x69\x74","\x69\x73\x54\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73\x4C\x69\x6D\x69\x74","\x68\x61\x73\x43\x68\x61\x74","\x68\x61\x73\x4D\x61\x69\x6C","\x68\x61\x73\x46\x61\x78","\x69\x73\x56\x61\x6C\x69\x64\x41\x67\x65\x6E\x74","\x64\x65\x6D\x6F\x4C\x69\x63\x65\x6E\x73\x65","\x64\x65\x63\x72\x79\x70\x74"];_0x850e[0];var compose=require(_0x850e[1]);var moment=require(_0x850e[2]);var crypto=require(_0x850e[3]);var util=require(_0x850e[4]);var os=require(_0x850e[5]);var config=require(_0x850e[6]);var User=require(_0x850e[8])[_0x850e[7]];var Telephone=require(_0x850e[8])[_0x850e[9]];var Settings=require(_0x850e[8])[_0x850e[10]];var demoLicense={users:1,agents:1,telephones:0,chat:false,mail:false,fax:false,description:_0x850e[11]};function getUuid(){if(os[_0x850e[12]]()!==_0x850e[13]){var _0xceaexc=exec(_0x850e[15],{silent:true})[_0x850e[14]];var _0xceaexd=_0xceaexc[_0x850e[18]](_0x850e[17])[_0x850e[16]](0,-1);return _0xceaexd[0]}else {var _0xceaexc=exec(_0x850e[19],{silent:true})[_0x850e[14]];var _0xceaexd=_0xceaexc[_0x850e[18]](_0x850e[17])[_0x850e[16]](0,-1)[_0x850e[23]](function(_0xceaexe){var _0xceaexf,_0xceaex10,_0xceaexd;_0xceaex10= new RegExp(/(\w+)\=\"([^\"]+)/g);_0xceaexf={partition:_0xceaexe[_0x850e[20]](/^(\S+)\:\ /)[1]};while(_0xceaexd=_0xceaex10[_0x850e[22]](_0xceaexe)){_0xceaexf[_0xceaexd[1][_0x850e[21]]()]=_0xceaexd[2]};return _0xceaexf});return _0xceaexd[0][_0x850e[24]]}}function hasChat(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){var _0xceaex17=null,_0xceaex18=false;if(_0xceaex16[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex16[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};_0xceaex18=_0xceaex17[_0x850e[28]];if(!_0xceaex18){return _0xceaex13[_0x850e[29]](403)};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function hasMail(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){var _0xceaex17=null,_0xceaex1a=false;if(_0xceaex16[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex16[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};_0xceaex1a=_0xceaex17[_0x850e[33]];if(!_0xceaex1a){return _0xceaex13[_0x850e[29]](403)};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function hasFax(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){var _0xceaex17=null,_0xceaex1c=false;if(_0xceaex16[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex16[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};_0xceaex1c=_0xceaex17[_0x850e[34]];if(!_0xceaex1c){return _0xceaex13[_0x850e[29]](403)};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function isValidDate(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){var _0xceaex17=null,_0xceaex1e=false;if(_0xceaex16[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex16[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17);if(moment()[_0x850e[36]](_0xceaex17[_0x850e[35]])){_0xceaex1e=true}};if(!_0xceaex1e){return _0xceaex13[_0x850e[29]](403)};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function isUsersLimit(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){var _0xceaex20;return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){_0xceaex20=_0xceaex16;return User[_0x850e[44]]({where:{$or:[{role:_0x850e[42]},{role:_0x850e[43]}]}})})[_0x850e[41]](function(_0xceaex21){var _0xceaex17=null,_0xceaex22=false;if(_0xceaex20[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex20[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};if(_0xceaex17[_0x850e[37]]>_0xceaex21){_0xceaex22=true};if(!_0xceaex22){return _0xceaex13[_0x850e[40]](403)[_0x850e[39]]({message:_0x850e[38]})};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function isTelephonesLimit(){return compose()[_0x850e[32]](function(_0xceaex12,_0xceaex13,_0xceaex14){var _0xceaex20;return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){_0xceaex20=_0xceaex16;return User[_0x850e[44]]({where:{role:_0x850e[47]}})})[_0x850e[41]](function(_0xceaex24){var _0xceaex17=null,_0xceaex22=false;if(_0xceaex20[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex20[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};if(_0xceaex17[_0x850e[45]]>_0xceaex24){_0xceaex22=true};if(!_0xceaex22){return _0xceaex13[_0x850e[40]](403)[_0x850e[39]]({message:_0x850e[46]})};return _0xceaex14()})[_0x850e[25]](function(_0xceaex15){return _0xceaex14(_0xceaex15)})})}function isValidAgent(){return function(_0xceaex26){var _0xceaex20;var _0xceaex27=false;if(_0xceaex26[_0x850e[48]]===_0x850e[42]||_0xceaex26[_0x850e[48]]===_0x850e[43]||(_0xceaex26[_0x850e[48]]===_0x850e[49]&&_0xceaex26[_0x850e[50]])){_0xceaex27=true};return Settings[_0x850e[31]]({where:{id:1}})[_0x850e[30]](function(_0xceaex16){_0xceaex20=_0xceaex16;return User[_0x850e[44]]({where:{role:_0x850e[49],online:true}})})[_0x850e[41]](function(_0xceaex28){var _0xceaex17=null;if(_0xceaex20[_0x850e[26]]){_0xceaex17=decrypt(_0xceaex20[_0x850e[26]]);_0xceaex17=JSON[_0x850e[27]](_0xceaex17)}else {_0xceaex17=demoLicense};if(_0xceaex17[_0x850e[51]]>_0xceaex28){_0xceaex27=true};return _0xceaex27})}}function decrypt(_0xceaex2a){var _0xceaex2b=getUuid();var _0xceaex2c=_0xceaex2b[_0x850e[18]](_0x850e[52])[4];var _0xceaex2d=_0xceaex2b[_0x850e[18]](_0x850e[52])[0];var _0xceaex2e=crypto[_0x850e[56]](_0x850e[53],util[_0x850e[55]](_0x850e[54],_0xceaex2c,_0xceaex2b,_0xceaex2d));var _0xceaex17=_0xceaex2e[_0x850e[59]](_0xceaex2a,_0x850e[57],_0x850e[58]);_0xceaex17+=_0xceaex2e[_0x850e[60]](_0x850e[58]);return _0xceaex17}exports[_0x850e[61]]=getUuid;exports[_0x850e[62]]=isValidDate;exports[_0x850e[63]]=isUsersLimit;exports[_0x850e[64]]=isTelephonesLimit;exports[_0x850e[65]]=hasChat;exports[_0x850e[66]]=hasMail;exports[_0x850e[67]]=hasFax;exports[_0x850e[68]]=isValidAgent;exports[_0x850e[69]]=demoLicense;exports[_0x850e[70]]=decrypt
\ No newline at end of file
+var _0x5d8b=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x63\x6F\x6D\x70\x6F\x73\x61\x62\x6C\x65\x2D\x6D\x69\x64\x64\x6C\x65\x77\x61\x72\x65","\x6D\x6F\x6D\x65\x6E\x74","\x63\x72\x79\x70\x74\x6F","\x75\x74\x69\x6C","\x6F\x73","\x65\x78\x65\x63\x53\x79\x6E\x63","\x63\x68\x69\x6C\x64\x5F\x70\x72\x6F\x63\x65\x73\x73","\x2E\x2E\x2F\x65\x6E\x76\x69\x72\x6F\x6E\x6D\x65\x6E\x74","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x54\x65\x6C\x65\x70\x68\x6F\x6E\x65","\x53\x65\x74\x74\x69\x6E\x67","\x4C\x69\x63\x65\x6E\x73\x65","\x44\x45\x4D\x4F\x20\x4C\x49\x43\x45\x4E\x53\x45","\x0D\x0A","","\x72\x65\x70\x6C\x61\x63\x65","\x64\x6D\x69\x64\x65\x63\x6F\x64\x65\x20\x2D\x2D\x73\x74\x72\x69\x6E\x67\x20\x73\x79\x73\x74\x65\x6D\x2D\x75\x75\x69\x64","\x75\x74\x66\x38","\x77\x69\x6E\x33\x32","\x2E\x2F\x68\x61\x72\x64\x77\x61\x72\x65","\x70\x6C\x61\x74\x66\x6F\x72\x6D","\x63\x61\x74\x63\x68","\x6C\x69\x63\x65\x6E\x73\x65","\x64\x61\x74\x61\x31","\x70\x61\x72\x73\x65","\x64\x65\x63\x72\x79\x70\x74\x20\x65\x72\x72\x6F\x72","\x6C\x6F\x67","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x73\x70\x72\x65\x61\x64","\x66\x69\x6E\x64\x4F\x72\x43\x72\x65\x61\x74\x65","\x75\x73\x65","\x63\x68\x61\x74","\x6D\x65\x73\x73\x61\x67\x69\x6E\x67","\x63\x6D","\x75\x70\x64\x61\x74\x65","\x6D\x61\x69\x6C","\x66\x61\x78","\x6A\x73\x63\x72\x69\x70\x74\x79","\x63\x75\x73\x74\x6F\x6D","\x6F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C","\x65\x78\x70\x69\x72\x61\x74\x69\x6F\x6E","\x69\x73\x53\x61\x6D\x65\x4F\x72\x42\x65\x66\x6F\x72\x65","\x75\x73\x65\x72\x73","\x4D\x61\x78\x69\x6D\x75\x6D\x20\x75\x73\x65\x72\x73\x20\x6C\x69\x6D\x69\x74\x20\x68\x61\x76\x65\x20\x62\x65\x65\x6E\x20\x72\x65\x61\x63\x68\x65\x64","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x61\x64\x6D\x69\x6E","\x75\x73\x65\x72","\x63\x6F\x75\x6E\x74","\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73","\x4D\x61\x78\x69\x6D\x75\x6D\x20\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73\x20\x6C\x69\x6D\x69\x74\x20\x68\x61\x76\x65\x20\x62\x65\x65\x6E\x20\x72\x65\x61\x63\x68\x65\x64","\x74\x65\x6C\x65\x70\x68\x6F\x6E\x65","\x72\x6F\x6C\x65","\x61\x67\x65\x6E\x74","\x6F\x6E\x6C\x69\x6E\x65","\x61\x67\x65\x6E\x74\x73","\x2D","\x73\x70\x6C\x69\x74","\x61\x65\x73\x2D\x32\x35\x36\x2D\x63\x74\x72","\x25\x73\x3A\x25\x73\x3A\x25\x73","\x66\x6F\x72\x6D\x61\x74","\x63\x72\x65\x61\x74\x65\x44\x65\x63\x69\x70\x68\x65\x72","\x62\x61\x73\x65\x36\x34","\x66\x69\x6E\x61\x6C","\x67\x65\x74\x55\x75\x69\x64","\x69\x73\x56\x61\x6C\x69\x64\x44\x61\x74\x65","\x69\x73\x55\x73\x65\x72\x73\x4C\x69\x6D\x69\x74","\x69\x73\x54\x65\x6C\x65\x70\x68\x6F\x6E\x65\x73\x4C\x69\x6D\x69\x74","\x68\x61\x73\x43\x68\x61\x74","\x68\x61\x73\x4D\x61\x69\x6C","\x68\x61\x73\x46\x61\x78","\x68\x61\x73\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C","\x68\x61\x73\x53\x6D\x73","\x68\x61\x73\x4A\x73\x63\x72\x69\x70\x74\x79","\x68\x61\x73\x43\x6D","\x68\x61\x73\x55\x70\x64\x61\x74\x65","\x69\x73\x56\x61\x6C\x69\x64\x41\x67\x65\x6E\x74","\x64\x65\x6D\x6F\x4C\x69\x63\x65\x6E\x73\x65","\x64\x65\x63\x72\x79\x70\x74"];_0x5d8b[0];var compose=require(_0x5d8b[1]);var moment=require(_0x5d8b[2]);var crypto=require(_0x5d8b[3]);var util=require(_0x5d8b[4]);var os=require(_0x5d8b[5]);var exec=require(_0x5d8b[7])[_0x5d8b[6]];var config=require(_0x5d8b[8]);var User=require(_0x5d8b[10])[_0x5d8b[9]];var Telephone=require(_0x5d8b[10])[_0x5d8b[11]];var Setting=require(_0x5d8b[10])[_0x5d8b[12]];var License=require(_0x5d8b[10])[_0x5d8b[13]];var demoLicense={users:1,agents:1,telephones:0,chat:false,mail:false,fax:false,jscripty:false,messaging:false,openchannel:false,custom:false,cm:false,dialer:false,update:false,description:_0x5d8b[14]};function getUuid(){switch(os[_0x5d8b[22]]()){case _0x5d8b[20]:return exec(_0x5d8b[18],{encoding:_0x5d8b[19]})[_0x5d8b[17]](_0x5d8b[15],_0x5d8b[16]);default:return require(_0x5d8b[21])(true)}}function checkLicense(_0xb1ccxf){return compose()[_0x5d8b[32]](function(_0xb1ccx10,_0xb1ccx11,_0xb1ccx12){return License[_0x5d8b[31]]({where:{id:1}})[_0x5d8b[30]](function(_0xb1ccx14){var _0xb1ccx15=null;var _0xb1ccx16=false;try{if(_0xb1ccx14[_0x5d8b[24]]){_0xb1ccx15= decrypt(_0xb1ccx14[_0x5d8b[24]],_0xb1ccx14[_0x5d8b[25]]);_0xb1ccx15= JSON[_0x5d8b[26]](_0xb1ccx15)}else {_0xb1ccx15= demoLicense}}catch(err){console[_0x5d8b[28]](_0x5d8b[27],err);_0xb1ccx15= demoLicense};_0xb1ccx16= _0xb1ccx15[_0xb1ccxf];if(!_0xb1ccx16){return _0xb1ccx11[_0x5d8b[29]](403)};return _0xb1ccx12()})[_0x5d8b[23]](function(_0xb1ccx13){return _0xb1ccx12(_0xb1ccx13)})})}function hasChat(){return checkLicense(_0x5d8b[33])}function hasSms(){return checkLicense(_0x5d8b[34])}function hasCm(){return checkLicense(_0x5d8b[35])}function hasUpdate(){return checkLicense(_0x5d8b[36])}function hasMail(){return checkLicense(_0x5d8b[37])}function hasFax(){return checkLicense(_0x5d8b[38])}function hasJscripty(){return checkLicense(_0x5d8b[39])}function hasCustom(){return checkLicense(_0x5d8b[40])}function hasOpenchannel(){return checkLicense(_0x5d8b[41])}function isValidDate(){return compose()[_0x5d8b[32]](function(_0xb1ccx10,_0xb1ccx11,_0xb1ccx12){return License[_0x5d8b[31]]({where:{id:1}})[_0x5d8b[30]](function(_0xb1ccx14){var _0xb1ccx15=null,_0xb1ccx21=false;try{if(_0xb1ccx14[_0x5d8b[24]]){_0xb1ccx15= decrypt(_0xb1ccx14[_0x5d8b[24]],_0xb1ccx14[_0x5d8b[25]]);_0xb1ccx15= JSON[_0x5d8b[26]](_0xb1ccx15);if(moment()[_0x5d8b[43]](_0xb1ccx15[_0x5d8b[42]])){_0xb1ccx21= true}}}catch(err){console[_0x5d8b[28]](_0x5d8b[27],err)};if(!_0xb1ccx21){return _0xb1ccx11[_0x5d8b[29]](403)};return _0xb1ccx12()})[_0x5d8b[23]](function(_0xb1ccx13){return _0xb1ccx12(_0xb1ccx13)})})}function isUsersLimit(){return compose()[_0x5d8b[32]](function(_0xb1ccx10,_0xb1ccx11,_0xb1ccx12){var _0xb1ccx14;return License[_0x5d8b[31]]({where:{id:1}})[_0x5d8b[30]](function(_0xb1ccx25){_0xb1ccx14= _0xb1ccx25;return User[_0x5d8b[51]]({where:{$or:[{role:_0x5d8b[49]},{role:_0x5d8b[50]}]}})})[_0x5d8b[48]](function(_0xb1ccx23){var _0xb1ccx15=null,_0xb1ccx24=false;try{if(_0xb1ccx14[_0x5d8b[24]]){_0xb1ccx15= decrypt(_0xb1ccx14[_0x5d8b[24]],_0xb1ccx14[_0x5d8b[25]]);_0xb1ccx15= JSON[_0x5d8b[26]](_0xb1ccx15)}else {_0xb1ccx15= demoLicense}}catch(err){console[_0x5d8b[28]](_0x5d8b[27],err);_0xb1ccx15= demoLicense};if(_0xb1ccx15[_0x5d8b[44]]> _0xb1ccx23){_0xb1ccx24= true};if(!_0xb1ccx24){return _0xb1ccx11[_0x5d8b[47]](403)[_0x5d8b[46]]({message:_0x5d8b[45]})};return _0xb1ccx12()})[_0x5d8b[23]](function(_0xb1ccx13){return _0xb1ccx12(_0xb1ccx13)})})}function isTelephonesLimit(){return compose()[_0x5d8b[32]](function(_0xb1ccx10,_0xb1ccx11,_0xb1ccx12){var _0xb1ccx14;return License[_0x5d8b[31]]({where:{id:1}})[_0x5d8b[30]](function(_0xb1ccx25){_0xb1ccx14= _0xb1ccx25;return User[_0x5d8b[51]]({where:{role:_0x5d8b[54]}})})[_0x5d8b[48]](function(_0xb1ccx27){var _0xb1ccx15=null,_0xb1ccx24=false;try{if(_0xb1ccx14[_0x5d8b[24]]){_0xb1ccx15= decrypt(_0xb1ccx14[_0x5d8b[24]],_0xb1ccx14[_0x5d8b[25]]);_0xb1ccx15= JSON[_0x5d8b[26]](_0xb1ccx15)}else {_0xb1ccx15= demoLicense}}catch(err){console[_0x5d8b[28]](_0x5d8b[27],err);_0xb1ccx15= demoLicense};if(_0xb1ccx15[_0x5d8b[52]]> _0xb1ccx27){_0xb1ccx24= true};if(!_0xb1ccx24){return _0xb1ccx11[_0x5d8b[47]](403)[_0x5d8b[46]]({message:_0x5d8b[53]})};return _0xb1ccx12()})[_0x5d8b[23]](function(_0xb1ccx13){return _0xb1ccx12(_0xb1ccx13)})})}function isValidAgent(){return function(_0xb1ccx29){var _0xb1ccx14;var _0xb1ccx2a=false;if(_0xb1ccx29[_0x5d8b[55]]=== _0x5d8b[49]|| _0xb1ccx29[_0x5d8b[55]]=== _0x5d8b[50]|| (_0xb1ccx29[_0x5d8b[55]]=== _0x5d8b[56]&& _0xb1ccx29[_0x5d8b[57]])){_0xb1ccx2a= true};return License[_0x5d8b[31]]({where:{id:1}})[_0x5d8b[30]](function(_0xb1ccx25){_0xb1ccx14= _0xb1ccx25;return User[_0x5d8b[51]]({where:{role:_0x5d8b[56],online:true}})})[_0x5d8b[48]](function(_0xb1ccx2b){var _0xb1ccx15=null;try{if(_0xb1ccx14[_0x5d8b[24]]){_0xb1ccx15= decrypt(_0xb1ccx14[_0x5d8b[24]],_0xb1ccx14[_0x5d8b[25]]);_0xb1ccx15= JSON[_0x5d8b[26]](_0xb1ccx15)}else {_0xb1ccx15= demoLicense}}catch(err){console[_0x5d8b[28]](_0x5d8b[27],err);_0xb1ccx15= demoLicense};if(_0xb1ccx15[_0x5d8b[58]]> _0xb1ccx2b){_0xb1ccx2a= true};return _0xb1ccx2a})}}function decrypt(_0xb1ccx2d,_0xb1ccx2e){var _0xb1ccx2f=_0xb1ccx2e[_0x5d8b[60]](_0x5d8b[59])[4];var _0xb1ccx30=_0xb1ccx2e[_0x5d8b[60]](_0x5d8b[59])[0];var _0xb1ccx31=crypto[_0x5d8b[64]](_0x5d8b[61],util[_0x5d8b[63]](_0x5d8b[62],_0xb1ccx2f,_0xb1ccx2e,_0xb1ccx30));var _0xb1ccx14=_0xb1ccx31[_0x5d8b[36]](_0xb1ccx2d,_0x5d8b[65],_0x5d8b[19]);_0xb1ccx14+= _0xb1ccx31[_0x5d8b[66]](_0x5d8b[19]);return _0xb1ccx14}exports[_0x5d8b[67]]= getUuid;exports[_0x5d8b[68]]= isValidDate;exports[_0x5d8b[69]]= isUsersLimit;exports[_0x5d8b[70]]= isTelephonesLimit;exports[_0x5d8b[71]]= hasChat;exports[_0x5d8b[72]]= hasMail;exports[_0x5d8b[73]]= hasFax;exports[_0x5d8b[74]]= hasOpenchannel;exports[_0x5d8b[75]]= hasSms;exports[_0x5d8b[76]]= hasJscripty;exports[_0x5d8b[77]]= hasCm;exports[_0x5d8b[78]]= hasUpdate;exports[_0x5d8b[79]]= isValidAgent;exports[_0x5d8b[80]]= demoLicense;exports[_0x5d8b[81]]= decrypt
\ No newline at end of file