[asterisk-bugs] [JIRA] (ASTERISK-29978) chan_sip: Asterisk do not use the first media format in reply with SDP

Mark Petersen (JIRA) noreply at issues.asterisk.org
Mon Mar 21 08:14:06 CDT 2022


    [ https://issues.asterisk.org/jira/browse/ASTERISK-29978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=258412#comment-258412 ] 

Mark Petersen edited comment on ASTERISK-29978 at 3/21/22 8:12 AM:
-------------------------------------------------------------------

--- ORDER is correct ---
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 8 based on m type on 0x7f9311bc2110
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 9 based on m type on 0x7f9311bc2110
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 0 based on m type on 0x7f9311bc2110

chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:8 PCMA/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:9 G722/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:0 PCMU/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:101 telephone-event/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=silenceSupp:off - - - -... UNSUPPORTED OR FAILED.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=fmtp:101 0-15... UNSUPPORTED OR FAILED.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=ptime:20... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=sendrecv... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtcp:57221... UNSUPPORTED OR FAILED.
res_rtp_asterisk.c:1235 ast_rtp_ice_set_role: (0x7f93300f2dd0) ICE set role failed; no ice instance
acl.c:1047 ast_ouraddrfor: For destination '10.253.253.170', our source address is '10.253.248.16'.
res_rtp_asterisk.c:8542 ast_rtp_remote_address_set: (0x7f93300f2dd0) RTCP setting address on RTP instance

--- ORDER has changed from above ---
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 0 (0x7f934803f768) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 8 (0x7f934800bc68) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 9 (0x7f934811cd98) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 101 (0x7f93480f8978) from 0x7f9311bc2110 to 0x7f93300f2fa8

res_rtp_asterisk.c:8339 ast_rtp_prop_set: (0x7f93300f2dd0) RTCP ignoring duplicate property
chan_sip.c:11217 process_sdp: We're settling with these formats: (g722)



was (Author: asterisk.org at zombie.dk):
--- ORDER is correct ---
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 8 based on m type on 0x7f9311bc2110
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 9 based on m type on 0x7f9311bc2110
rtp_engine.c:1311 ast_rtp_codecs_payloads_set_m_type: Setting tx payload type 0 based on m type on 0x7f9311bc2110

chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:8 PCMA/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:9 G722/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:0 PCMU/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtpmap:101 telephone-event/8000... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=silenceSupp:off - - - -... UNSUPPORTED OR FAILED.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=fmtp:101 0-15... UNSUPPORTED OR FAILED.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=ptime:20... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=sendrecv... OK.
chan_sip.c:10903 process_sdp: Processing media-level (audio) SDP a=rtcp:57221... UNSUPPORTED OR FAILED.
res_rtp_asterisk.c:1235 ast_rtp_ice_set_role: (0x7f93300f2dd0) ICE set role failed; no ice instance
acl.c:1047 ast_ouraddrfor: For destination '10.253.253.170', our source address is '10.253.248.16'.
res_rtp_asterisk.c:8542 ast_rtp_remote_address_set: (0x7f93300f2dd0) RTCP setting address on RTP instance

--- ORDER of has changed from above ---
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 0 (0x7f934803f768) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 8 (0x7f934800bc68) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 9 (0x7f934811cd98) from 0x7f9311bc2110 to 0x7f93300f2fa8
rtp_engine.c:1197 rtp_codecs_payloads_copy_tx: Copying tx payload mapping 101 (0x7f93480f8978) from 0x7f9311bc2110 to 0x7f93300f2fa8

res_rtp_asterisk.c:8339 ast_rtp_prop_set: (0x7f93300f2dd0) RTCP ignoring duplicate property
chan_sip.c:11217 process_sdp: We're settling with these formats: (g722)


> chan_sip: Asterisk do not use the first media format in reply with SDP
> ----------------------------------------------------------------------
>
>                 Key: ASTERISK-29978
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-29978
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Channels/chan_sip/CodecHandling
>    Affects Versions: 16.24.1, 18.10.1
>            Reporter: Mark Petersen
>         Attachments: Asterisk_debug.log, tcpdump-dev-asterisk.pcap
>
>
> when Asterisk receive 200 OK from Bob, it do not use the first codec in the 200 OK
> causing mitch match RTP, witch result in one way sound on most phones
> sip.conf
> disallow=all
> allow=g722,alaw,ulaw,gsm
> sip show peer hpbx 
>   Codecs       : (g722|alaw|ulaw|gsm)
> INVITE 
> m=audio 19534 RTP/AVP 8 9 0 3 101
> a=rtpmap:8 PCMA/8000
> a=rtpmap:9 G722/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:3 GSM/8000
> a=rtpmap:101 telephone-event/8000
> 200 OK
> m=audio 51172 RTP/AVP 8 9 0 101
> a=rtpmap:8 PCMA/8000
> a=rtpmap:9 G722/8000
> a=rtpmap:0 PCMU/8000
> a=rtpmap:101 telephone-event/8000
> asterisk send using rtpmap:9 G722/8000 
> but should be using rtpmap:8 PCMA/8000
> according ti RFC https://datatracker.ietf.org/doc/html/rfc3264#section-7



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list