Hello!
It’s been several years since I’ve used Kamailio. My current employer wants to implement WebRTC, which is currently not supported in our SIP backend, and asked if I could set up a Kamailio server as a gateway.
I’ve been able to make calls in all directions between SIP and WebRTC clients registered locally on Kamailio. When I tried to connect the server to the SIP backend, I ran into an issue. I’m able to register SIP clients in the backend via
the gateway and make calls everywhere. However, the WebRTC client fails to register. Here are the messages between the Kamailio gateway and the SIP backend:
U 2018/05/09 10:12:58.316643 GATEWAY:15060 -> DOMAIN:5060
REGISTER sip:DOMAIN SIP/2.0.
Via: SIP/2.0/UDP GATEWAY:15060;branch=z9hG4bK4fc6.04d1730be5b78d595c69a3aa137987c1.0.
Via: SIP/2.0/AUTO lr2l9s72ehhc.invalid;rport=61353;received=CLIENT;branch=z9hG4bK5927151.
Max-Forwards: 68.
To: <sip:4777519304@DOMAIN>.
From: <sip:4777519304@DOMAIN>;tag=9qhqhrnj3s.
Call-ID: j5h7830ivr5dfc2mn5sov1.
CSeq: 4 REGISTER.
Contact: <sip:c3qkm4fv@lr2l9s72ehhc.invalid;transport=ws>;+sip.ice;reg-id=1;+sip.instance="<urn:uuid:0ef2deac-2d56-465a-840b-543b9fd01af8>";expires=600.
Expires: 600.
Allow: INVITE,ACK,CANCEL,BYE,UPDATE,MESSAGE,OPTIONS,REFER,INFO.
Supported: path,gruu,outbound.
User-Agent: JsSIP 3.2.9.
Content-Length: 0.
Path: <sip:GATEWAY:15060;lr>.
.
U 2018/05/09 10:12:58.368409 DOMAIN:5060 -> GATEWAY:15060
SIP/2.0 400 Wrong transport. Provided transport either invalid or not supported..
Via: SIP/2.0/UDP GATEWAY:15060;branch=z9hG4bK4fc6.04d1730be5b78d595c69a3aa137987c1.0.
Via: SIP/2.0/AUTO lr2l9s72ehhc.invalid;rport=61353;received=CLIENT;branch=z9hG4bK5927151.
To: <sip:4777519304@DOMAIN>;tag=91334f57.
From: <sip:4777519304@DOMAIN>;tag=9qhqhrnj3s.
Call-ID: j5h7830ivr5dfc2mn5sov1.
CSeq: 4 REGISTER.
Content-Length: 0.
I believe that this error message is caused by ‘;transport=ws’ in the Contact header. I’m not allowed to modify this header.
In the backend database, I found that some other clients have ‘;transport=UDP’ in their path headers, so I tried to add that. (Why can I not add parameters in path module without adding username?) I still got the same error.
How do I best proceed?
For your information: We have outsourced the development of the WebRTC client, so we are able to change it. We also have the option of paying the supplier of the backend for development there.
With kind regards
Pan B. Christensen
Developer
Phonect AS
Brugata 19, PB 9156 Grønland, N-0133 Oslo, Norway
E-mail: pan.christensen@phonect.no
Mobile: +47 41 88 88 00