1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold. *
17 // *************************************************************************
18 var _0x2508=['MailAccount','provider','service','host','port','secure','Smtp','authentication','modernAuthentication','Cloud\x20Provider\x20configuration\x20not\x20found','auth','OAuth2','user','CloudProvider','data5','./mailAccount.attributes','define'];(function(_0xbc4560,_0x4020b8){var _0x298cfb=function(_0x254423){while(--_0x254423){_0xbc4560['push'](_0xbc4560['shift']());}};_0x298cfb(++_0x4020b8);}(_0x2508,0x174));var _0x8250=function(_0x56a0a6,_0x21f8c4){_0x56a0a6=_0x56a0a6-0x0;var _0x285500=_0x2508[_0x56a0a6];return _0x285500;};'use strict';var attributes=require(_0x8250('0x0'));module['exports']=function(_0x5cab20){return _0x5cab20[_0x8250('0x1')](_0x8250('0x2'),attributes,{'tableName':'mail_accounts','paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getSmtpOptions':function(){var _0x4d5c39=this;var _0x1d3003={'id':_0x4d5c39['id'],'tls':{'rejectUnauthorized':![]}};if(_0x4d5c39[_0x8250('0x3')]!=='custom'){_0x1d3003[_0x8250('0x4')]=_0x4d5c39[_0x8250('0x3')];}else{_0x1d3003[_0x8250('0x5')]=_0x4d5c39['Smtp'][_0x8250('0x5')];_0x1d3003[_0x8250('0x6')]=_0x4d5c39['Smtp'][_0x8250('0x6')];_0x1d3003[_0x8250('0x7')]=_0x4d5c39[_0x8250('0x8')][_0x8250('0x7')];}if(_0x4d5c39[_0x8250('0x8')][_0x8250('0x9')]){if(_0x4d5c39[_0x8250('0x8')][_0x8250('0xa')]){if(!_0x4d5c39[_0x8250('0x8')]['CloudProvider'])throw new Error(_0x8250('0xb'));_0x1d3003[_0x8250('0xc')]={'type':_0x8250('0xd'),'user':_0x4d5c39[_0x8250('0x8')][_0x8250('0xe')],'accessToken':_0x4d5c39[_0x8250('0x8')][_0x8250('0xf')][_0x8250('0x10')]};}else{_0x1d3003[_0x8250('0xc')]={'user':_0x4d5c39[_0x8250('0x8')][_0x8250('0xe')],'pass':_0x4d5c39[_0x8250('0x8')]['pass']};}}return _0x1d3003;}}});};