Asterisk as SIP client (ie softphone) to Cisco CUCM?


#1

Hi,

I would like to use Asterix to do voice recognition. Is that possible?
Also, can Asterix be connected to CUCM as a SIP client?

Basically what I’m trying to accomplish is to replace my Cisco IP Phone with a SIP client that can do voice recognition. I’d like to run Asterix from a linux server that could dial out over CUCM and also do voice recognition since it would be communicating with an IVR system. My application would send username and receive a token back from the IVR system.

Is any of this even possible or am I totally out in left field? I’m pretty new to this and am in exploratory mode at the moment.

Thank you


#2

Yes. It’s called IVR. You cam search IVR topics to learn how to implement it.

I’m a newbie on Asterisk myself, but IVR is mentioned in nearly every overview and intro article/video for Asterisk.


#3

IVR is not (normally) voice recognition. Asterisk can do voice recognition, but needs a third party recognition engine.

Asterisk can act as a SIP client to CUCM (originate CUCM calls) and as a a SIP server to CUCM (accept calls from CUCM). I’ve personally only done this with CUCM configured with Asterisk as a trunk, but I believe CUCM also supports SIP phones. SIP doesn’t really have distinct trunk and extension concepts.


#4

Hmmm. Okay, maybe my terminology is wrong. However, from this link it does appear to be an optional standard module, unless I’m reading it wrong?

https://wiki.asterisk.org/wiki/display/AST/Speech+Recognition+API


#5

connects through the API to speech recognition software, that is not included in the module


#6

I have sucessfully used https://cloud.google.com/speech-to-text/ with Asterisk, results are very decents


#7

Thanks for all your replies. It sounds like what I’m trying to do is possible from what I’ve read so far.

To clarify, I’m not trying to implement an IVR system, but rather trying to dial an IVR using Asterisk -> CUCM -> customer IVR. Once connected I want Asterisk to send a pre-defined set of DTMF digits and then receive/decode the speech responses from the IVR system.

Currently I do this manually using my Cisco desk phone, but what I’m trying to do is substitute my desk phone with Asterisk so I can automate the process. I’m not sure if it will require any modifications on CUCM (which is highly unlikely to happen since it involves IT), or if I can just configure Asterisk to “look” like a Cisco desk phone. I’ve been on it a couple of days and so far no luck. I have a PCAP of the SIP messages between my desk phone and CUCM, so I’m trying to massage Asterisk configuration files to match those SIP messages until it works. Probably not the best approach (ie trial and error) but I’m learning as I go.

Thanks again for all your inputs!

Dan


#8

Do you have the username and password your phone uses to communicate with CUCM?

If you don’t have the credentials it’s going to be very hard to make this work without involving your IT staff.


#9

Yes I have the user/pass I had to enter it on my Cisco phone when I set it up, since I also use those credentials to login to the Jabber phone.


#10

If you are using Jabber I would think they have configured their CUCM to allow SIP registration, I would use the exact same settings from Jabber in your pjsip settings.


#11

Yep…that’s what I’ve been trying to do. Since I’m a newbie with Asterisk, I’m having to do a lot of trial/error with the config files to get it to do what I want.


#12

I would suggest starting with this document https://wiki.asterisk.org/wiki/display/AST/PJSIP+Configuration+Wizard specifically the trunk between trusted peers section.

Since your PBX will not be called into by your CUCM you don’t need registration.


#13

I think he may be doing this behind the back of the manager of the CUCM. Whilst it would be best to treat this as a trunk, he might have no choice but to register as a dynamic extension, even to originate calls.

My only use of CUCM was with trusted peer trunks.


#14

John/David,

Thanks again for your help. I will read up on the document you provided. I’m at the point where I see SIP reg going out (do I even need that based one what John said? I don’t know yet), but there is data missing in the contact section that I’m trying to add by modifying the config. The registration has the Contact URI, but nothing else, and i suspect the authentication info CUCM needs is in the remaining part of the Contact info.

Here is what Jabber is sending in the SIP reg:

        Contact URI: sip:a25959fb-253b-a167-96ea-b67b75c77b15@10.19.46.18:60548;transport=tcp
            Contact URI User Part: a25959fb-253b-a167-96ea-b67b75c77b15
            Contact URI Host Part: 10.19.46.18
            Contact URI Host Port: 60548
            Contact URI parameter: transport=tcp
        Contact parameter: +sip.instance="<urn:uuid:00000000-0000-0000-0000-58ef68e5cecc>"
        Contact parameter: +u.sip!devicename.ccm.cisco.com="xxxxxxxxxxx"
        Contact parameter: +u.sip!model.ccm.cisco.com="503"
        Contact parameter: expires=0
        Contact parameter: cisco-keep-alive
        Contact parameter: video

And the reply I get from CUCM with my SIP reg (missing contact) is (blanked out my user@server):

<--- Received SIP response (502 bytes) from TCP:x.x.x.x.143:5060 --->
SIP/2.0 404 Not Found
Via: SIP/2.0/TCP 10.186.234.24:5060;rport;branch=z9hG4bKPj261ce833-700e-4590-865d- 
b03fbba02fc4;alias
From: <sip:user@server>;tag=ee31d7db-5055-478c-9009-39db92ee1292
To: <sip:+user@server>;tag=1453715631
Date: Sun, 06 Jan 2019 00:18:05 GMT
Call-ID: ada82469-593c-4efc-aa53-cad46fcda639
Server: Cisco-CUCM12.0
CSeq: 13849 REGISTER
Warning: 399 <sip server> "**Unable to find device/user in database**"
Content-Length: 0

The fact CUCM can’t find the device, and devicename.ccm.cisco.com=“xxxxxxxxxxx” is in the Jabber SIP reg leads me to believe the “contact parameters” are required fields. But I don’t know for sure.

Anyway, I’ll read up on John’s document to see if I can make any progress. Would really be cool to get this working as it would simplify my workflow a lot.

Thank you,
Dan


#15

Hmm, Sorry I didn’t realize that Cisco had ‘extended’ sip with extra headers that would be needed.

You may not be able to do what you want with asterisk without using something additional like kamalio or opensips to modify traffic between Asterisk and CUCUM.


#16

Thanks John. You probably saved me a lot of time chasing a white elephant. I’ll look into opensips/kamalio. Thx