Hello,
I have been trying for several weeks to make calls from a SIP client (Linphone) to a WEB client which is SIPML5 but without success. However, calling the other way works perfectly.
To be more precise when a call is launched from Linphone to SIPML5 we can see that it hangs up immediately. On the side of the browser where SIPML5 is opened (Firefox or Chrome) we can see that no request arrives.
Here is the SIPML5 configuration:
Here is the Asterisk 18.2.2 (In a Docker under Linux) configuration:
- extensions.conf:
[parking]
exten => 216,1,Wait(1)
exten => 216,2,Answer
exten => 216,3,Dial(PJSIP/216)
exten => 216,4,Hangup
exten => webrtc_client,1,Wait(1)
exten => webrtc_client,2,Dial(PJSIP/webrtc_client)
exten => webrtc_client,3,Hangup
- pjsip.conf:
[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0
[216]
type=endpoint
transport=transport-udp
context=parking
use_avpf=yes
media_encryption=sdes
media_use_received_transport=yes
disallow=all
allow=ulaw
allow=alaw
allow=g729
allow=g722
auth=216
aors=216
callerid=216<parking>
[216]
type=auth
auth_type=userpass
password=***********
username=216
[216]
type=aor
max_contacts=1
[transport-wss]
type=transport
protocol=wss
bind=0.0.0.0
[webrtc_client]
type=aor
max_contacts=5
remove_existing=yes
[webrtc_client]
type=auth
auth_type=userpass
username=webrtc_client
password=******************
[webrtc_client]
type=endpoint
transport=transport-wss
webrtc=yes
context=parking
disallow=all
allow=ulaw
allow=alaw
allow=g729
allow=g722
auth=webrtc_client
aors=webrtc_client
callerid=webrtc<parking>
-http.conf:
[general]
servername=Asterisk
enabled=yes
bindaddr=0.0.0.0
bindport=8088
prefix=asterisk
sessionlimit=100
enablestatic=yes
redirect = / /static/dev_interface_Asterisk/edition.html
tlsenable=yes
tlsbindaddr=0.0.0.0:8089
tlscertfile=/etc/asterisk/keys/asterisk.pem
tlsprivatekey=/etc/asterisk/keys/asterisk.key
And finally here is the trace with the part containing the error during a call test:
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Stream 0:audio-0:audio:sendrecv (ulaw|alaw|g729|g722) added with mid audio-0
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Done with 0:audio-0:audio:sendrecv (ulaw|alaw|g729|g722)
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Adding bundle groups (if available)
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Copying connection details
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Processing media 0
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Media 0 reset
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c:
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Method is INVITE
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004
[Sep 27 11:18:50] DEBUG[21655] res_pjsip/pjsip_resolver.c: Performing SIP DNS resolution of target '172.21.38.236'
[Sep 27 11:18:50] DEBUG[21655] res_pjsip/pjsip_resolver.c: Transport type for target '172.21.38.236' is '(null)'
[Sep 27 11:18:50] DEBUG[21655] res_pjsip/pjsip_resolver.c: Target '172.21.38.236' is an IP address, skipping resolution
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004 Event: TSX_STATE Inv State: DISCONNCTD
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: Function session_inv_on_state_changed called on event TSX_STATE
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The state change pertains to the endpoint 'webrtc_client(PJSIP/webrtc_client-00000004)'
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The inv session still has an invite_tsx (0x7f02db5db0c8)
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: There is no transaction involved in this state change
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The current inv state is DISCONNCTD
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004: Source of transaction state change is TRANSPORT_ERROR
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c:
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004 TSX State: Terminated Inv State: DISCONNCTD
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: Function session_inv_on_tsx_state_changed called on event TSX_STATE
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The state change pertains to the endpoint 'webrtc_client(PJSIP/webrtc_client-00000004)'
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The inv session does NOT have an invite_tsx
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The UAC INVITE transaction involved in this state change is 0x7f02db5db0c8
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The current transaction state is Terminated
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The transaction state change event is TRANSPORT_ERROR
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: The current inv state is DISCONNCTD
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: Disconnected
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: (null session) TSX State: Terminated Inv State: DISCONNCTD
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c:
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c: RC: 0
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c: PJSIP/webrtc_client-00000004
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c:
[Sep 27 11:18:50] DEBUG[21681][C-00000003] channel.c: PJSIP/216-00000003: Dropping redundant connected line update "webrtc" <parking>.
[Sep 27 11:18:50] DEBUG[21681][C-00000003] channel.c: Channel 0x7f02d8cfa080 'PJSIP/webrtc_client-00000004' hanging up. Refs: 2
[Sep 27 11:18:50] DEBUG[21681][C-00000003] chan_pjsip.c: PJSIP/webrtc_client-00000004
[Sep 27 11:18:50] DEBUG[21681][C-00000003] chan_pjsip.c: Cause: 503
[Sep 27 11:18:50] DEBUG[21525] cdr.c: Finalized CDR for PJSIP/216-00000003 - start 1664270329.398984 answer 0.000000 end 1664270330.414431 dur 1.015 bill 1664270330.414 dispo FAILED
[Sep 27 11:18:50] VERBOSE[21681][C-00000003] app_dial.c: Everyone is busy/congested at this time (1:0/1/0)
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c: PJSIP/webrtc_client-00000004
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/webrtc_client-00000004 Response 503
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c:
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: webrtc_client: Destroying SIP session
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) DTLS srtp - stopped timeout timer'
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) DTLS srtp - stopped timeout timer'
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) DTLS stop
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) DTLS srtp - stopped timeout timer'
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) DTLS srtp - stopped timeout timer'
[Sep 27 11:18:50] DEBUG[21681][C-00000003] app_dial.c: PJSIP/216-00000003: No outging channels available
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) ICE RTP transport deallocating
[Sep 27 11:18:50] DEBUG[21655] res_rtp_asterisk.c: (0x7f02d885b690) ICE stopped
[Sep 27 11:18:50] DEBUG[21681][C-00000003] app_dial.c: Exiting with DIALSTATUS=CONGESTION.
[Sep 27 11:18:50] DEBUG[21655] rtp_engine.c: Destroyed RTP instance '0x7f02d885b690'
[Sep 27 11:18:50] DEBUG[21681][C-00000003] app_dial.c: PJSIP/216-00000003: Done
[Sep 27 11:18:50] DEBUG[21655] channel.c: Channel 0x7f02d8cfa080 'PJSIP/webrtc_client-00000004' destroying
[Sep 27 11:18:50] DEBUG[21681][C-00000003] pbx.c: Launching 'Hangup'
[Sep 27 11:18:50] DEBUG[21525] cdr.c: Finalized CDR for PJSIP/webrtc_client-00000004 - start 1664270330.405554 answer 0.000000 end 1664270330.416349 dur 0.010 bill 1664270330.416 dispo FAILED
[Sep 27 11:18:50] DEBUG[21525] cdr.c: CDR for PJSIP/webrtc_client-00000004 is dialed and has no Party B; discarding
[Sep 27 11:18:50] DEBUG[21655] stasis.c: Destroying topic. name: channel:1664270330.4, detail:
[Sep 27 11:18:50] DEBUG[21655] stasis.c: Topic 'channel:1664270330.4': 0x7f02d84a5370 destroyed
[Sep 27 11:18:50] DEBUG[21655] channel_internal_api.c: <initializing>: MultistreamFormats: (nothing)
[Sep 27 11:18:50] DEBUG[21655] channel_internal_api.c: Channel is being initialized or destroyed
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c:
[Sep 27 11:18:50] DEBUG[21517] devicestate.c: No provider found, checking channel drivers for PJSIP - webrtc_client
[Sep 27 11:18:50] DEBUG[21517] devicestate.c: Changing state for PJSIP/webrtc_client - state 1 (Not in use)
[Sep 27 11:18:50] VERBOSE[21681][C-00000003] pbx.c: Executing [webrtc_client@parking:3] Hangup("PJSIP/216-00000003", "") in new stack
[Sep 27 11:18:50] DEBUG[21681][C-00000003] channel.c: Soft-Hanging (0x20) up channel 'PJSIP/216-00000003'
[Sep 27 11:18:50] DEBUG[21681][C-00000003] pbx.c: Spawn extension (parking,webrtc_client,3) exited non-zero on 'PJSIP/216-00000003'
[Sep 27 11:18:50] VERBOSE[21681][C-00000003] pbx.c: Spawn extension (parking, webrtc_client, 3) exited non-zero on 'PJSIP/216-00000003'
[Sep 27 11:18:50] DEBUG[21681][C-00000003] channel.c: Soft-Hanging (0x10) up channel 'PJSIP/216-00000003'
[Sep 27 11:18:50] DEBUG[21681][C-00000003] channel.c: Channel 0x7f02db5ab190 'PJSIP/216-00000003' hanging up. Refs: 2
[Sep 27 11:18:50] DEBUG[21681][C-00000003] chan_pjsip.c: PJSIP/216-00000003
[Sep 27 11:18:50] DEBUG[21681][C-00000003] chan_pjsip.c: Cause: 503
[Sep 27 11:18:50] DEBUG[21655] chan_pjsip.c: PJSIP/216-00000003
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/216-00000003 Response 503
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/216-00000003: Method is INVITE, Response is 503 Service Unavailable
[Sep 27 11:18:50] DEBUG[21655] res_pjsip_session.c: PJSIP/216-00000003
[Sep 27 11:18:50] VERBOSE[21655] res_pjsip_logger.c: <--- Transmitting SIP response (369 bytes) to UDP:172.21.38.236:5060 --->
SIP/2.0 503 Service Unavailable
Via: SIP/2.0/UDP 172.21.38.236:5060;rport=5060;received=172.21.38.236;branch=z9hG4bK.1jH3Y1hfB
Call-ID: ~-NoF7d-dr
From: "216" <sip:216@172.21.38.222>;tag=yO1RnUwCh
To: <sip:webrtc_client@172.21.38.222>;tag=aFKykoc3031flZQBDIhefL5wEf59WXT5
CSeq: 21 INVITE
Server: Asterisk PBX 18.2.2
Reason: Q.850;cause=34
Content-Length: 0
After long days of research on the internet (forum, website …) I do not know what to look for.
If you need more precision do not hesitate.
Thank you for your interest.