From peter.manley@kombea.com Tue Jun 29 19:43:50 2021 From: Peter Manley To: sr-users@lists.kamailio.org Subject: Re: [SR-Users] Guidance building a WebRTC to Asterisk Intermediate Proxy Date: Tue, 29 Jun 2021 17:43:41 +0000 Message-ID: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2106393189==" --===============2106393189== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Thanks Muhammad, That seems to have done the trick. I am now able to bridge WebRTC to UDP. Regards, Peter Manley M S shaheryarkh at gmail.com Sat Jun 26 03:57:27 CEST 2021 * Previous message (by thread): [SR-Users] Guidance building a WebRTC to = Asterisk Intermediate Proxy * Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] ________________________________ The problem seems to that the kamailio is trying to route it over UDP port using WSS transport, which will never work. You are creating a transport bridge (UDP <-> WSS i.e. stateless transport <-> stateful transport) as well media bridge (RTP <-> SRTP), so it is going to be tricky. I strongly discourage it since things get messy for sequential requests. But you can try the following, Here are some PATH module parameters and functions, you will need to setup. 1. You will need to enable "use_received" parameter to ensure connection tracking. 2. It seems you may have enabled "received_format", so you make sure you do NAT detection and use "handle_ruri_alias" for initial requests. 3. You must also enabled "enable_r2", but with caution, since both ends (i.e. UAC and UAS) can be using same kamailio (proxy) socket for in/out. 4. Make sure to use "add_path_received" instead of "add_path". 5. If using OUTBOUND module then make sure it is loaded BEFORE the PATH module. Thank you. -- Muhammad Shahzad Shafi Burraq Technologies Tel: +49 176 99 83 10 85 On Sat, Jun 26, 2021 at 12:47 AM Peter Manley > wrote: > Hello, > > > > I'm working on building an RTP Proxy which will allow both regular SIP to > SIP transactions and WebRTC to SIP transactions to an Asterisk Server. > > > > SIP UAC < ---UDP/SIP --- > Kamailio/RTPEngine Proxy < ---UDP/SIP----- > > Asterisk Server > > > > AND > > > > WebRTC UAC < ---WSS--- > Kamailio/RTPEngine Proxy < ---UDP/SIP----- > > Asterisk Server > > > > The Kamailio/RTPEngine Proxy is stateless (does not use the tm or > registerer modules), and uses the Path module to replace the Route header > with a Path header. > > > > It works grep for SIP/UDP to SIP/UDP transactions. > > > > HOWEVER... It only partially works for WSS to SIP/UDP transactions. The > REGISTER/401(Unauthorized), REGISTER/200(OK) transaction works well. > > > > When the Asterisk server sends a SIP Options message, I get the following > error: > > Jun 25 15:47:03 VRTPENGINE kamailio[4953]: INFO: