* You are viewing Posts Tagged ‘callerid’

Google Talk Under Asterisk 11.0.1

I followed https://wiki.asterisk.org/wiki/display/AST/Calling+using+Googleto get incoming and outgoing using Google Voice working.

However, when calling from google talk client, I see strange behaviour
(describe below):

Here is my configuration:

motif.conf
============
[google]
context=in-google disallow=all allow=alaw allow=ulaw allow=h264
connection=google


xmpp.conf
================
[google]
type=client serverhost=talk.google.com username=mygmail@gmail.com secret=mypassword priority=1
portR22
usetls=yes usesasl=yes status=available statusmessage=”Asterisk”
timeout=5


ael dial plan
====================
context in-google
{
s =>
{
Wait(1);
Set(crazygooglecid=${CALLERID(name)});
Set(stripcrazysuffix=${CUT(crazygooglecid,@,1)});
Set(CALLERID(all)=${stripcrazysuffix});
Answer();
SendDTMF(1);
//Voicemail(${DEF_MAILBOX}@default,su);
goto in-various|ringphones|1;
hangup();
}
}


Given the above context, when someone called, it stucked at the Wait(1)
forever.
— Executing [s@in-google:1] Wait(“Motif/wk-f2e2″, “1″) in new stack

If I replaced the Wait and SendDTMF above with Dial() my local sip phone, the call is disconnected and I see the following error message.

WARNING[6789][C-0000000f]: channel.c:1304 __ast_queue_frame: Exceptionally long queue length queuing to Motif/wk-e8e6


When calling the Google Voice number, it works fine. Any thought? Thanks.

If Would Possible Use A Custom Function In Asterisk Dialplan

Hello,

If would be possible to use a “function concept” in side of Asterisk DialPlan

For example:

I have following logic in my dial plan remove country code a add an “0″ before the rest of the numbers


exten => _X.,1, NoOp( call ID ${CALLERID(num)} exten: ${EXTEN}))
; remove my country code exten => _X.,n, GotoIf($["${CALLERID(num):0:4}"="${country-code}"]?international-format:national-format)
exten => _X.,n(international-format), Set(CALLERID(num)=0${CALLERID(num):4})
exten => _X.,n(national-format), NoOp(call ID: ${CALLERID(num)} exten: ${EXTEN}))

Do you think if would be possible that I could write a function something like “REMOVEMYCOUNTRYCODE(${NUM})” with a return value of a number with out country code and with an “0″ add in front of the rest of the numbers.

like

exten => _X.,1, NoOp( call ID ${CALLERID(num)} exten: ${EXTEN}))
; remove my county code exten => _X.n, Set(CALLERID(num=REMOVEMYCOUNTRYCODE(${CALLERID(num)} ));

then I have to define this function in someway

TON Always Unknown In RDNIS (outgoing Calls)

Hello,

first of all, this is my first time asking for advice on this mailing list, so I apologize and thank in advance for your help. Also, besides having access to rather advanced equipment, maybe some of the terms I will use will be incorrect or ambiguous. I hope to be able to clarify any doubt you should have about it.

I am currently in the process of upgrading a SIP/TDM gateway from Asterisk
1.4.23 to 1.8.17. The gateway is designed to terminate SIP calls via TDM
through a switching equipment. Among the features for this gateway there is handling for redirected calls, i.e. populating the outgoing RDNIS with information from custom SIP headers.

In the past, (Asterisk 1.4.23, DAHDI 2.6.1, libPRI 1.4.12) this was accomplished by setting CALLERID(RDNIS) and PRIREDIRECTREASON in the dialplan. Tracing on the switching equipment, I noticed that the REDIRECTING party had:
– TON as set in DAHDI’s prilocaldialplan
– NPI ISDN
– Presentation indicator always “allowed”
– Reason as set in PRIREDIRECTREASON
– Redirecting Party Number as set in CALLERID(RDNIS)

In the new setup (Asterisk 1.8.17, DAHDI 2.6.1, libPRI 1.4.12) I am instead using:
– REDIRECTING(from-num) to set the redirecting party number
– REDIRECTING(from-num-plan) to set the NPI (to numeric value 1 – ISDN),
because by default it was set to 0 – unknown
– REDIRECTING(from-num-pres) to set the Presentation Indicator
– REDIRECTING(reason) to set the redirecting reason

Everything seems fine, and using the new REDIRECTING function I have also gained control on the Presentation Indicator (which was previously fixed), but the RDNIS seems always to have TON unknown (instead of what specified in prilocaldialplan – international). Is there a specific way to manually set the TON as I did with the NPI, or is there some known issue with this mechanism?

Thanks again in advance for your help.

Gianluca

Digium D40 Phones And Caller ID

First post to this mailing list. I’ll keep it brief: My D40 phones don’t show the “name” component of CALLERID. It only displays the number. This includes calls originating from PSTN
with their own CID already set, and calls where we’ve specifically filled in this data. Changing the destination of my test extension to a softphone (zoiper in this case) correctly displays the information. sip.conf already contains sendrpid=pai.

From what I can tell, this appears to be a Digium phone limitation. Or am I missing something crucial?

Regarding Caller ID And Security

Hi all,

I am new to Asterisk, and would like to begin by saying that it is an absolutely fantastic system. Seems incredibly stable, well tested, and easy to use.

Now, to my question. I am making a mix between a personal ads and a voicemail service, where I want each user to be able to submit an ad that others can respond to by recording messages that go into this users inbox. My original thought was to base this purely on the CALLERID(num) value, but quickly discovered that this is a bit unreliable. Sometimes when I would call in it’d say anonymous, other times it would give me a bunch of zero’s, other times it would show me my real phone number, and once it actually gave me just random digits. I do have a wait call after answering but before my first soundf ile is triggered, in my pickup context. I am wondering what the best way to approach this is? Do I ask the user to enter their phone number, and then generate a code based upon this that will then serve as a password when you call back? Do I attempt to use CALLERID(num) to detect returning users, or is this not adviseable from a security perspective?

Preferably, I would like to avoid using a code altogether but I am told that it is relatively easy to spoof phone numbers to hack into someone else’s inbox. Note that I do not plan to allow direct SIP calls, only through a PSTN/SIP provider where the IP address is on a whitelist. Any tips on how to approach this would be highly appreciated. Basically I want to make it as easy as possible for my users, but maintain high security.

Thanks in advance for any help, and thanks once again to the developers of Asterisk for making such an excellent tool!

Kind regards,

Philip Bennefall

P.S. I also wanted to know whether there is a function to check if a string contains only digits? This would be useful as a sanity check before I look up the phone number in the MySql database, if I do decide to use CALLERID(num) in this way.