f9b96bb4fccc2139586d441981a9f198a84e52b8
[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 _0x5983=['yes','/etc/pki/tls/certs/motion.crt','/etc/pki/tls/private/motion.key','actpass','\x22%s\x22\x20<%s>','User','then','log','catch','util','../mysqldb','push','format','%s%s','agent','%s%s@xcally.com','password','udp','all','ulaw'];(function(_0x4c1832,_0x11e246){var _0x1a6d24=function(_0xe43c2f){while(--_0xe43c2f){_0x4c1832['push'](_0x4c1832['shift']());}};_0x1a6d24(++_0x11e246);}(_0x5983,0xe5));var _0x3598=function(_0x2b53ba,_0x54c027){_0x2b53ba=_0x2b53ba-0x0;var _0x5d933e=_0x5983[_0x2b53ba];return _0x5d933e;};'use strict';var util=require(_0x3598('0x0'));var db=require(_0x3598('0x1'))['db'];var users=[];for(var i=0x1;i<=0xc8;i+=0x1){users[_0x3598('0x2')]({'name':util[_0x3598('0x3')](_0x3598('0x4'),_0x3598('0x5'),i),'fullname':util[_0x3598('0x3')](_0x3598('0x4'),'agent',i),'email':util[_0x3598('0x3')](_0x3598('0x6'),_0x3598('0x5'),i),'role':_0x3598('0x5'),'password':_0x3598('0x7'),'internal':0xfa0+i,'type':'friend','transport':[_0x3598('0x8'),'ws','wss'],'disallow':[_0x3598('0x9')],'allow':[_0x3598('0xa')],'defaultuser':util[_0x3598('0x3')](_0x3598('0x4'),_0x3598('0x5'),i),'encryption':_0x3598('0xb'),'avpf':'yes','force_avp':_0x3598('0xb'),'icesupport':_0x3598('0xb'),'dtlsenable':_0x3598('0xb'),'dtlsverify':'no','dtlscertfile':_0x3598('0xc'),'dtlsprivatekey':_0x3598('0xd'),'dtlssetup':_0x3598('0xe'),'callerid':util[_0x3598('0x3')](_0x3598('0xf'),util[_0x3598('0x3')]('%s%s',_0x3598('0x5'),i),0xfa0+i)});}db[_0x3598('0x10')]['bulkCreate'](users)[_0x3598('0x11')](function(){console[_0x3598('0x12')]('add\x20user');})[_0x3598('0x13')](function(_0x5f3000){console[_0x3598('0x12')](_0x5f3000);});