[asterisk-users] [sip] setvar not executed when call comes in via registry

martin f krafft madduck at madduck.net
Wed Sep 2 07:16:12 CDT 2015


Hi,

I have a line like

  register => 1yyyyyyy1:xxxxxxxxxxxx at sipconnect.sipgate.de/incoming

in sip.conf, and a corresponding stanza (note especially the final
setvar):

  [trunk-sipgate]
  type=peer
  qualify=yes
  insecure=invite
  language=de
  dtmfmode=rfc2833
  host=sipconnect.sipgate.de
  fromdomain=sipconnect.sipgate.de
  fromuser=1yyyyyyy1
  defaultuser=1yyyyyyy1
  secret=xxxxxxxxxxxx
  context=in-trunk-sipgate
  session-timers=accept
  allow=!all,alaw,ulaw,g726
  setvar=FOO=BAR

If I 'sip show peer trunk-sipgate', the variable FOO is there.

I also have a stanza for my local SIP phone, e.g.

  [0020fe8200de]
  ; abbreviated
  md5secret=abcdabcdabcdabcadbcdabcadbcdabcd
  context=in-martin
  setvar=DEFAULT_ORIGIN=11

When I make a call with this phone, the dialplan has access to
${DEFAULT_ORIGIN}.

However, when a call comes in through the sipgate trunk and gets
routed to the in-trunk-sipgate context, the ${FOO} variable is not
set and thus not available from the dialplan.

Am I doing something wrong (* v11.13 on Debian)

Thanks,

-- 
@martinkrafft | http://madduck.net/ | http://two.sentenc.es/
 
chaos reigns within.
reflect, repent, reboot.
order shall return.
 
spamtraps: madduck.bogus at madduck.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: digital_signature_gpg.asc
Type: application/pgp-signature
Size: 1107 bytes
Desc: Digital signature (see http://martin-krafft.net/gpg/sig-policy/999bbcc4/current)
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20150902/bdbdfe1a/attachment.pgp>


More information about the asterisk-users mailing list