[asterisk-users] GotoIf Dialplan inquiry

Steve Finkelstein sf at stevefink.net
Tue Jun 12 12:40:55 CDT 2007


Hi all,

I have the following in my extensions.conf:

exten => s,4,GotoIf($["${CALLERID(number)}" = "8585979857" |
"8585970327"]?15:5)

The numbers listed above are known spammer numbers. However, when I call
from any other CALLERID, it still directs me to s,15 which is the
Hangup() application. Here are logs from the asterisk CLI:

    -- Executing [8995 at fromlime:1] Macro("IAX2/lime-3",
"forward|SIP/8995&SIP/31337|15|8995|IAX2/limemed at lime/13476681546") in
new stack
    -- Executing [s at macro-forward:1] Zapateller("IAX2/lime-3",
"answer|nocallerid") in new stack
    -- Executing [s at macro-forward:2] PrivacyManager("IAX2/lime-3", "")
in new stack
    -- CallerID Present: Skipping
    -- Executing [s at macro-forward:3] Wait("IAX2/lime-3", "1") in new stack
    -- Executing [s at macro-forward:4] GotoIf("IAX2/lime-3",
"("8585970327")?15:5") in new stack
    -- Goto (macro-forward,s,15)
    -- Executing [s at macro-forward:15] Hangup("IAX2/lime-3", "") in new stack
  == Spawn extension (macro-forward, s, 15) exited non-zero on
'IAX2/lime-3' in macro 'forward'
  == Spawn extension (macro-forward, s, 15) exited non-zero on 'IAX2/lime-3'
    -- Hungup 'IAX2/lime-3'


Thank you for any assistance.

- sf


More information about the asterisk-users mailing list