cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1898
Views
15
Helpful
5
Replies

Inbound Dial Peer Matching

s-baldwin
Level 1
Level 1

We have a Cisco 4451 IOS router running CUBE software. Currently we have two inbound dial peers for inbound called numbers. The first one uses URI host matching to match the DNS name from the ISP. The second one uses the user-id to match the incoming called number so that we can reroute hard faxes. I want to add another inbound dial peer to match a specific calling number using the user-id of the SIP message.

This is the current inbound dial peer configs:

dial-peer voice 5000 voip

 description Incoming from Verizon

 session protocol sipv2

 session transport udp

 destination dpg 7000

 incoming uri to VZDNS

 voice-class codec 1

 voice-class sip copy-list 1

 voice-class sip bind control source-interface GigabitEthernet0/0/2

 voice-class sip bind media source-interface GigabitEthernet0/0/2

 dtmf-relay rtp-nte sip-kpml sip-notify

 no vad

 detect-fax mode local 5551212

 

As you can see we have configured an incoming URI to match the ISP's DNS information in the To header which I have included below:

voice class uri VZDNS sip

 host dns:disaarnoldhub.globalipcom.com

 host dns:ngancehub.disa.globalipcom.com

 host dns:ngastlhub.disa.globalipcom.com

 

The is the current inbound dial peer used to detect our hard fax inbound calls:

 

dial-peer voice 5001 voip

 description Incoming from Verizon for FAX

 session protocol sipv2

 session transport udp

 destination dpg 7000

 incoming uri to HardFaxDN

 voice-class sip bind control source-interface GigabitEthernet0/0/2

 voice-class sip bind media source-interface GigabitEthernet0/0/2

 dtmf-relay rtp-nte sip-kpml sip-notify

 codec g711ulaw

 fax-relay ecm disable

 fax rate 14400

 fax protocol t38 version 0 ls-redundancy 0 hs-redundancy 0 fallback pass-through g711ulaw

 no vad

 

As you can see we have configured an incoming URI to match the user-id information in the To header which I have included below:

voice class uri HardFaxDN sip
user-id 6363212345

 

Here is the dial peer that I added to match a specific calling number using the user-id of the SIP message:

dial-peer voice 5002 voip

 description Incoming from Verizon for Nuisance Call

 translation-profile incoming CUCM_for_Nuisance

 session protocol sipv2

 session transport udp

 destination dpg 7000

 incoming uri from NuisanceCalls

 voice-class sip bind media source-interface GigabitEthernet0/0/2

 dtmf-relay rtp-nte sip-kpml sip-notify

 codec g711ulaw

 fax-relay ecm disable

 fax rate 14400

 fax protocol t38 version 0 ls-redundancy 0 hs-redundancy 0 fallback pass-through g711ulaw

 no vad

 

Here is the voice class uri to match the user-id information in the From header which I have included below

voice class uri NuisanceCalls sip

 user-id 3142564320

 

I have also changed the preference order for the uri hunting with the following command:

voice class uri sip preference user-id host

 

The problem that I am having is that when the call comes in, the router looks for a matching inbound dial peer and always chooses DP 5000 because it is looking at the To header before it looks at the From header. My understanding is that DP matching will look at the To header first and if it matches it will quit hunting. Is there a way to change that?

2 Accepted Solutions

Accepted Solutions

b.winter
VIP
VIP

Since the priority is hard-coded, where the To header matches before the From header, there is no chance to change that.

The only thing you can do is to change your dial-peer matching.

 

The following is the order in which inbound dial-peer is matched for SIP call-legs:

  • voice class uri URI-class-identifier with incoming uri {via} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {request} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {to} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {from} URI-class-identifier

  • incoming called-number DNIS-string

  • answer-address ANI-string

View solution in original post

The order for dial-peer matching is set in IOS and can from what I know not be altered. This document explains in dept how call routing works in IOS and IOS-XE.

This table is from this document and outlines the order of operation for inbound SIP calls.
image.png



Response Signature


View solution in original post

5 Replies 5

b.winter
VIP
VIP

Since the priority is hard-coded, where the To header matches before the From header, there is no chance to change that.

The only thing you can do is to change your dial-peer matching.

 

The following is the order in which inbound dial-peer is matched for SIP call-legs:

  • voice class uri URI-class-identifier with incoming uri {via} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {request} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {to} URI-class-identifier

  • voice class uri URI-class-identifier with incoming uri {from} URI-class-identifier

  • incoming called-number DNIS-string

  • answer-address ANI-string

The order for dial-peer matching is set in IOS and can from what I know not be altered. This document explains in dept how call routing works in IOS and IOS-XE.

This table is from this document and outlines the order of operation for inbound SIP calls.
image.png



Response Signature


s-baldwin
Level 1
Level 1

Thank you for your responses. I have read that in depth document, which provided me enough info to be dangerous :). Your posts have confirmed what I expected. It looks like I will need to find a new approach to solving this problem. Thanks again.

lhillu
Level 1
Level 1

I had a similar challenge, and after stumbling around for a while found the following command:

voice class uri sip preference user-id host

This will change the preference for matching so it looks at the user-id (configured as your desired phone number) first; after that if no match it will then look at host matches.

I had to change slightly how I was matching calls coming in to my CUBE - as you are still bound by the same match order as referenced above (via, request to, from).  You have both dial-peers using uri "to", so this should be exactly what you need....   the preference command change will let you match on user-id first, then host to catch all else that didn't match user-id.

Do some reading, do some testing, but it worked out exactly like I needed it to, so I could match on specific numbers while still using the host match to catch all other traffic. 

You might have missed that the OP already has that option in the original post.

“I have also changed the preference order for the uri hunting with the following command:

voice class uri sip preference user-id host”



Response Signature