Asterisk 'fromuser' field ignored

nikmit
Joined: Thu 09 of Jun, 2011

Asterisk 'fromuser' field ignored

Posted:Thu 09 of Jun, 2011 (20:50 UTC)
Hello,

I have configured my Asterisk PBX to the point where local conversations run fine, and I have registered a trunk successfully.
Attempts to dial external numbers however fail and my provider said the reason is I am presenting my local extension in the 'From:' field rather than the DID assigned by them.


Debug output includes:
From: "User Name" <sip:1001@xx.xx.xx.xx>;tag=as4448824f  ======================> notice from user is 1001
To: <sip:somemobilenum@host.orbtalk.co.uk>
Contact: <sip:1001@xx.xx.xx.xx>
...
Responce from provider:
<--- SIP read from UDP:xy.xy.xy.xy:5060 --->
SIP/2.0 100 Giving a try...
Via: SIP/2.0/UDP xx.xx.xx.xx:5060;branch=z9hG4bK7c3a6ef8
From: "User Name" <sip:1001@xx.xx.xx.xx>;tag=as4448824f
To: <sip:somemobilenum@sipgw3.orbtalk.co.uk>
Call-ID: 22033f2a0c1108a04ef885fd3d7d2c03@86.24.150.213
CSeq: 102 INVITE
Server: OpenSIPS (1.6.3-notls (x86_64/linux))
Content-Length: 0

<--- SIP read from UDP:xy.xy.xy.xy:5060 --->
SIP/2.0 407 Proxy Authentication Required

My config is very simple at this point:

/etc/asterisk/extensions.conf :
[phones]
exten => 1001,1,Dial(SIP/1001,10)
exten => 1002,1,Dial(SIP/1002,10)
include => orbtalk

[orbtalk]
exten => _0.,1,Dial(SIP/${EXTEN}@host.orbtalk.co.uk,20,ftwTW)

/etc/asterisk/sip.conf :
register => 44xxxx:yyyy@host.orbtalk.co.uk/44xxxx

[1001]
type=friend
context=phones
host=dynamic
secret=****
dtmf=rfc2833

[orbtalk]
type=peer
fromdomain=orbtalk.co.uk
fromuser=44xxxx  ===================================> this is what should set 44xxxx in the from field instead of 1001
secret=yyyy
context=orbtalk
host=host.orbtalk.co.uk
insecure=invite
qualify=yes

debian*CLI> sip show peer orbtalk

  * Name       : orbtalk
  Secret       : <Set>
  MD5Secret    : <Not set>
  Remote Secret: <Not set>
  Context      : orbtalk
  Subscr.Cont. : <Not set>
  Language     :
  AMA flags    : Unknown
  Transfer mode: open
  CallingPres  : Presentation Allowed, Not Screened
  FromUser     : 44xxxx  ===========================> asterisk seems to read and accept that bit of the config, but doesn't implement it in the dial out attempts.
  FromDomain   : orbtalk.co.uk
  Callgroup    :
... ... ... output truncated


Any ideas will be greatly appreciated.

Nik