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 _0xa9bc=['define','MailAccount','provider','custom','Smtp','host','port','secure','authentication','modernAuthentication','CloudProvider','auth','user','data5','pass','./mailAccount.attributes','exports'];(function(_0x10f8c0,_0x3389ae){var _0x4ec182=function(_0x9f4df0){while(--_0x9f4df0){_0x10f8c0['push'](_0x10f8c0['shift']());}};_0x4ec182(++_0x3389ae);}(_0xa9bc,0x1b8));var _0xca9b=function(_0x26a511,_0x309cab){_0x26a511=_0x26a511-0x0;var _0x3ca951=_0xa9bc[_0x26a511];return _0x3ca951;};'use strict';var attributes=require(_0xca9b('0x0'));module[_0xca9b('0x1')]=function(_0x14d003){return _0x14d003[_0xca9b('0x2')](_0xca9b('0x3'),attributes,{'tableName':'mail_accounts','paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getSmtpOptions':function(){var _0xeea934=this;var _0x1a9ba6={'id':_0xeea934['id'],'tls':{'rejectUnauthorized':![]}};if(_0xeea934[_0xca9b('0x4')]!==_0xca9b('0x5')){_0x1a9ba6['service']=_0xeea934[_0xca9b('0x4')];}else{_0x1a9ba6['host']=_0xeea934[_0xca9b('0x6')][_0xca9b('0x7')];_0x1a9ba6[_0xca9b('0x8')]=_0xeea934[_0xca9b('0x6')][_0xca9b('0x8')];_0x1a9ba6[_0xca9b('0x9')]=_0xeea934[_0xca9b('0x6')][_0xca9b('0x9')];}if(_0xeea934[_0xca9b('0x6')][_0xca9b('0xa')]){if(_0xeea934[_0xca9b('0x6')][_0xca9b('0xb')]){if(!_0xeea934[_0xca9b('0x6')][_0xca9b('0xc')])throw new Error('Cloud\x20Provider\x20configuration\x20not\x20found');_0x1a9ba6[_0xca9b('0xd')]={'type':'OAuth2','user':_0xeea934[_0xca9b('0x6')][_0xca9b('0xe')],'accessToken':_0xeea934[_0xca9b('0x6')][_0xca9b('0xc')][_0xca9b('0xf')]};}else{_0x1a9ba6[_0xca9b('0xd')]={'user':_0xeea934[_0xca9b('0x6')]['user'],'pass':_0xeea934[_0xca9b('0x6')][_0xca9b('0x10')]};}}return _0x1a9ba6;}}});};