[Home]

Summary:ASTERISK-26011: [patch]PJSIP: add "via_addr", "via_port", "call_id" to contacts
Reporter:Alexei Gradinari (alexei gradinari)Labels:
Date Opened:2016-05-10 15:59:43Date Closed:2016-07-05 11:42:32
Priority:MinorRegression?
Status:Closed/CompleteComponents:Resources/res_pjsip Resources/res_pjsip_registrar
Versions:13.9.0 Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:As res_pjsip_nat rewrites contact's address, only the last Via header can contain the source address of registered endpoint.
Also Call-Id header may contain the source address of registered endpoint.

Added "via_addr", "via_port", "call_id" to contacts.
Added new fields ViaAddress,CallID to AMI event ContactStatus.

[edit by Rusty - adding Alexei's further explanation]
To manually manage/provisioning remote (behind the NAT) SIP devices it's necessary to know internal ip-address.
We could get internal ip-address using old-SIP AMI command 'SIPShowPeer'
For example
Reg-Contact : sip:user@192.168.1.2:5060
Using PJSIP we couldn't because res_pjsip_nat rewrites contact's address before
AMI event is sent.
To find out internal ip-address 2 SIP headers can help: Via and Call-Id.
Comments:By: Asterisk Team (asteriskteam) 2016-05-10 15:59:44.448-0500

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

By: Walter Doekes (wdoekes) 2016-05-11 03:18:49.803-0500

Hi. Thanks for the patches.
If you could you add the URL to the gerrit review in the "Reviewboard URL" field in the future, it helps. Thanks :)

I did not get a chance too look at your patch in gerrit at this point, because it is down (daily reload), but I wonder what the purpose of this patch is.

res_pjsip_nat rewrites the contact: ok, and then. When do we want the via_addr/via_port/callid, why do we want it? What would we do with it? Is it worth storing all of that for every registered peer always?



By: Alexei Gradinari (alexei gradinari) 2016-05-11 15:46:07.359-0500

Hi Walter,

If you click on "Gerrit Reviews" tab it has all gerrit reviews for this topic.

To manually manage/provisioning remote (behind the NAT) SIP devices it's necessary to know internal ip-address.
We could get internal ip-address using old-SIP AMI command 'SIPShowPeer'
For example
Reg-Contact : sip:user@192.168.1.2:5060
Using PJSIP we couldn't because res_pjsip_nat rewrites contact's address before
AMI event is sent.
To find out internal ip-address 2 SIP headers can help: Via and Call-Id.