02-19-2018 08:39 AM - edited 03-17-2019 12:14 PM
Hi ALL - I have a customer that wishes to block calls based on certain CNAM(Caller-id) strings. I have a LUA script that does this but unfortunately on the cusomer CUBE, they are sending some calls to CUCM and have other dial-peers sending calls directly to CVP so I need to explore other options. I was able to create a SIP profile that changes the calling number to 7654321when the call hits the incoming peer.
request INVITE sip-header Remote-Party-ID modify "\"CNAMstring\"(.*)<sip:(.*)@(.*)>" "\1<sip:7654321\u01@\3>"
Now the tricky part is that at this point the call is in the middle of the CUBE and needs to match an outbound dial-peer towards CUCM that will block the call and for outgoing peers on CUBE I can only match on destination. I attempted using a translation rule on the outbound peer:
voice translation-profile call_block
translate calling 5
but since this is an outgoing dial-peer, it does not work, since this mechanism is looking for an inbound call. I also checked into using a cor list which would probably work but I'm trying to keep this as simple as possible.
The other method to do this would be to reconfigure call routing to route all calls to CUCM and use the LUA script. Just wanted to check with the community if there is a better way of doing this at the CUBE. Any feedback is appreciated.
02-19-2018 07:50 PM
02-19-2018 08:02 PM
theoretically, if you can change the CNAM string, you can manipulate the called number into , lets say "97654321" right? if you can achieve that you can match it on an outbound dial peer using destination pattern "97654321" and block it on cucm.
02-20-2018 08:06 AM
02-20-2018 09:34 AM
Hi ALl thanks for the responses.
Since the call already arrived at the CUBE and I need to block it from sending the outbound leg , I can't block incoming - I surely would not be posting here if it were that simple.
I ended up putting a tcl script on the inbound dial-peer that rejects the call for specified CNAM string.
ugly, yes
kludgy, yes
02-20-2018 09:46 AM - edited 02-20-2018 09:46 AM
.
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: