[SR-Users] Call Transfer Scenario Using Freeswitch

2018-08-20 Thread Sunil More
Hi All,

I am using kamailio and freeswitch in my setup. While all users are
registered on Kamailio, calls are routed to Freeswitch back to kamailio and
then upstream providers.

I can make user to user calls but in cases of transfer I am stuck. I am
using a Polycom IP phone to test this scenario. While I initiate a attended
transfer and click on transfer all the legs hangup.

When I register all users on Freeswitch this works well. I am missing
something on Kamailio side.

Please point me in the right direction.

Thanking You,
Sunil More
Ph : 9503338275
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Best practice/routing block for TCP connection errors to UAC?

2018-08-20 Thread Anthony Alba
HI SR-Users

Scenario: clients registered by TCP/TLS dropping off the network,
kamailio stil thinks the client is registered and relays the INTIVE.
The error occurs at the TCP layer so no failure route is called.


ERROR:  [core/tcp_main.c:2690]: tcpconn_1st_send(): connect
127.0.0.1:48338 failed (RST) Connection refused
ERROR:  [core/tcp_main.c:2700]: tcpconn_1st_send():
127.0.0.1:48338: connect & send  for 0x7f5494e906c0 failed: Connection
refused (111)
ERROR: tm [../../core/forward.h:251]: msg_send_buffer(): tcp_send failed
WARNING: tm [t_fwd.c:1567]: t_send_branch(): sending request on branch 0 failed
ERROR: sl [sl_funcs.c:362]: sl_reply_error(): stateless error reply
used: I'm terribly sorry, server error occurred (1/SL)

I want to send the caller instead a graceful failure route type
message as if the callee is not registered (404/486/603/408 type) but
don't understand how to hook a routing block for TCP errors.

Anthony

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] ERROR: PID file /var/run/kamailio.pid does not exist -- Kamailio start failed

2018-08-20 Thread Henning Westerholt
Am Montag, 20. August 2018, 11:00:57 CEST schrieb Abdulaziz Alghosh:
> i am at the final stages of emigrating from kamailio 3.0.3 to 5.1.0
> including our own module. Unluckily, after writing the command " kamctl
> start", the following error is popping up:
> 
> * PID file /var/run/kamailio.pid does not exist -- Kamailio start failed*
> 
> Thus, I used the command " kamailio -M 8 -E -e -dd " to get more debugging
> Info and the output is detailing the following:
> 
>  0(10334) ERROR: db_mysql [km_my_con.c:129]: db_mysql_new_connection():
> driver error: Can't connect to MySQL server on '192.168.1.207' (4)
>  0(10334) ERROR:  [db.c:318]: db_do_init2(): could not add connection
> to the pool 0(10334) ERROR: ABDUL_functions [ABDUL_chk.c:1069]: init_db():
> failed to connect database URL=mysql://ABDUL:ABDUL@192.168.1.207/ABDUL
>  0(10334) ERROR: ABDUL_functions [ABDUL_functions_mod.c:296]: mod_init():
> Module ABDUL_functions not correktly initialized, pid[10334]
>  0(10334) ERROR:  [core/sr_module.c:991]: init_mod(): Error while
> initializing module ABDUL_functions
> (//lib64/kamailio/modules/ABDUL_functions.so)
> 
> Seemingly the error relates to old databases url ( "URL=mysql://
> ABDUL:ABDUL@192.168.1.207/ABDUL" ) inside an old Kamailio.cfg file from my
> 3.0.3 package which I put under another different directory. This old
> Kamailio.cfg file #includes my own module, so he is exporting this url.
> Consequently, my module is trying to connect again to this databases.
> 
> I do not know why both kamailio.cfg (new: /etc/kamailio/kamailio.cfg and
> old one out of /etc/kamailio) are both seen for kamctl or (/sbin/kamailio).
> I know that my new url inside the new /etc/kamailio/kamailio.cfg is read
> and connected but again not sure why my hidden old kamailio.cfg is still
> being read as well.
> 
> the attached shows my init file for "SUSE Linux Enterprise Server 11
> (x86_64)" and my used kamailio *default *file under /etc/default.

Hello Abdulaziz,

Kamailio gets during compilation some default configuration path, which might 
point to the old (wrong) location. Have a look to the 'kamailio -f' output to 
see its default, you can also use the '-f' parameter to change this location. 
You get all parameters with 'kamailio -h'

Then try again with the debugging method you choose above.

Best regards,

Henning 

-- 
Henning Westerholt
https://skalatan.de/blog/

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What is the typical network setup for kamailio?

2018-08-20 Thread Henning Westerholt
Am Montag, 20. August 2018, 13:22:30 CEST schrieb Kevin Olbrich:
> I browsed the files but was unable to find one using Kamailio as SBC
> without exposing the Asterisk core.
> 
> Most examples indeed expose the node and let media flow directly (
> https://www.kamailio.org/events/2017-KamailioWorld/Day1/08-David.Casem-Build
> ing-A-Global-VoIP-Network.pdf - interesting solution with e/iBGP which we
> would also be able to deploy).
> 
> There was just a single presentation that I was able to locate that had the
> proxy only on the edge:
> https://www.kamailio.org/events/2017-KamailioWorld/Day2/15-Sebasitan.Damm-An
> ti-Fraud-With-HTables.pdf At least it looks like they are located behind the
> SBC.
> 
> After the research my impression is, that co-locating the B2BUA with the
> Edge-Proxy and firewall-ing it, seems best practice.
> We will try to add some security by bridge-firewalling and BGP.
> 
> If anyone has a hint for a presentation with high-security edge-proxy, I
> would appreciate it. Thank you.
> [..]

Hi Kevin,

here you find a (older) presentation about a setup with private asterisk and 
kamailio as network edge. This is the one that we build back in the days at 
1&1, slide 19 has a schematic diagram of the setup:

https://skalatan.de/archive/presentations/kamailio-world-2013-presentation.pdf

Best regards,

Henning


-- 
Henning Westerholt
https://skalatan.de/blog/

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What is the typical network setup for kamailio?

2018-08-20 Thread Matthew Jordan
On Mon, Aug 20, 2018 at 1:04 PM Alex Balashov 
wrote:

> On Mon, Aug 20, 2018 at 09:01:08PM +0300, Dmitri Savolainen wrote:
>
> > >
> > >  If Kamailio is going to act as your registrar, then you will need to
> > > find some way to expose the registered contacts to Asterisk -
> > >
> > Matthew, could you explain why Asterisk have to know about reg contacts
> in
> > you approch?  Asterisk just may sends all to Kamailio (second call leg)
> > and let Kamailio route this call to appropriate contact.
>

This is fine, and you can make your outbound calls in that fashion. You do
need to have Asterisk present enough information that Kamailio is aware of
how to route that outbound INVITE request, but if you have sufficient
information in the request URI, it can certainly make that decision.

If, however, you wanted to dial PJSIP/1000 - which no other information and
where 1000 is some registered device - Asterisk will need the registered
contact that the device has presented to the registrar. In which case, you
have to have some mechanism for Asterisk to get at that information.


>
> The historical problem with this "dial endpoints over a trunk peer"
> approach is that such endpoints are not as privileged by Asterisk as
> local AstDB bindings for various Class 5 / application purposes, e.g.
> hints, voicemail, MWI, etc.
>
> But as I understand it, PJSIP is supposed to fix this problem and make
> use of an outboard registrar a lot more transparent.
>

Yup - it all depends on how you configure / use things.

-- 
Matthew Jordan
Digium, Inc. | CTO
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at: http://digium.com & http://asterisk.org
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What is the typical network setup for kamailio?

2018-08-20 Thread Alex Balashov
On Mon, Aug 20, 2018 at 09:01:08PM +0300, Dmitri Savolainen wrote:

> >
> >  If Kamailio is going to act as your registrar, then you will need to
> > find some way to expose the registered contacts to Asterisk -
> >
> Matthew, could you explain why Asterisk have to know about reg contacts in
> you approch?  Asterisk just may sends all to Kamailio (second call leg)
> and let Kamailio route this call to appropriate contact.

The historical problem with this "dial endpoints over a trunk peer"
approach is that such endpoints are not as privileged by Asterisk as
local AstDB bindings for various Class 5 / application purposes, e.g.
hints, voicemail, MWI, etc.

But as I understand it, PJSIP is supposed to fix this problem and make
use of an outboard registrar a lot more transparent.

-- 
Alex Balashov | Principal | Evariste Systems LLC

Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Dialplan priority

2018-08-20 Thread Dmitri Savolainen
hi, Igor

> I'm not sure to understand in which situation "pr" value is used.
>
assume you want send 200 to 200 and others to 100
1.  ^.*$ -> 100
2. ^200$->200

so you should set   more priority to second rule (for avoid 200 to 100
translation) like
1.  ^.*$ -> 100; pr=2
2. ^200$->200; pr=1

The finality I'd like to accomplish is having some kind of load balacing
> between two values into "repl_exp" with the same inputs conditions.

For balancing you may look for another modules, like drouting or dispatcher
Or use different DPIDs within dialplan: DPID may be chosen by $RANDOM (from
cfgutils module)

On 20 August 2018 at 17:56,  wrote:

> Hello,
>
>
>
> I'm not sure to understand in which situation "pr" value is used. For
> example: if I have two identical rules except pr value: 1 with 1 and the
> second with 2, then the rule with pr 2 is never used.
>
>
>
> Someone can help me to understand? Thank you.
>
>
>
> The finality I'd like to accomplish is having some kind of load balacing
> between two values into "repl_exp" with the same inputs conditions.
>
>
>
> Thank you.
>
> Regards,
>
>
>
> Igor.
>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>


-- 
Savolainen Dmitri
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio 5.1 Nathelper sipping on different transport protocols.

2018-08-20 Thread Володимир Іванець
Dmitri and Daniel, thank you very much!

2018-08-20 20:22 GMT+03:00 Daniel Tryba :

> On Mon, Aug 20, 2018 at 07:03:22PM +0300, ??
> ?? wrote:
> > It works fine if client is connected over UDP. But as soon as I will
> switch
> > to TCP or register with client that uses WS, Kamailio stops generating
> > OPTIONS.
> >
> > Does anyone know if it is  correct behavior or something is wrong?
>
> It is correct (as it is intended). AFAIK your only other choice is to
> take matters in your own hands and generate the OPTIONS yourself outside
> of kamailio.
>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio 5.1 Nathelper sipping on different transport protocols.

2018-08-20 Thread Daniel Tryba
On Mon, Aug 20, 2018 at 07:03:22PM +0300, ?? ?? 
wrote:
> It works fine if client is connected over UDP. But as soon as I will switch
> to TCP or register with client that uses WS, Kamailio stops generating
> OPTIONS.
> 
> Does anyone know if it is  correct behavior or something is wrong?

It is correct (as it is intended). AFAIK your only other choice is to
take matters in your own hands and generate the OPTIONS yourself outside
of kamailio.


signature.asc
Description: PGP signature
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio 5.1 Nathelper sipping on different transport protocols.

2018-08-20 Thread Dmitri Savolainen
hi.
It is ok; nathelper sends OPTIONS for UDP only,
TCP  is managed by core (by using params like "tcp_keepalive")

On 20 August 2018 at 19:03, Володимир Іванець 
wrote:

> Hello everyone!
>
> I have system with Kamailio v5.1 which needs to send OPTIONS packets to
> all active clients. Here is full Nathelper module configuration:
>
> *modparam("nathelper", "received_avp", "$avp(s:received)")*
> *modparam("nathelper", "natping_interval", 30)*
> *modparam("nathelper", "ping_nated_only", 0)*
> *modparam("nathelper", "sipping_bflag", FLB_SIPPING)*
> *modparam("nathelper", "sipping_from", "sip:pin...@kamailio.org
> ")*
>
> It works fine if client is connected over UDP. But as soon as I will
> switch to TCP or register with client that uses WS, Kamailio stops
> generating OPTIONS.
>
> Does anyone know if it is  correct behavior or something is wrong?
>
> Thanks a lot!
>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>


-- 
Savolainen Dmitri
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Kamailio 5.1 Nathelper sipping on different transport protocols.

2018-08-20 Thread Володимир Іванець
Hello everyone!

I have system with Kamailio v5.1 which needs to send OPTIONS packets to all
active clients. Here is full Nathelper module configuration:

*modparam("nathelper", "received_avp", "$avp(s:received)")*
*modparam("nathelper", "natping_interval", 30)*
*modparam("nathelper", "ping_nated_only", 0)*
*modparam("nathelper", "sipping_bflag", FLB_SIPPING)*
*modparam("nathelper", "sipping_from", "sip:pin...@kamailio.org
")*

It works fine if client is connected over UDP. But as soon as I will switch
to TCP or register with client that uses WS, Kamailio stops generating
OPTIONS.

Does anyone know if it is  correct behavior or something is wrong?

Thanks a lot!
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What is the typical network setup for kamailio?

2018-08-20 Thread Matthew Jordan
For what it's worth, we've set up a network/system where Asterisk resides
completely on a private network with Kamailio acting as an edge proxy.
RTPEngine is necessary as well to help the media through to the private
network, but that's probably not surprising. It is completely doable,
although the suggestions below about simply restricting Asterisk on a
public network to the locations of the Kamailio proxies also works quite
well.

Matching inbound requests in Asterisk to only the pool of Kamailio proxies
can be done in a variety of fashions - IP address matching being the
simplest. You will obviously need to think carefully about how Asterisk
handles its outbound calling. If Kamailio is going to act as your
registrar, then you will need to find some way to expose the registered
contacts to Asterisk - we chose this route, and wrote a small REST sidecar
to Kamailio for that purpose. If Asterisk is going to act as your
registrar, you will need to fork the REGISTER requests to all of the
Asterisk instances. Additionally, for INVITE requests being initiated by
Asterisk, you will want to force those to flow through your edge proxies.
This can be done using Asterisk's outbound_proxy setting on the AOR object
in pjsip.conf.

On Mon, Aug 20, 2018 at 6:23 AM Kevin Olbrich  wrote:

> Hi Henning,
>
> I browsed the files but was unable to find one using Kamailio as SBC
> without exposing the Asterisk core.
> Most examples indeed expose the node and let media flow directly (
> https://www.kamailio.org/events/2017-KamailioWorld/Day1/08-David.Casem-Building-A-Global-VoIP-Network.pdf
> - interesting solution with e/iBGP which we would also be able to deploy).
>
> There was just a single presentation that I was able to locate that had
> the proxy only on the edge:
>
> https://www.kamailio.org/events/2017-KamailioWorld/Day2/15-Sebasitan.Damm-Anti-Fraud-With-HTables.pdf
> At least it looks like they are located behind the SBC.
>
> After the research my impression is, that co-locating the B2BUA with the
> Edge-Proxy and firewall-ing it, seems best practice.
> We will try to add some security by bridge-firewalling and BGP.
>
> If anyone has a hint for a presentation with high-security edge-proxy, I
> would appreciate it. Thank you.
>
> Kind regards,
> Kevin
>
>
> Am Do., 16. Aug. 2018 um 19:12 Uhr schrieb Henning Westerholt <
> h...@kamailio.org>:
>
>> Am Donnerstag, 16. August 2018, 11:57:03 CEST schrieb Kevin Olbrich:
>> > I am working successfully with Kamailio in my lab setup where Kamailio
>> is
>> > the SBC for Asterisk.
>> > The network layout is looking like this:
>> >
>> > SIP-Phone <== PUBLIC NET ==> Kamailio (SBC) <== PRIVATE NET ==> Asterisk
>> > <== PUBLIC NET ==> Carrier
>> >
>> > Each public network is reachable from the internet and has a local
>> firewall
>> > with IP whitelists.
>> > The internal SIP transactions are UDP-only but for external phones I
>> would
>> > like to also listen for TCP/TLS.
>> >
>> > For this layout to work with rtpproxy (before we move on to RTPengine),
>> we
>> > have to enable mhomed in Kamailio.
>> > We also have some routing issues with packets leaving with the wrong IP
>> via
>> > rtpproxy (when call between carrier and external phone needs to be
>> bridged).
>> >
>> > Most examples show that Asterisk is deployed on the same network as the
>> > external interface of Kamailio (-> Asterisk exposed to the public
>> network).
>> > In our tests, this works much better but I have great security concerns
>> > because this Asterisk instance itself does not need to be reachable from
>> > external.
>> >
>> > How do other users deploy Kamailio in front of Asterisk or similar as
>> SBC
>> > to secure internals?
>> > There is lot of docs for Kamailio's config but IMHO less for the setup
>> as
>> > DMZ (SBC) proxy.
>>
>> Hello Kevin,
>>
>> this is indeed a common setup to protect asterisk and to have also much
>> greater flexibility with regards to balancing and/or SIP message
>> adaptions.
>>
>> To get some ideas, have a look to the last years conferences available
>> here:
>>
>> https://www.kamailio.org/events/
>>
>> There should be some talks about using Kamailio to in front of asterisk,
>> the
>> talk name is usually in the file name.
>>
>> I think even on this year cluecon Fred Posner did a talk about Kamailio
>> as
>> Edge Proxy, and also on astricon there were some talks  about this
>> scenario if
>> I remember correctly.
>>
>> You should also find in the Kamailio World or FOSDEM talks a lot of
>> information about this scenario.  You find all the talks available from
>> Kamailio World in our youtube channel:
>>
>> https://www.youtube.com/kamailioworld
>>
>> Best regards,
>>
>> Henning
>>
>> --
>> Henning Westerholt
>> https://skalatan.de/blog/
>>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>


-- 
Matthew Jordan
Digium, Inc. | CTO
445 Jan Davis 

[SR-Users] Dialplan priority

2018-08-20 Thread igor.potjevlesch
Hello,

 

I'm not sure to understand in which situation "pr" value is used. For
example: if I have two identical rules except pr value: 1 with 1 and the
second with 2, then the rule with pr 2 is never used.

 

Someone can help me to understand? Thank you.

 

The finality I'd like to accomplish is having some kind of load balacing
between two values into "repl_exp" with the same inputs conditions.

 

Thank you.

Regards,

 

Igor.

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Fail to reload htable

2018-08-20 Thread Soltanici Ilie
I'm trying to reload a hash table but receiving an error: 
error: 500 - Mtree reload failed


[root@kamailio]# /usr/local/sbin/kamcmd htable.listTables
{
    name: auth
    dbtable: 
    dbmode: 0
    expire: 0
    updateexpire: 1
    size: 256
     dmqreplicate: 0
}
[root@kamailio]# /usr/local/sbin/kamcmd htable.dump auth
{
    entry: 69
    size: 1
    slot: {
    {
         name: username::8.8.8.8
         value: 0
         type: int
     }
  }
}

[root@kamailio]# /usr/local/sbin/kamcmd htable.reload auth
error: 500 - Mtree reload failed
[root@kamailio]# /usr/local/sbin/kamailio -v
version: kamailio 5.1.4 (x86_64/linux) e8b2bf



___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] help

2018-08-20 Thread Pravin .
thanks for your support but the following command not worked properly..

1. apt-get install mariadb-server
after running this command it works but some depended packages not
installed correctly..and then what will be next command as given below as
it depends on earlier package installed ..

2. apt install kamailio kamailio-mysql-modules  (how it run as it depend on
earlier package installed)

If you can provide us the latest /updated install guide for kamailio on
debian, would be helpful.

Regards,
Pravin
bolindia Networks Pvt. Ltd.


On Mon, Aug 20, 2018 at 6:24 PM, Floimair Florian 
wrote:

> MySQL is no longer part of Debian. Instead they now use the MySQL fork
> MariaDB.
>
> So instead of
>
> mysql-server use maria-db-server
>
>
>
> all the rest of the steps are the same.
>
>
>
>
>
>
>
> With best regards
>
>
>
> *Florian Floimair *Innovation - Software-Development
>
>
> *COMMEND INTERNATIONAL GMBH *A-5020 Salzburg, Saalachstraße 51
> http://www.commend.com
>
>
>
> *Security and Communication by Commend *FN 178618z | LG Salzburg
>
>
>
> *Von: *sr-users  im Auftrag von
> "Pravin ." 
> *Antworten an: *"Kamailio (SER) - Users Mailing List" <
> sr-users@lists.kamailio.org>
> *Datum: *Montag, 20. August 2018 um 14:51
> *An: *"Kamailio (SER) - Users Mailing List" 
> *Betreff: *Re: [SR-Users] help
>
>
>
> Hello ,
>
>
>
> Tried to install Kamailio as per link provided by you
> https://www.kamailio.org/wiki/install/stable/debian.
>
>
>
> following commands are not working...
>
>
>
> apt
>
> *install*
>
> mysql-*server*
>
> apt *install*
>
> kamailio kamailio-mysql-modules
>
>
>
> Getting following error...
>
>
>
> Package mysql-server is not available ,but is referred to by another
> package.
>
> This may mean that package is missing.
>
> E: Package "mysql-server" has no installation candidate
>
>
>
> Pls guide us how to proceed...
>
>
>
>
>
> Note: I have installed Debian 9 as OS in my system.
>
>
>
> Regards,
>
> Pravin
>
> bolindia Networks Pvt Ltd.
>
>
>
> On Sat, Aug 18, 2018 at 1:38 PM, Mojtaba  wrote:
>
> Hi,
> The installation of Kamailio is straight forward, Just follow the
> following steps in this site:
> https://www.kamailio.org/wiki/install/stable/debian
> Also, you could download Kamailio form git source.
> With Regards.Mojtaba
>
>
> On Sat, Aug 18, 2018 at 11:52 AM Pravin .  wrote:
> >
> > Hello Team,
> >
> > I want to install Kamailio SIP server on centOS server...do we need to
> download kamailio ISO file and install on server..pls provide the
> installation procedure/guidelines.
> >
> >
> > Regards
> > Pravin
>
> > ___
> > Kamailio (SER) - Users Mailing List
> > sr-users@lists.kamailio.org
> > https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> --
> --Mojtaba Esfandiari.S
>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] help

2018-08-20 Thread Floimair Florian
Sorry, typo in my previous mail.

Correct package name is:

mariadb-server



With best regards

Florian Floimair
Innovation - Software-Development

COMMEND INTERNATIONAL GMBH
A-5020 Salzburg, Saalachstraße 51
http://www.commend.com

Security and Communication by Commend

FN 178618z | LG Salzburg

Von: sr-users  im Auftrag von Floimair 
Florian 
Antworten an: "Kamailio (SER) - Users Mailing List" 

Datum: Montag, 20. August 2018 um 14:55
An: "Kamailio (SER) - Users Mailing List" 
Betreff: Re: [SR-Users] help

MySQL is no longer part of Debian. Instead they now use the MySQL fork MariaDB.
So instead of
mysql-server use maria-db-server

all the rest of the steps are the same.



With best regards

Florian Floimair
Innovation - Software-Development

COMMEND INTERNATIONAL GMBH
A-5020 Salzburg, Saalachstraße 51
http://www.commend.com

Security and Communication by Commend

FN 178618z | LG Salzburg

Von: sr-users  im Auftrag von "Pravin ." 

Antworten an: "Kamailio (SER) - Users Mailing List" 

Datum: Montag, 20. August 2018 um 14:51
An: "Kamailio (SER) - Users Mailing List" 
Betreff: Re: [SR-Users] help

Hello ,

Tried to install Kamailio as per link provided by you  
https://www.kamailio.org/wiki/install/stable/debian.

following commands are not working...

apt
install
mysql-server
apt install
kamailio kamailio-mysql-modules

Getting following error...

Package mysql-server is not available ,but is referred to by another package.
This may mean that package is missing.
E: Package "mysql-server" has no installation candidate

Pls guide us how to proceed...


Note: I have installed Debian 9 as OS in my system.

Regards,
Pravin
bolindia Networks Pvt Ltd.

On Sat, Aug 18, 2018 at 1:38 PM, Mojtaba 
mailto:mes...@gmail.com>> wrote:
Hi,
The installation of Kamailio is straight forward, Just follow the
following steps in this site:
https://www.kamailio.org/wiki/install/stable/debian
Also, you could download Kamailio form git source.
With Regards.Mojtaba

On Sat, Aug 18, 2018 at 11:52 AM Pravin . 
mailto:pra...@bolindia.com>> wrote:
>
> Hello Team,
>
> I want to install Kamailio SIP server on centOS server...do we need to 
> download kamailio ISO file and install on server..pls provide the 
> installation procedure/guidelines.
>
>
> Regards
> Pravin
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users



--
--Mojtaba Esfandiari.S

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] help

2018-08-20 Thread Floimair Florian
MySQL is no longer part of Debian. Instead they now use the MySQL fork MariaDB.
So instead of
mysql-server use maria-db-server

all the rest of the steps are the same.



With best regards

Florian Floimair
Innovation - Software-Development

COMMEND INTERNATIONAL GMBH
A-5020 Salzburg, Saalachstraße 51
http://www.commend.com

Security and Communication by Commend

FN 178618z | LG Salzburg

Von: sr-users  im Auftrag von "Pravin ." 

Antworten an: "Kamailio (SER) - Users Mailing List" 

Datum: Montag, 20. August 2018 um 14:51
An: "Kamailio (SER) - Users Mailing List" 
Betreff: Re: [SR-Users] help

Hello ,

Tried to install Kamailio as per link provided by you  
https://www.kamailio.org/wiki/install/stable/debian.

following commands are not working...

apt
install
mysql-server
apt install
kamailio kamailio-mysql-modules

Getting following error...

Package mysql-server is not available ,but is referred to by another package.
This may mean that package is missing.
E: Package "mysql-server" has no installation candidate

Pls guide us how to proceed...


Note: I have installed Debian 9 as OS in my system.

Regards,
Pravin
bolindia Networks Pvt Ltd.

On Sat, Aug 18, 2018 at 1:38 PM, Mojtaba 
mailto:mes...@gmail.com>> wrote:
Hi,
The installation of Kamailio is straight forward, Just follow the
following steps in this site:
https://www.kamailio.org/wiki/install/stable/debian
Also, you could download Kamailio form git source.
With Regards.Mojtaba

On Sat, Aug 18, 2018 at 11:52 AM Pravin . 
mailto:pra...@bolindia.com>> wrote:
>
> Hello Team,
>
> I want to install Kamailio SIP server on centOS server...do we need to 
> download kamailio ISO file and install on server..pls provide the 
> installation procedure/guidelines.
>
>
> Regards
> Pravin
> ___
> Kamailio (SER) - Users Mailing List
> sr-users@lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users



--
--Mojtaba Esfandiari.S

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What is the typical network setup for kamailio?

2018-08-20 Thread Kevin Olbrich
Hi Henning,

I browsed the files but was unable to find one using Kamailio as SBC
without exposing the Asterisk core.
Most examples indeed expose the node and let media flow directly (
https://www.kamailio.org/events/2017-KamailioWorld/Day1/08-David.Casem-Building-A-Global-VoIP-Network.pdf
- interesting solution with e/iBGP which we would also be able to deploy).

There was just a single presentation that I was able to locate that had the
proxy only on the edge:
https://www.kamailio.org/events/2017-KamailioWorld/Day2/15-Sebasitan.Damm-Anti-Fraud-With-HTables.pdf
At least it looks like they are located behind the SBC.

After the research my impression is, that co-locating the B2BUA with the
Edge-Proxy and firewall-ing it, seems best practice.
We will try to add some security by bridge-firewalling and BGP.

If anyone has a hint for a presentation with high-security edge-proxy, I
would appreciate it. Thank you.

Kind regards,
Kevin


Am Do., 16. Aug. 2018 um 19:12 Uhr schrieb Henning Westerholt <
h...@kamailio.org>:

> Am Donnerstag, 16. August 2018, 11:57:03 CEST schrieb Kevin Olbrich:
> > I am working successfully with Kamailio in my lab setup where Kamailio is
> > the SBC for Asterisk.
> > The network layout is looking like this:
> >
> > SIP-Phone <== PUBLIC NET ==> Kamailio (SBC) <== PRIVATE NET ==> Asterisk
> > <== PUBLIC NET ==> Carrier
> >
> > Each public network is reachable from the internet and has a local
> firewall
> > with IP whitelists.
> > The internal SIP transactions are UDP-only but for external phones I
> would
> > like to also listen for TCP/TLS.
> >
> > For this layout to work with rtpproxy (before we move on to RTPengine),
> we
> > have to enable mhomed in Kamailio.
> > We also have some routing issues with packets leaving with the wrong IP
> via
> > rtpproxy (when call between carrier and external phone needs to be
> bridged).
> >
> > Most examples show that Asterisk is deployed on the same network as the
> > external interface of Kamailio (-> Asterisk exposed to the public
> network).
> > In our tests, this works much better but I have great security concerns
> > because this Asterisk instance itself does not need to be reachable from
> > external.
> >
> > How do other users deploy Kamailio in front of Asterisk or similar as SBC
> > to secure internals?
> > There is lot of docs for Kamailio's config but IMHO less for the setup as
> > DMZ (SBC) proxy.
>
> Hello Kevin,
>
> this is indeed a common setup to protect asterisk and to have also much
> greater flexibility with regards to balancing and/or SIP message adaptions.
>
> To get some ideas, have a look to the last years conferences available
> here:
>
> https://www.kamailio.org/events/
>
> There should be some talks about using Kamailio to in front of asterisk,
> the
> talk name is usually in the file name.
>
> I think even on this year cluecon Fred Posner did a talk about Kamailio as
> Edge Proxy, and also on astricon there were some talks  about this
> scenario if
> I remember correctly.
>
> You should also find in the Kamailio World or FOSDEM talks a lot of
> information about this scenario.  You find all the talks available from
> Kamailio World in our youtube channel:
>
> https://www.youtube.com/kamailioworld
>
> Best regards,
>
> Henning
>
> --
> Henning Westerholt
> https://skalatan.de/blog/
>
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Releasing Kamailio v5.1.5

2018-08-20 Thread Daniel-Constantin Mierla
Hello,

short reminder that 5.1.5 is planned for mid of this week -- I
backported many patches by end of last week, but it would be good that
everyone checks to see if all patches relevant for own deployments were
pushed to 5.1 branch.

Cheers,
Daniel

On 14.08.18 15:21, Daniel-Constantin Mierla wrote:
> Hello,
>
> with the summer holidays in the northern hemisphere approaching the end,
> I am considering to release v5.1.5 out of Kamailio git branch 5.1 --
> there were several fixes done since 5.1.4 and it is time to package
> another minor release.
>
> The propose date is next week on Wednesday, August 22, or slightly after
> in case there are unexpected events delays it.
>
> Should there be any issues you are aware of and not yet reported on the
> bug tracker, do it asap in order to have a chance to be fixed:
>
>   - https://github.com/kamailio/kamailio/issues
>
> Cheers,
> Daniel
>

-- 
Daniel-Constantin Mierla -- www.asipto.com
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference -- www.kamailioworld.com


___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] ERROR: PID file /var/run/kamailio.pid does not exist -- Kamailio start failed

2018-08-20 Thread Abdulaziz Alghosh
Greetings,

i am at the final stages of emigrating from kamailio 3.0.3 to 5.1.0
including our own module. Unluckily, after writing the command " kamctl
start", the following error is popping up:


* PID file /var/run/kamailio.pid does not exist -- Kamailio start failed*

Thus, I used the command " kamailio -M 8 -E -e -dd " to get more debugging
Info and the output is detailing the following:

 0(10334) ERROR: db_mysql [km_my_con.c:129]: db_mysql_new_connection():
driver error: Can't connect to MySQL server on '192.168.1.207' (4)
 0(10334) ERROR:  [db.c:318]: db_do_init2(): could not add connection
to the pool 0(10334) ERROR: ABDUL_functions [ABDUL_chk.c:1069]: init_db():
failed to connect database URL=mysql://ABDUL:ABDUL@192.168.1.207/ABDUL
 0(10334) ERROR: ABDUL_functions [ABDUL_functions_mod.c:296]: mod_init():
Module ABDUL_functions not correktly initialized, pid[10334]
 0(10334) ERROR:  [core/sr_module.c:991]: init_mod(): Error while
initializing module ABDUL_functions
(//lib64/kamailio/modules/ABDUL_functions.so)

Seemingly the error relates to old databases url ( "URL=mysql://
ABDUL:ABDUL@192.168.1.207/ABDUL" ) inside an old Kamailio.cfg file from my
3.0.3 package which I put under another different directory. This old
Kamailio.cfg file #includes my own module, so he is exporting this url.
Consequently, my module is trying to connect again to this databases.

I do not know why both kamailio.cfg (new: /etc/kamailio/kamailio.cfg and
old one out of /etc/kamailio) are both seen for kamctl or (/sbin/kamailio).
I know that my new url inside the new /etc/kamailio/kamailio.cfg is read
and connected but again not sure why my hidden old kamailio.cfg is still
being read as well.

the attached shows my init file for "SUSE Linux Enterprise Server 11
(x86_64)" and my used kamailio *default *file under /etc/default.

Thanks in advance and best regards
Abdulaziz


kamailio_default_copy
Description: Binary data


kamailio_init_copy
Description: Binary data
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] remove_hf function in INVITE message

2018-08-20 Thread Daniel-Constantin Mierla
The message is broken indeed, at the part:

Max-Forwards: 69
   
sip:7000@192.168.122.1:36853;transport=UDP;alias=192.168.122.1~36853~1To:


Likely that is because you do couple of operations over the Contact
header, besides remove_hf()/append_hf(), you use also
set_contact_alias() or add_contact_alias(). You can do
msg_apply_changes() in between such operations to avoid breaking the sip
message.

Cheers,
Daniel


On 19.08.18 11:45, Mojtaba wrote:
> Today i encounter with strange issue in SIP signalling in Kamailio,
> In INVITE message, I just change Contact Header and relay message to
> destination, But the message is like this:
> 192.168.122.245.4080 > 192.168.122.174.5060: [bad udp cksum 0x7b5e ->
> 0x3a4d!] SIP, length: 1104
> INVITE sip:8...@r-kh.com;transport=UDP SIP/2.0
> Record-Route: 
> Via: SIP/2.0/UDP
> 192.168.122.245:4080;branch=z9hG4bK14d7.dc974309aba269b24213204d3ea085e2.0
> Via: SIP/2.0/UDP
> 192.168.122.1:36853;rport=36853;branch=z9hG4bK-d8754z-423b431a3ebc8a22-1---d8754z-
> Max-Forwards: 69
> sip:7000@192.168.122.1:36853;transport=UDP;alias=192.168.122.1~36853~1To:
> 
> From: ;tag=8e47e95e
> Call-ID: YTZmYTJmYzg0ZDNiMjM2OGUxZGYwNzg4OWY1ZmIxYzc.
> CSeq: 1 INVITE
> Allow: INVITE, ACK, CANCEL, BYE, NOTIFY, REFER, MESSAGE, OPTIONS,
> INFO, SUBSCRIBE
> Content-Type: application/sdp
> Supported: replaces, norefersub, extended-refer, timer, X-cisco-serviceuri
> User-Agent: Z 3.3.25608 r25552
> Allow-Events: presence, kpml
> Content-Length: 241
>  
> The code in Kamailio is:
>
> #!ifdef WITH_SBC_NASIM
> #if the Invite request is MO, forward it to Asterisk .
> if (is_method("INVITE") && $si!="192.168.122.245") {
> xlog("L_INFO", "The Invite message from $si:$sp,
> Forwart to Asterisk.  <192.168.122.174:5060>.\n");
> remove_hf("Contact");
> append_hf("Contact:sip:$f...@sbc.r-kh.com\r\n");
> $du = "sip:192.168.122.174:5060";
> }
> #!endif
>
> Be notice that, i have the same procedure in REGISTER message, But it
> is work correct,
> if(is_method("REGISTER")) {
> xlog("L_INFO", "forward register to Asterisk\n");
> remove_hf("Contact");
> append_hf("Contact:sip:$f...@sbc.r-kh.com\r\n");
> rewriteuri("sip:r-kh.com");
> $du = "sip:192.168.122.174:5060";
> route(RELAY);
> }
>
> Let me know what is the problem?
>

-- 
Daniel-Constantin Mierla -- www.asipto.com
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference -- www.kamailioworld.com


___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] JSONRPC-S and async RPC commands

2018-08-20 Thread Daniel-Constantin Mierla


On 18.08.18 19:16, Juha Heinanen wrote:
> Daniel-Constantin Mierla writes:
>
>> I just pushed a commit in master branch, hopefully is fixing the issue
>> -- let me know the results and if ok, it will be backported.
> Daniel,
>
> Thanks for the commit.  My tm.t_uac_wait test (using master) now worked
> fine without issues.
>
>
Thanks for testing and reporting, I will backport.

Cheers,
Daniel

-- 
Daniel-Constantin Mierla -- www.asipto.com
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference -- www.kamailioworld.com


___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users