[asterisk-bugs] [JIRA] (ASTERISK-28901) pjsip behaves incorrectly when sending RTP, it sends it to a private IP

Asterisk Team (JIRA) noreply at issues.asterisk.org
Sun May 17 08:48:25 CDT 2020


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

Asterisk Team commented on ASTERISK-28901:
------------------------------------------

This issue has been reopened as a result of your commenting on it as the reporter. It will be triaged once again as applicable.

> pjsip behaves incorrectly when sending RTP, it sends it to a private IP
> -----------------------------------------------------------------------
>
>                 Key: ASTERISK-28901
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-28901
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Channels/chan_pjsip
>    Affects Versions: 13.33.0, 16.10.0
>         Environment: Linux
>            Reporter: Private Name
>         Attachments: asteriskbug.txt, pjsip.conf
>
>
> I found that the PJSIP incorrectly sends RTP back to a private address, while in the same exact circumstances the old sip channel works correctly.
> My phone is located behind a NAT, 172.16.0.0/21.
> Asterisk 16 is on a public IP.
> PJSIP has the config below:
> force_rport=yes
> direct_media=yes
> disable_direct_media_on_nat = yes
> direct_media_method=invite
> But when I send a call I see the RTP being sent to my private address, vs the public IP. This only happens when Asterisk has dialed the call to another carrier. If instead of Dial I choose Answer() and MusicOnHold, then the RTP gets shipped to the right address.
> This is a sample of the erroneous behavior:
> Got  RTP packet from    XX.XX.XX.XX:17510 (type 00, seq 024786, ts 017440, len 000160)
> Sent RTP packet to      172.16.7.254:50798 (type 00, seq 010736, ts 017440, len 000160)
> 172.16.7.254 is my private address
> This is the call flow:
> Sostphone --->Router---->Asterisk16Public--->Asterisk16Public (musicOnHold)
> On the first Asterisk16Public I see the RTP being sent to the Private IP.
> I am uploading my PJSIP.conf and trace that shows, it its last line, the change to the 
> The dialplan is: dial(${EXTEN}@asterisk)
> NOTE: the first few seconds into the call, the RTP is correctly sent to my public IP. Then there is a reinvite and asterisk switches to the private IP. 
> I am uploading a trace that shows in its last line the issue. Until then the behavior is correct.
> In the trace I replaced the public IPs and numbers for strings.



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



More information about the asterisk-bugs mailing list