[SR-Users] Route Between WebSockets without rtpengine getting into the mix

Daniel-Constantin Mierla miconda at gmail.com
Thu Mar 5 21:51:24 CET 2015


Hello,

you can do nat_uac_test("64") to identify that call comes in via
websocket and after lookup("location") you can see it is going out via
websocket. If both coditions are true, then you can skip engaging rtpengine.

Cheers,
Daniel

On 03/03/15 07:42, Don Fanning wrote:
> Hello All,
>
> Prior to going down the rtpengine path for another need, calling was
> working fine between WSS client.  Now that I've added in some pieces
> from caruizdiaz's config
> [https://github.com/caruizdiaz/kamailio-ws/blob/master/kamailio-ws.cfg] relating
> to SETUP_BY_TRANSPORT, it has broken that functionality.
>
> Is there a way to skip rtpengine if the originator and destination are
> both on wss?
>
>
>
> route[RELAY] {
>
>         # enable additional event routes for forwarded requests
>         # - serial forking, RTP relaying handling, a.s.o.
>         if (is_method("INVITE|BYE|SUBSCRIBE|UPDATE")) {
>                 t_on_branch("MANAGE_BRANCH");
>                 t_on_reply("MANAGE_REPLY");
>         }
>         if (is_method("INVITE")) {
>                 route(SETUP_BY_TRANSPORT);
>                 if(!t_is_set("failure_route"))
> t_on_failure("MANAGE_FAILURE");
>         }
>         if (!t_relay()) {
>                 sl_reply_error();
>         }
>         exit;
> }
>
> route[SETUP_BY_TRANSPORT] {
>
>         if ($ru =~ "transport=ws") {
>                 xlog("L_INFO", "Request going to WS");
>                 if(sdp_with_transport("RTP/SAVPF")) {
>                         rtpengine_manage("rtcp-mux-demux trust-address
> replace-origin replace-session-connection ICE=force DTLS=passive");
>                         t_on_reply("REPLY_WS_TO_WS");
>                         return;
>                 }
>
>                 #rtpengine_manage("rtcp-mux-demux trust-address
> replace-origin replace-session-connection ICE=force DTLS=passive
> RTP/SAVP");
>                 t_on_reply("REPLY_FROM_WS");
>         }
>         else if ($proto =~ "ws") {
>                 xlog("L_INFO", "Request coming from WS");
>                 rtpengine_manage("rtcp-mux-demux trust-address
> replace-origin replace-session-connection ICE=remove DTLS=passive
> RTP/SAVP");
>                 t_on_reply("REPLY_TO_WS");
>         }
>         else {
>                 xlog("L_INFO", "This is a classic phone call");
>                 rtpengine_manage("replace-origin
> replace-session-connection");
>                 t_on_reply("MANAGE_CLASSIC_REPLY");
>         }
> }
>
> Thanks for any help!
> -Don
>
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference, May 27-29, 2015
Berlin, Germany - http://www.kamailioworld.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20150305/37b72ddf/attachment.html>


More information about the sr-users mailing list