[Asterisk-Users] Call ID WinPopup working one-line example without scratch file

Thomas Hutton pres at nicheware.com
Wed Nov 17 21:23:52 MST 2004


Here's a tested example that works without any scratch file.  I still
had to use a combination of single and double quote characters, as well
as a double backslash for the \n newline command.

; Extension 200 Call ID Popup Example
exten => 200,1,NoOp(${CALLERID} ${DATETIME})
exten => 200,2,System(/bin/echo -e "'Incoming Call From: ${CALLERID} \\r
Received: ${DATETIME}'"|/usr/bin/smbclient -M target_netbiosname)
exten => 200,3,Dial,sip/tom|30|t        ; Ring, 30 secs max
exten => 200,4,Congestion

Note: line two wrapped - it needs to be all on one line.
Thanks to Duane and Adam for the ideas.  

It still does nothing to prevent somebody from slipping bad code into
their Call ID string, but as I'm running a private system and only
taking Call ID's directly off the PSTN on a single low volume zap
channel, or assigning them myself at this point.  I'm not too worried
someone is going to put in something like ''""bad command""'' in their
string.  It would be nice to know if there is a check someplace up the
food chain in the application to qualify valid Call ID's- or if that's
something possible?

By the way, I'm sorry to start a new thread all the time here but I
can't respond to links from my firefox browser with evolution. (probably
an even greater sin than top posting)

Thomas Hutton




More information about the asterisk-users mailing list