SIP call on android: plain RTP session impossible (intentionally unencrypted LAN-PBX)
Hi, since Android 13 doesn't offer native SIP support anymore, I thought this great Jami thing could step in... Unfortunately, it was quiet inconvenient to get at least some idea why this doesn't work with my LAN/VPN PBX
(Inconvenience: LAN/VPN PBX is asterisk 1.6, which doesn't use identical string for account identification and user authentication; the user corresponding to the password for authentication is different to the name of the SIP account. It's possible to set Jami up that way, but it's quiet hidden - besides some more not so minor UI nits on android, but that will be a different issue report.)
I checked that all Security->Security switches are off (SRTP and TLS transport).
1.) Initiating (outgoing) call fails because:
"Rejecting secure audio stream without encryption details: audio 19686 RTP/SAVP 104 9 2 112 111 110 8 0 101"
<--- SIP read from UDP:172.21.97.226:5060 ---> [115/1865] INVITE sip:11@pbx.example.net SIP/2.0
Via: SIP/2.0/UDP 172.21.97.226:5060;rport;branch=z9hG4bKPjaf1c522c-6e92-4539-b899-15c2bad55ad1
Max-Forwards: 70
From: sip:tobimob_line1@pbx.example.net;tag=b2110c22-6e14-4381-8a99-cc1e40d3872f
To: sip:11@pbx.example.net
Contact: sip:tobimob_line1@172.21.97.226:5060
Call-ID: 4b970369-1b13-44da-b798-3a74f51d8c39
CSeq: 629 INVITE
Subject: Phone call
Allow: SUBSCRIBE, NOTIFY, REFER, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, OPTIONS, MESSAGE, PUBLISH
Supported: replaces
User-Agent: Jami Daemon 13.7.0 (android)
Authorization: Digest username="tobi.huber", realm="pbx.example.net", nonce="3b54e054", uri="sip:11@pbx.example.net", response="4070f25aadda2536ee24058551dfb64 1", algorithm=MD5
Content-Type: application/sdp
Content-Length: 1047v=0
o=localhost 3890394360 0 IN IP4 172.21.97.226
s=Call ID 8706183892147327
c=IN IP4 172.21.97.226
t=0 0
a=ice-ufrag:42a09c4e
a=ice-pwd:04afb39763f13c7f32a67b91
m=aud--- (15 headers 27 lines) ---
Sending to 172.21.97.226:5060 (no NAT)
Using INVITE request as basis request - 4b970369-1b13-44da-b798-3a74f51d8c39
Found peer 'tobimob_line1' for 'tobimob_line1' from 172.21.97.226:5060
Found RTP audio format 104
Found RTP audio format 9
Found RTP audio format 2
Found RTP audio format 112
Found RTP audio format 111 Found RTP audio format 110 Found RTP audio format 8 Found RTP audio format 0 Found RTP audio format 101 Found unknown media description format opus for ID 104 Found audio description format G722 for ID 9 Found audio description format G726-32 for ID 2 Found audio description format speex for ID 112 Found audio description format speex for ID 111 Found audio description format speex for ID 110 Found audio description format PCMA for ID 8 Found audio description format PCMU for ID 0 Found audio description format telephone-event for ID 101 [Apr 13 19:05:59] ERROR[101987][C-000005d5]: chan_sip.c:33575 int setup_srtp(struct sip_srtp **): No SRTP module loaded, can't setup SRTP session. [Apr 13 19:05:59] WARNING[101987][C-000005d5]: chan_sip.c:10417 int process_sdp(struct sip_pvt *, struct sip_request *, int): Rejecting secure audio stream witho ut encryption details: audio 19686 RTP/SAVP 104 9 2 112 111 110 8 0 101
Why does it send RTP/SAVP although I disabled SRTP?
2.) Incoming call signalling works, but not possible to establish RTP session:
"Ignoring audio media offer because port number is zero" and
"Failing due to no acceptable offer found"
Ringing:
<--- SIP read from UDP:172.21.97.226:5060 ---> SIP/2.0 180 Ringing Via: SIP/2.0/UDP 172.21.98.12:5060;received=172.21.98.12;branch=z9hG4bK0d2bf1b6 Call-ID: 1e4bf56a62264ba6792450e4506bed52@pbx.example.net From: "T. Huber (22)" sip:thbuero@pbx.example.net;tag=as48fb14ca To: sip:tobimob_line1@172.21.97.226;tag=6c456d21-e6ae-4c85-bf04-da0aaf56e758 CSeq: 102 INVITE User-Agent: Jami Daemon 13.7.0 (android) Allow: SUBSCRIBE, NOTIFY, REFER, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, OPTIONS, MESSAGE, PUBLISH Contact: sip:tobimob_line1@172.21.97.226:5060 ... (snipped)
Accepting call on Jami:
<--- SIP read from UDP:172.21.97.226:5060 ---> SIP/2.0 200 OK Via: SIP/2.0/UDP 172.21.98.12:5060;received=172.21.98.12;branch=z9hG4bK0d2bf1b6 Call-ID: 1e4bf56a62264ba6792450e4506bed52@pbx.example.net From: "T. Huber (22)" sip:thbuero@pbx.example.net;tag=as48fb14ca To: sip:tobimob_line1@172.21.97.226;tag=6c456d21-e6ae-4c85-bf04-da0aaf56e758 CSeq: 102 INVITE User-Agent: Jami Daemon 13.7.0 (android) Allow: SUBSCRIBE, NOTIFY, REFER, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, OPTIONS, MESSAGE, PUBLISH Supported: replaces Contact: sip:tobimob_line1@172.21.97.226:5060 Content-Type: application/sdp Content-Length: 142
v=0 o=localhost 3890395686 1 IN IP4 172.21.97.226 s=Call ID 5890041505306313 c=IN IP4 172.21.97.226 t=0 0 m=audio 0 RTP/AVP 9 8 0 3 101 <------------->
chan_sip.c:10008 int process_sdp(struct sip_pvt *, struct sip_request *, int): Ignoring audio media offer [5/1992] port number is zero chan_sip.c:10438 int process_sdp(struct sip_pvt *, struct sip_request *, int): Failing due to no acceptabl[3/1992] found
Here's a working internal call, where sipdroid is the user agent on the same phone:
<--- SIP read from UDP:172.21.97.226:40739 --->
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 172.21.98.12:5060;branch=z9hG4bK04f5274c
To: sip:tobimob_line1@10.26.229.169:40739;transport=udp;tag=fb8b4ff3c7a73ee8 From: "T. Huber (22)" sip:thbuero@pbx.example.net;tag=as686012bd Call-ID: 3547fb4e68213eb90d8295ae221e36ea@pbx.example.net CSeq: 102 INVITE Server: Sipdroid/6.3 beta/Pixel 7 Content-Length: 198 Content-Type: application/sdp ... (snipped)
Accepting call on SIPdroid:
SIP/2.0 200 OK Via: SIP/2.0/UDP 172.21.98.12:5060;branch=z9hG4bK04f5274c To: sip:tobimob_line1@10.26.229.169:40739;transport=udp;tag=fb8b4ff3c7a73ee8 From: "T. Huber (22)" sip:thbuero@pbx.example.net;tag=as686012bd Call-ID: 3547fb4e68213eb90d8295ae221e36ea@pbx.example.net CSeq: 102 INVITE Contact: sip:tobimob_line1@10.26.229.169:40739;transport=udp Server: Sipdroid/6.3 beta/Pixel 7 Content-Length: 198 Content-Type: application/sdp
v=0 o=tobimob_line1@pbx.example.net 0 0 IN IP4 10.26.229.169 s=Session SIP/SDP c=IN IP4 10.26.229.169 t=0 0 m=audio 21000 RTP/AVP 9 101 a=rtpmap:9 G722/8000 a=rtpmap:101 telephone-event/8000 <------------->
Significant difference here is "m=audio ...." lines.
With SIPdroid (the working incomming call), it reads
m=audio 21000 RTP/AVP 9 101
while with jami (not working)
m=audio 0 RTP/AVP 9 8 0 3 101
I'd very much appreciate if somebody could take care and bring back originating strenghts of Jami in that it's usable as a working SIP UA - for plain RTP too! Especially due to dropped native SIP support in recent android versions!
The android settings UI is broken too, like already mentioned, but ther's the workaround to use it in landscape mode, which makes it possible to sroll the account-enabler switch out of overlapping tab selection area... Will tell in a different issue report.
Thanks in advance,
-Tobi