[SR-Users] Need help with Kamailio+RLS configuration.
Hello everyone, I am running Kamailio 3.3.2 server and I need to configure it to support RLS to avoid big amounts of SUBSCRIBE requests from clients. By this moment I have managed to configure XCAP server and learned the XML structure for press-rules, rls-services and resource-list documents. Also I have successfully put rls_update_subs and rls_handle_subscribe calls to kamailio.cfg, so now when I PUT new rls-services or resource-list document to XCAP I can see these calls triggered. The problem is that on client side I always get empty notification XML: ?xml version=1.0? list uri=sip:user1-list@sip.server xmlns=urn:ietf:params:xml:ns:rlmi version=1 fullState=true resource uri=sip:user2@sip.server/ resource uri=sip:user3@sip.server/ /list As I understand, user2 and user3 must have added user1 to pres-rules document? Correct? So it is… I assume there should be a call to rls_handle_notify function somewhere in kamailio.cfg, but where exactly? I have tried to add it after SUBSCRIBE condition, but it is never called in fact: if( is_method(SUBSCRIBE)) { xlog(BEFORE rls_handle_subscribe); $var(ret_code)= rls_handle_subscribe(); xlog(AFTER rls_handle_subscribe); if($var(ret_code)== 10) handle_subscribe(); t_release(); } else if (is_method(NOTIFY)) { xlog(BEFORE rls_handle_notify); rls_handle_notify(); xlog(AFTER rls_handle_notify); } Any comment would be appreciated! Regards, Alex. ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] IPv4 / v6 request to global parameter TOS
Hello, there is a patch attempting to set the tos for IPv6: - http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=084be456bc0fab015cf9964ac85651fa60ea77c9 For now is only for UDP, but if it works I will propagate to tcp/tls. I tested it compiles, but had no IPv6 testbed around. If anyone can test and report back, will be appreciated. Cheers, Daniel On 3/25/13 1:40 PM, Daniel-Constantin Mierla wrote: Hello, On 3/22/13 9:50 PM, Klaus Feichtinger wrote: Hello list, in a bridging scenario with kamailio 3.3.4 and rtpproxy 1.2.1 for bridging signalling and media from an IPv4 to an IPv6 network and vice versa I found that the TOS value, which is set in kamailio.cfg, is used for IPv4 packets only. IPv6 packets have the traffic class value set to the default value 0x0. In other words: kamailio doesn´t use this variable for IPv6 packets. In the cookbook (http://www.kamailio.org/wiki/cookbooks/3.3.x/core#tos) I haven´t found any hint that it _is_ limited to IPv4 only (...for the sent IP packages). I know that the name tos may be misleading, as the original definition was outdated by dscp+ecn, but it was/is working fine now. However, as IPv6 is using dscp+ecn, too, I wonder if the tos variable should support IPv6 packets, too. Could anybody give me a hint? Is there maybe an alternative way to prioritise SIP in IPv6 with kamailio? Probably when it was added the IPv6 was no longer in the spot and developer didn't bother with it. If it uses more or less same interface to set it, then I guess it will not be hard to extend it to IPv6. Just add it to the tracker to be visible and not to get forgotten. Cheers, Daniel -- Daniel-Constantin Mierla - http://www.asipto.com http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda Kamailio World Conference, April 16-17, 2013, Berlin - http://conference.kamailio.com - ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] base64 transformation
Hi guys Maybe I missed something, but looks like there is no base64 encode/decode transformation in PV, right? I think we're going to add one, as it might be handy to do such transformations directly from within the config file. One case where this could be used is that some UAs are picky in regards to URIs as URI params, e.g. P-Foo: sip:al...@example.org;x='sip:1.2.3.4:1234' which could be changed into P-Foo: sip:al...@example.org;x=c2lwOjEuMi4zLjQ6MTIzNAo= which might be understood more easily (although it's still just a work-around for broken UAs, but that's how life is). Any objections against such a transformation? Andreas ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] base64 transformation
I'm all in favour of it, as it would be quite useful to us likewise! Andreas Granig agra...@sipwise.com wrote: Hi guys Maybe I missed something, but looks like there is no base64 encode/decode transformation in PV, right? I think we're going to add one, as it might be handy to do such transformations directly from within the config file. One case where this could be used is that some UAs are picky in regards to URIs as URI params, e.g. P-Foo: sip:al...@example.org;x='sip:1.2.3.4:1234' which could be changed into P-Foo: sip:al...@example.org;x=c2lwOjEuMi4zLjQ6MTIzNAo= which might be understood more easily (although it's still just a work-around for broken UAs, but that's how life is). Any objections against such a transformation? Andreas ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users -- Sent from my mobile, and thus lacking in the refinement one might expect from a fully-fledged keyboard. Alex Balashov - Principal Evariste Systems LLC 235 E Ponce de Leon Ave Suite 106 Decatur, GA 30030 United States Tel: +1-678-954-0670 Web: http://www.evaristesys.com/, http://www.alexbalashov.com/ ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Tag maximum size/length
Hello, Is there a maximum length/size defined for the From and To Tag? The RFC states: it MUST be globally unique and cryptographically random with at least 32 bits of randomness. Though I can't find anything in the RFC about the maximum. The sip_capture table stores the to_tag and from_tag in a varchar(64). Does this mean the max is 64? Source: https://code.google.com/p/homer/source/browse/sql/create_sipcapture.sql Thanks, G ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Tag maximum size/length
On 3/28/13 11:21 AM, Grant Bagdasarian wrote: Hello, Is there a maximum length/size defined for the From and To Tag? The RFC states: “it MUST be globally unique and cryptographically random with at least 32 bits of randomness”. Though I can’t find anything in the RFC about the maximum. The sip_capture table stores the to_tag and from_tag in a varchar(64). Does this mean the max is 64? Source: https://code.google.com/p/homer/source/browse/sql/create_sipcapture.sql Yes, that's an implementation's limitation. -jiri ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Tag maximum size/length
Do you mean implementation in the context of Kamailio's implementation of SIP? If so, what if certain SIP clients implement it in a different way and their Tag values exceed this limitation? -Original Message- From: Jiri Kuthan [mailto:j...@iptel.org] Sent: Thursday, March 28, 2013 11:42 AM To: Kamailio (SER) - Users Mailing List Cc: Grant Bagdasarian Subject: Re: [SR-Users] Tag maximum size/length On 3/28/13 11:21 AM, Grant Bagdasarian wrote: Hello, Is there a maximum length/size defined for the From and To Tag? The RFC states: “it MUST be globally unique and cryptographically random with at least 32 bits of randomness”. Though I can’t find anything in the RFC about the maximum. The sip_capture table stores the to_tag and from_tag in a varchar(64). Does this mean the max is 64? Source: https://code.google.com/p/homer/source/browse/sql/create_sipcapture.sql Yes, that's an implementation's limitation. -jiri ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Tag maximum size/length
On 3/28/13 12:41 PM, Grant Bagdasarian wrote: Do you mean implementation in the context of Kamailio's implementation of SIP? yes If so, what if certain SIP clients implement it in a different way and their Tag values exceed this limitation? that depends on the application how a loss of bits affects it. With the required level of entropy, the impact is probably not big within a module: good enough for say correlation. it would be more problematic if the sip_capture module tried to work with some other module and match the tags between them -- that would obviously fail. if you wanted to be more deterministic with the sip_capture module and mysql data model, you would probably have to change data types to TEXT (256 bytes) or BLOB (64k). While these sizes are not prohibited by the spec, MTU constraints and fragmentation would anihilate INVITEs with such Tags anyhow. Also these types have some performance penalties associated with them. so in summary -- it appears that while somehow esthetically suboptimal, the 64 bytes limit is mostly good enough. jiri -Original Message- From: Jiri Kuthan [mailto:j...@iptel.org] Sent: Thursday, March 28, 2013 11:42 AM To: Kamailio (SER) - Users Mailing List Cc: Grant Bagdasarian Subject: Re: [SR-Users] Tag maximum size/length On 3/28/13 11:21 AM, Grant Bagdasarian wrote: Hello, Is there a maximum length/size defined for the From and To Tag? The RFC states: “it MUST be globally unique and cryptographically random with at least 32 bits of randomness”. Though I can’t find anything in the RFC about the maximum. The sip_capture table stores the to_tag and from_tag in a varchar(64). Does this mean the max is 64? Source: https://code.google.com/p/homer/source/browse/sql/create_sipcapture.sql Yes, that's an implementation's limitation. -jiri ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] kamailio 4.0.0; km_append_branch problem
Hi all, I installed Kamailio 4.0.0 from source an tried configuration from Kamailio 3.3.2. problem is with km_append_branch function. Not starting Kamailio400: invalid configuration file! -e 0(20346) ERROR: core [cfg.y:3431]: cfg. parser: failed to find command km_append_branch 0(20346) : core [cfg.y:3570]: parse error in config file /usr/local/kamailio400/etc/kamailio/kamailio.cfg, line 2448, column 22: unknown command, missing loadmodule? ERROR: bad config file (1 errors) configuration: -- mpath=/usr/local/kamailio400/lib64/kamailio/modules_k/:/usr/local/kamailio400/lib64/kamailio/modules/ loadmodule kex.so ... km_append_branch(); route(RELAY); exit; } ... Please advise Best regards Pavel ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Homer / Kamailio / Freeswitch
Hello. First of all i just did a fresh install of Homer and this thing is perfect only really missing the RTP analysis. Anyway I have a Freeswitch PBX with several internal profiles and also external profiles binded into external Ips ( Public not Private). Capture on the private network profiles works flawlessly when i try to track public interface , calls going into the VOIP Operators , there are no entries So : Public call data inside the DB , No Freeswitch sending data into Kamailio , Yes TCPDUMP on Kamailio Shows SIP Data from the PBX Interface , Yes , Kamailio complains with Mar 28 08:30:27 debian /usr/local/sbin/kamailio[23709]: ERROR: core [parser/msg_parser.c:705]: ERROR: parse_msg: message=#015#012 Mar 28 08:30:27 debian /usr/local/sbin/kamailio[23709]: ERROR: core [receive.c:146]: ERROR: receive_msg: parse_msg failed Problem Scenario : A call from a phone inside the network 1.1.1.0 Into the PBX 1.1.1.1 is tracked by Homer a call from the external IP Binded into the PBX lets say something like 80.0.80.8(External Public IP) , Call not tracked and Kamailio complains with parse_msg_error. Helper Data : Uname Linux debian 2.6.32-5-amd64 #1 SMP Mon Feb 25 00:26:11 UTC 2013 x86_64 GNU/Linux LSB Distributor ID: Debian Description:Debian GNU/Linux 6.0.7 (squeeze) Release:6.0.7 Codename: squeeze Kamailio as of TODAY from GIT Homer as of TODAY from GIT WebHomer 3.3.1 From GIT Also Using the SOFIA SIPTRACE , problem shows both using the global sip trace or individual profile siptrace. Thanks for your time Antonio ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Homer / Kamailio / Freeswitch
Hi, can you show your sofia's config ? btw, better send this question to homer's list. Wbr, Alexandr -Original Message- From: sr-users-boun...@lists.sip-router.org [mailto:sr-users-boun...@lists.sip-router.org] On Behalf Of Antonio Teixeira Sent: Thursday, March 28, 2013 6:37 PM To: sr-users@lists.sip-router.org Subject: [SR-Users] Homer / Kamailio / Freeswitch Hello. First of all i just did a fresh install of Homer and this thing is perfect only really missing the RTP analysis. Anyway I have a Freeswitch PBX with several internal profiles and also external profiles binded into external Ips ( Public not Private). Capture on the private network profiles works flawlessly when i try to track public interface , calls going into the VOIP Operators , there are no entries So : Public call data inside the DB , No Freeswitch sending data into Kamailio , Yes TCPDUMP on Kamailio Shows SIP Data from the PBX Interface , Yes , Kamailio complains with Mar 28 08:30:27 debian /usr/local/sbin/kamailio[23709]: ERROR: core [parser/msg_parser.c:705]: ERROR: parse_msg: message=#015#012 Mar 28 08:30:27 debian /usr/local/sbin/kamailio[23709]: ERROR: core [receive.c:146]: ERROR: receive_msg: parse_msg failed Problem Scenario : A call from a phone inside the network 1.1.1.0 Into the PBX 1.1.1.1 is tracked by Homer a call from the external IP Binded into the PBX lets say something like 80.0.80.8(External Public IP) , Call not tracked and Kamailio complains with parse_msg_error. Helper Data : Uname Linux debian 2.6.32-5-amd64 #1 SMP Mon Feb 25 00:26:11 UTC 2013 x86_64 GNU/Linux LSB Distributor ID: Debian Description:Debian GNU/Linux 6.0.7 (squeeze) Release:6.0.7 Codename: squeeze Kamailio as of TODAY from GIT Homer as of TODAY from GIT WebHomer 3.3.1 From GIT Also Using the SOFIA SIPTRACE , problem shows both using the global sip trace or individual profile siptrace. Thanks for your time Antonio ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] base64 transformation
+1 for me too. Great idea. Skyler On 3/28/2013 3:06 AM, Alex Balashov wrote: I'm all in favour of it, as it would be quite useful to us likewise! Andreas Granig agra...@sipwise.com wrote: Hi guys Maybe I missed something, but looks like there is no base64 encode/decode transformation in PV, right? I think we're going to add one, as it might be handy to do such transformations directly from within the config file. One case where this could be used is that some UAs are picky in regards to URIs as URI params, e.g. P-Foo: sip:al...@example.org;x='sip:1.2.3.4:1234' which could be changed into P-Foo: sip:al...@example.org;x=c2lwOjEuMi4zLjQ6MTIzNAo= which might be understood more easily (although it's still just a work-around for broken UAs, but that's how life is). Any objections against such a transformation? Andreas ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Help with SIP over Websocket audio call
Hi, New to Kamailio. I have my Kamailio 4.0 server with websocket support, and the users can register using the JsSIP Tryit sample WebRTC application. However, after registration, the users can't place an audio call. I see no ringing on the remote browser. I don't know how to debug this further to find out what the problem is. Can anyone help with clues or debug? In Debug log I can see the websocket ws_frame.c decode the websocket message into SIP, and I see normal SIP call flow for an INVITE. However, nothing indicating a call. With this JsSIP, I can do chat through Kamailio SIP over WebSockets. With this Kamailio server, SIP User Agent Clients work just fine to register and place SIP call with audio. It's just that WebRTC audio calls don't work with JsSIP sample application with Kamailio 4.0 websocket module. Kamailio websocket configuration borrowed from: https://gist.github.com/jesusprubio/4066845 Any help debugging this appreciated. Brad ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Iimitations of xcap server in kamailio
Has anyone else noticed issues when adding a large number of contacts to your buddy list? I was using Jitsi and at about 40 contacts I was encountering issues in that the subsequent contacts would not get added to my buddy list. Ttyl, Dave ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Help with SIP over Websocket audio call: 405 Method Not Allowed
Hi, New to Kamailio. I have my Kamailio 4.0 server with websocket support, and the users can register using the JsSIP Tryit sample WebRTC application. They can do 'chat' feature of JsSIP Tryit using kamailio 4.0 sip over websockets module. However, after registration, the users can't place an audio call. I see no ringing on the remote browser. Can anyone help with clues or debug? In Debug log I can see the websocket ws_frame.c decode the websocket message into SIP, and I see normal SIP call flow for an INVITE. However, nothing indicating a call. I ran 'ngrep -p -w -W byline port ' (WS port) and see that I'm getting an error response to browser UA of 405: Method Not Allowed. I've isolated it down to the this snippet in the kamailio.cfg for route[LOCATION]: $avp(oexten) = $rU; if (!lookup(location)) { $var(rc) = $rc; route(TOVOICEMAIL); t_newtran(); switch ($var(rc)) { case -1: case -3: send_reply(404, Not Found); exit; case -2: send_reply(405, TEST: Method Not Allowed); exit; } } The switch case is returning -2, for some reason. Any help in debugging this appreciated. ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Iimitations of xcap server in kamailio
There are a number of core parameter and modparam values you need to increase from their defaults in order to be able to handle large HTTP requests (and therefore large XCAP documents). For example, * tcp_rd_buf_size (core parameter) * tcp_wq_max (core parameter) * sql_buffer_size (core parameter) * buf_size (xcap_server modparam) Regards, Peter Has anyone else noticed issues when adding a large number of contacts to your buddy list? I was using Jitsi and at about 40 contacts I was encountering issues in that the subsequent contacts would not get added to my buddy list. Ttyl, Dave ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users -- Peter Dunkley Technical Director Crocodile RCS Ltd ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] Help with SIP over Websocket audio call: 405 Method Not Allowed
Hello, In SIP you can put an Allow: header in REGISTER requests to say which methods the registering end-point is capable of receiving. If you get a -2 returned from lookup() it means that the method for the request (in this case INVITE) was not in the Allow: header in the REGISTER. You can check this by looking at the REGISTER request in a trace and by inspecting the location records stored in Kamailio (use the ul.dump command in kamctl for this). You can disable method filtering in the Kamailio registrar module by ensuring that the method_filtering modparam is set to 0 (or just not set at all as disabled is the default). Doing this should prevent lookup() ever returning -2. Regards, Peter Hi, New to Kamailio. I have my Kamailio 4.0 server with websocket support, and the users can register using the JsSIP Tryit sample WebRTC application. They can do 'chat' feature of JsSIP Tryit using kamailio 4.0 sip over websockets module. However, after registration, the users can't place an audio call. I see no ringing on the remote browser. Can anyone help with clues or debug? In Debug log I can see the websocket ws_frame.c decode the websocket message into SIP, and I see normal SIP call flow for an INVITE. However, nothing indicating a call. I ran 'ngrep -p -w -W byline port ' (WS port) and see that I'm getting an error response to browser UA of 405: Method Not Allowed. I've isolated it down to the this snippet in the kamailio.cfg for route[LOCATION]: $avp(oexten) = $rU; if (!lookup(location)) { $var(rc) = $rc; route(TOVOICEMAIL); t_newtran(); switch ($var(rc)) { case -1: case -3: send_reply(404, Not Found); exit; case -2: send_reply(405, TEST: Method Not Allowed); exit; } } The switch case is returning -2, for some reason. Any help in debugging this appreciated. ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users -- Peter Dunkley Technical Director Crocodile RCS Ltd ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users