Sponsor: VoiceMeUp - Corporate & Wholesale VoIP Services

VoIP Mailing List Archives
Mailing list archives for the VoIP community
 SearchSearch 

[asterisk-users] asterisk stun setup , not using public ip returned by stun server


 
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> Asterisk Users
View previous topic :: View next topic  
Author Message
chandapure.shivu89 at ...
Guest





PostPosted: Mon Oct 13, 2014 1:51 am    Post subject: [asterisk-users] asterisk stun setup , not using public ip r Reply with quote

Dear all,


           I have enabled stun module and configured it in asterisk , but asterisk not using stun returned public ip address for any of the sip requests going out of my network.


i have done settings as below



res_stun_monitor.conf  settings:

[general]
stunaddr = stun.ideasip.com
stunrefresh = 30


stun show status
Hostname              Port    Period   Retries Status   ExternAddr  externport 
stun.ideasip.com   3478      30         3        OK       61.12.17.171     39710




sip.conf 
localnet=192.168.0.0/255.255.255.0
register=>jai9999:123456:jai9999@sip2sip.info/jai9999


when above command runs , it is sending register method with my private ip address.

REGISTER sip:sip2sip.info SIP/2.0
Via: SIP/2.0/UDP 192.168.0.187:5060;branch=z9hG4bK46d2b3e0
Max-Forwards: 70
From: <sip:jai9999@sip2sip.info ([email]sip%3Ajai9999@sip2sip.info[/email])>;tag=as555629a9
To: <sip:jai9999@sip2sip.info ([email]sip%3Ajai9999@sip2sip.info[/email])>
Call-ID: 1f5936433e03a04220179d002168e445@127.0.1.1 (1f5936433e03a04220179d002168e445@127.0.1.1)
CSeq: 105 REGISTER
Supported: replaces, timer
User-Agent: ALLO Gateway
Authorization: Digest username="jai9999", realm="sip2sip.info", algorithm=MD5, uri="sip:sip2sip.info", nonce="5436734f53ce50788ae694ed13978eff84bd0fe9", response="51420d5eeed33bd8468dde9373c9ff9f"
Expires: 3600
Contact: <sip:jai9999@192.168.0.187:5060>
Content-Length: 0


In above packet VIA and CONTACT SIP-HEADERS contains the asterisk server private IP address which is behind the NAT , as per my understanding it supposed to be the public ip address of my network.


is this the expected behavior of asterisk while stun is enabled


Thnaks in advance



Thanks & Regards

Shivakumar
Back to top
asterisk-03 at jeremyk...
Guest





PostPosted: Mon Oct 13, 2014 11:15 pm    Post subject: [asterisk-users] asterisk stun setup , not using public ip r Reply with quote

On 10/13/2014 2:50 AM, chandapure shiva wrote:
Quote:
In above packet VIA and CONTACT SIP-HEADERS contains the asterisk server
private IP address which is behind the NAT , as per my understanding it
supposed to be the public ip address of my network.

do you also have the appropriate nat statement in sip.conf ?

since you have the 'stun show status' command, i beleive the correct nat
statement is nat=force_rport,comedia in the general section.

--

Jeremy Kister
http://jeremy.kister.net./


--
_____________________________________________________________________
-- 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
chandapure.shivu89 at ...
Guest





PostPosted: Tue Oct 14, 2014 1:26 am    Post subject: [asterisk-users] asterisk stun setup , not using public ip r Reply with quote

Thanks for your reply......

I have  put  nat =force_rport,comedia in general section , but still not working .


On Tue, Oct 14, 2014 at 9:45 AM, Jeremy Kister <asterisk-03@jeremykister.com (asterisk-03@jeremykister.com)> wrote:
Quote:
On 10/13/2014 2:50 AM, chandapure shiva wrote:
Quote:
In above packet VIA and CONTACT SIP-HEADERS contains the asterisk server
private IP address which is behind the NAT , as per my understanding it
supposed to be the public ip address of my network.

do you also have the appropriate nat statement in sip.conf ?

since you have the 'stun show status' command, i beleive the correct nat statement is nat=force_rport,comedia in the general section.

--

Jeremy Kister
http://jeremy.kister.net./


--
_____________________________________________________________________
-- 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
asterisk-03 at jeremyk...
Guest





PostPosted: Tue Oct 14, 2014 1:29 am    Post subject: [asterisk-users] asterisk stun setup , not using public ip r Reply with quote

On 10/14/2014 2:25 AM, chandapure shiva wrote:
Quote:
I have put nat =force_rport,comedia in general section , but still not
working .

I hate to ask, but did you reload sip afterwards? asterisk -rx 'sip reload'

--

Jeremy Kister
http://jeremy.kister.net./



--
_____________________________________________________________________
-- 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
chandapure.shivu89 at ...
Guest





PostPosted: Tue Oct 14, 2014 1:42 am    Post subject: [asterisk-users] asterisk stun setup , not using public ip r Reply with quote

yes i did sip reload, then checked the sip packects.


but problem exists.


On Tue, Oct 14, 2014 at 11:59 AM, Jeremy Kister <asterisk-03@jeremykister.com (asterisk-03@jeremykister.com)> wrote:
Quote:
On 10/14/2014 2:25 AM, chandapure shiva wrote:
Quote:
I have  put  nat =force_rport,comedia in general section , but still not
working .

I hate to ask, but did you reload sip afterwards?  asterisk -rx 'sip reload'

--

Jeremy Kister
http://jeremy.kister.net./



--
_____________________________________________________________________
-- 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
Display posts from previous:   
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> Asterisk Users All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
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

VoiceMeUp - Corporate & Wholesale VoIP Services