[asterisk-users] secret vs remotesecret on outgoing calls in Asterisk 1.6.2.16.1

Jose P. Espinal jpe at slackware-es.com
Wed Feb 23 09:31:04 CST 2011


Hello List,

I have a little issue with calls placed to a provider declared on 
sip.conf, because of a not clear (*for me*) behavior of 'remotesecret' 
parameter.

Before continuing, this is my environment:

Asterisk:  1.6.2.16.1
OS:        CentOS release 5.5 (Final)
            2.6.18-194.32.1.el5


Details:

I have this block on sip.conf

----- start ----
...
register => john:j0nhp4ss at 66.128.XX.XXX
...

[john-peer]
type=peer
defaultuser=john
remotesecret=j0nhp4ss
;secret=j0nhp4ss
host=66.128.XX.XXX
directmedia=no
dtmfmode=rfc2833
context=jonh-context

----- end ----


When I send a call to that block, I receive the following response 
unless (I explicitly indicate a 'secret' parameter, no matter if 
'remotesecret' parameter was indicated):

"Forbidden" from '"Test Account" <sip:9_XXX at 66.128.XX.XXX>;tag=as749a7ced'



If I set the 'secret' parameter, everything goes smoothly as expected.


Maybe I'm obviating something 'basic', but the CHANGES file says:

-----
Added a new configuration option "remotesecret" for authentication to
remote services. For backwards compatibility, "secret" still has the
same function as before, but now you can configure both a remote secret
and a local secret for mutual authentication.
-----

and on sip.conf.sample

-----
;remotesecret=guessit             ; Our password to their service
-----

I thought that 'remotesecret' is used to authenticate myself when 
placing a call to the remote network, as I used to do with 'secret' 
parameter.


Doing a: grep -ir 'remotesecret' . (inside the Asterisk source 
directory) indicates that only this files mention that parameter:

./ChangeLog
./channels/chan_sip.c
./CHANGES:
./configs/sip.conf.sample


Could someone please point me to documentation regarding this two 
parameters?


Thanks in advice.


-- 
Jose P. Espinal
http://www.eslackware.com
IRC: Khratos @ #asterisk / -doc / -bugs



More information about the asterisk-users mailing list