6ba5f4f91deb5551a58dba9e179e422b25182479
[motion2.git] / server / config / seedUsers.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
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.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xd6e3=['/etc/pki/tls/certs/motion.crt','/etc/pki/tls/private/motion.key','actpass','User','bulkCreate','then','log','add\x20user','catch','../mysqldb','%s%s','format','agent','password','friend','udp','ulaw','yes'];(function(_0x152aa1,_0x307718){var _0x1bc01a=function(_0xd3211e){while(--_0xd3211e){_0x152aa1['push'](_0x152aa1['shift']());}};_0x1bc01a(++_0x307718);}(_0xd6e3,0x117));var _0x3d6e=function(_0x4c9012,_0x386708){_0x4c9012=_0x4c9012-0x0;var _0x466873=_0xd6e3[_0x4c9012];return _0x466873;};'use strict';var util=require('util');var db=require(_0x3d6e('0x0'))['db'];var users=[];for(var i=0x1;i<=0xc8;i+=0x1){users['push']({'name':util['format'](_0x3d6e('0x1'),'agent',i),'fullname':util[_0x3d6e('0x2')]('%s%s',_0x3d6e('0x3'),i),'email':util[_0x3d6e('0x2')]('%s%s@xcally.com',_0x3d6e('0x3'),i),'role':_0x3d6e('0x3'),'password':_0x3d6e('0x4'),'internal':0xfa0+i,'type':_0x3d6e('0x5'),'transport':[_0x3d6e('0x6'),'ws','wss'],'disallow':['all'],'allow':[_0x3d6e('0x7')],'defaultuser':util[_0x3d6e('0x2')](_0x3d6e('0x1'),_0x3d6e('0x3'),i),'encryption':_0x3d6e('0x8'),'avpf':_0x3d6e('0x8'),'force_avp':_0x3d6e('0x8'),'icesupport':'yes','dtlsenable':'yes','dtlsverify':'no','dtlscertfile':_0x3d6e('0x9'),'dtlsprivatekey':_0x3d6e('0xa'),'dtlssetup':_0x3d6e('0xb'),'callerid':util[_0x3d6e('0x2')]('\x22%s\x22\x20<%s>',util[_0x3d6e('0x2')](_0x3d6e('0x1'),_0x3d6e('0x3'),i),0xfa0+i)});}db[_0x3d6e('0xc')][_0x3d6e('0xd')](users)[_0x3d6e('0xe')](function(){console[_0x3d6e('0xf')](_0x3d6e('0x10'));})[_0x3d6e('0x11')](function(_0x1d9a01){console[_0x3d6e('0xf')](_0x1d9a01);});