<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=iso-8859-1"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"Lucida Console";
        panose-1:2 11 6 9 4 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EstiloCorreo17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=ES-MX link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hello List<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><span lang=EN-US>I am trying to intgrate Kamailio latest release 4.1.4 and Freepbx 5.2.11 Asterisk 11.0.9 in the same box on an internal network following Danielīs tutorial (<a href="http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb">http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb</a>) . I am very new with Kamailio and I tried like 15 times, seriously.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>The difference is that I am not using the sipusers table nor sipregs (I may later use sipregs) nor the voicemail tables (Freepbx can manage voicemail). I believe I was able to modify the kamailio.cfg file (DBURL and DBASTURL) in order to fetch the user information from the Freepbx tables. There is a table called devices that contents all the information needed. I also managed to not fill the secret parameter (password) on the extension configuration so Asterisk does not ask for authentication twice as recommended in the tutorial. I put the password in other table and then tell Kamailio to fetch it from the corresponding table.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>I can control if the users are registered in the system as long as the user is created in Freepbx with the right password, again password is not on the secret column. The weird thing is that my users can register in Asterisk even if they are not created in Kamailio  (kamctl add). I was expecting them not to register if they are not created on the database. I have configured Freepbx to bind to a specific internal IP and port 5080 and configures kamailio as in the post<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>#!ifdef WITH_ASTERISK<o:p></o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>asterisk.bindip = "xxx.xxx.xxx.xxx" desc "Asterisk IP Address"<o:p></o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>asterisk.bindport = "5080" desc "Asterisk Port"<o:p></o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>kamailio.bindip = "xxx.xxx.xxx.xxx" desc "Kamailio IP Address"<o:p></o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>kamailio.bindport = "5060" desc "Kamailio Port"<o:p></o:p></span></p><p class=MsoNormal><span lang=EN style='font-size:10.0pt;font-family:"Courier New";mso-fareast-language:ES-MX'>#!endif<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Also I have added to kamailio.cfg<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Lucida Console"'>#!define WITH_MYSQL<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Lucida Console"'>#!define WITH_AUTH<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Lucida Console"'>#!define WITH_USRLOCDB<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Lucida Console"'>#!define WITH_ASTERISK<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:10.0pt;font-family:"Lucida Console"'>#!define WITH_ANTIFLOOD<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>I don’t think this is the normal behavior, does anybody have an insight of what could be happening?? MY goal is to add the <i>#!define WITH_NAT </i>functionality (I haven’t done it yet)and then have remote trusted users connected to the PBX. Of course the concerns is to keep hackers away from my system.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Thanks in advance for your help and for this great piece of software!!!!<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Regards and greetings from Mexico<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Carlos<o:p></o:p></span></p></div></body></html>