file sip.conf:

     register => user[:secret[:[EMAIL PROTECTED]:port][/extension]

example: register => 5311111:[EMAIL PROTECTED]:5061/1234


file extensions.conf
     exten => extension,1,1,Dial(number)
     exten => extension,1,2,HangUp

   example:

     exten => 1234,1,1,Dial(SIP/1)
     exten => 1234,1,2,HangUp


to call

 file sip.conf:

   [**NAME**]
   type=peer
   secret=**PSW**
   username=**USER**
   port=**PORT**
   host=**HOST**
   fromuser=**USER**
   fromdomain=**DOMAIN**
   nat=yes

   * ESEMPIO:

   [messagenet-out]
   type=peer
   secret=pwd
   username=nmb
   port=5061
   host=sip.messagenet.it
   fromuser=nmb
   fromdomain=sip.messagenet.it
   nat=yes

 file extensions.conf

exten => extension,1,Dial(number,30,r)
   * ESEMPIO:

exten => _9.,1,Dial(SIP/${EXTEN:[EMAIL PROTECTED],30,r)



[EMAIL PROTECTED] wrote:
Hi,

to register my Asterisk with a SIP provider I use the following syntax, as shown in the default sip.conf:

register => 2345:[EMAIL PROTECTED]

where

[sip_proxy]
type=peer
context=from-messagenet
host=sip.messagenet.it
port=5061 <------------- please note this one!!!

5061 is provider's port I have to register to.
This also would work for me:

register => 2345:[EMAIL PROTECTED]:5061

but I need the other syntax 'cause I *have* to specify a different context for incoming calls rather than the default one in sip.conf.

Well, "sip show registry" shows:
Host                  Username  Refresh State
sip_proxy:5060 *******               105 Registered
------------^^^^

As you can see, Asterisk didn't care about port value 5061.

However, "sip show peer sip_proxy" shows:
ToHost : sip.messagenet.it
Addr->IP : 212.97.59.76 Port 5061
-------------------------------------^^^^

What is wrong, please?
Should I report this behaviour as a bug? Maybe a feature request?

Cheers,
Alex



                
Tiscali ADSL 4 Mega Flat
Naviga senza limiti con l'unica Adsl a 4 Mega di velocità a soli 19,95 € al 
mese!
Attivala subito e hai GRATIS 2 MESI e l'ATTIVAZIONE. http://abbonati.tiscali.it/banner/middlepagetracking.html%3Fc%3Dwebmailadsl%26a%3Dwebmail%26z%3Dwebmail%26t%3D14%26r%3Dhttp%3A//abbonati.tiscali.it/adsl/sa/4flat_tc/
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to