VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
george.joseph at fairv... Guest
|
Posted: Mon Feb 29, 2016 5:38 pm Post subject: [asterisk-users] PJSIP signaling question |
|
|
On Mon, Feb 29, 2016 at 2:04 PM, Kevin Long <kevin.long@haloprivacy.com (kevin.long@haloprivacy.com)> wrote:
Quote: |
Greetings.
I am using the PJSIP driver with TLS transport, and my endpoints are SIP mobile apps operating in environments that I do not control.
I would like Asterisk to default to sending INVITES and all other SIP signals to endpoints via the existing SIP TLS connection which is already established, rather than trying to create a new TLS connection to an endpoint which is likely behind a NAT which will not allow a new inbound TCP/TLS connection.
My experience with chan_sip suggest to me that this was the default behavior, or more likely a fallback behavior, because I never had this issue before with endpoints not receiving INVITES so long as they were registered and had an open SIP control connection.
I thought that I could avoid these failed outbound connections by commenting out the “transport” option on my endpoint configurations, but tcpdump is showing me that asterisk is still trying to create *new* TLS outbound connections to my endpoints, which are failing.
|
This was actually an issue in pjproject which I just fixed last week.
It's in pjproject "trunk" so you'll have to download and build it from their subversion repository.
Now whether you use "transport=" or not, pjproject will look for an existing connection to the remote endpoint before attempting to create a new one.
I tested it with the current Asterisk 13 branch and I *think* it'll work with recent Asterisk releases as well. If it doesn't, let me know.
Quote: |
Thank you for your time
Kevin
-
My simple pjsip config file:
[transport-tls]
type=transport
protocol=tls
bind=0.0.0.0:5061
local_net=10.50.55.0/24
external_media_address=x.x.x.x
external_signaling_address=x.x.x.x
cert_file=/etc/asterisk/keys/dev1.crt
priv_key_file=/etc/asterisk/keys/dev1.key
ca_list_file=/etc/asterisk/keys/ca.crt
cipher=AES256-SHA
method=tlsv1
;===============EXTENSION 6001
[6000]
type=endpoint
context=internal
disallow=all
allow=ulaw
;transport=transport-tls
auth=auth6000
aors=6000
direct_media=no
rewrite_contact=yes ; necessary if endpoint does not know/register public ip:port
ice_support=no
force_rport=yes
rtp_symmetric=yes
media_encryption=sdes
[auth6000]
type=auth
auth_type=userpass
password=6000
username=6000
[6000]
type=aor
max_contacts=1
remove_existing=yes
;===============EXTENSION 6001
[6001]
type=endpoint
context=internal
disallow=all
allow=ulaw
;transport=transport-tls
auth=auth6001
aors=6001
direct_media=no
rewrite_contact=yes ; necessary if endpoint does not know/register public ip:port
ice_support=no
force_rport=yes
rtp_symmetric=yes
media_encryption=sdes
[auth6001]
type=auth
auth_type=userpass
password=6001
username=6001
[6001]
type=aor
max_contacts=1
remove_existing=yes
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
|
|
|
Back to top |
|
|
george.joseph at fairv... Guest
|
Posted: Tue Mar 01, 2016 9:38 pm Post subject: [asterisk-users] PJSIP signaling question |
|
|
On Tue, Mar 1, 2016 at 5:37 PM, Kevin Long <kevin.long@haloprivacy.com (kevin.long@haloprivacy.com)> wrote:
Quote: |
Interesting, thanks George. I pulled Asterisk 13 from git and the new pjproject from the SVN and will test accordingly .
|
Yeah, actually you do need Asterisk 13 from git because pjproject deprecated an api in trunk and we only handle that in the current git 13 branch.
Quote: |
I have a few more questions about PJSIP in Asterisk 13:
1. Is there any way to list current ongoing calls and see what codecs are being used in the RTP streams? With chan_sip, “sip show channels” did this.
2. Also with a PJSIP initiated call, is there a way to see how man RTP packets have been sent and received for the call , I am debugging some intermittent 1-way and no-way audio on calls , and I am having trouble figuring out fi it is the client, firewall, or Asterisk/pjsip that is the culprit .
|
Unfortunately, no to both (at least that I'm aware of). I remember looking at the channel stats a long while back and for some reason didn't go any further. I can re-look.
|
|
Back to top |
|
|
george.joseph at fairv... Guest
|
Posted: Fri Mar 04, 2016 3:01 am Post subject: [asterisk-users] PJSIP signaling question |
|
|
On Thu, Mar 3, 2016 at 8:25 PM, Kevin Long <kevin.long@haloprivacy.com (kevin.long@haloprivacy.com)> wrote:
Quote: |
Thanks George I appreciate the info . Being able to see what codec is in use for call in progress is very handy sometimes.
As far as the RTP stats goes, I see there is some info with “rtp” and “rtcp” commands which can be useful for troubleshooting. A running tally of # packets or bandwidth used would be awesome in along with the codec in "pjsip show channels" or something like that.
Im not certain, but I think the TLS signalling problem from this email may be happening to me again after patching for another pjsip/NAT issue which was with the external_media_address not working and the internal IP being sent in the SDP from asterisk - I applied this patch to the codebase and recompiled I am seeing the TLS “new transport” issue again , I think.
|
I've lost track of who's applying what patches to which codebase.
Which patch did you apply for "external_media_address not working"?
|
|
Back to top |
|
|
george.joseph at fairv... Guest
|
Posted: Fri Mar 04, 2016 10:34 am Post subject: [asterisk-users] PJSIP signaling question |
|
|
On Fri, Mar 4, 2016 at 1:16 AM, Kevin Long <kevin.long@haloprivacy.com (kevin.long@haloprivacy.com)> wrote:
Quote: | Hi George the patch was from here , you wrote it I believe . I pulled asterisk 13 from git, apply this patch which fixed RTP issue , but I think tla transport issue came back for me .
https://gerrit.asterisk.org/#/c/2346/
|
Oh, that one, OK. It should be merged now so if you 'git pull' on 13 now, you should get it. The transport re-use issue was in pjproject so is it possible that you're not compiling against the latest trunk?
Quote: |
Thank you
Sent from my iPhone
On Mar 4, 2016, at 12:01 AM, George Joseph <george.joseph@fairview5.com (george.joseph@fairview5.com)> wrote:
Quote: |
On Thu, Mar 3, 2016 at 8:25 PM, Kevin Long <kevin.long@haloprivacy.com (kevin.long@haloprivacy.com)> wrote:
Quote: |
Thanks George I appreciate the info . Being able to see what codec is in use for call in progress is very handy sometimes.
As far as the RTP stats goes, I see there is some info with “rtp” and “rtcp” commands which can be useful for troubleshooting. A running tally of # packets or bandwidth used would be awesome in along with the codec in "pjsip show channels" or something like that.
Im not certain, but I think the TLS signalling problem from this email may be happening to me again after patching for another pjsip/NAT issue which was with the external_media_address not working and the internal IP being sent in the SDP from asterisk - I applied this patch to the codebase and recompiled I am seeing the TLS “new transport” issue again , I think.
|
I've lost track of who's applying what patches to which codebase.
Which patch did you apply for "external_media_address not working"?
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
|
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
|
|
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|