10-16-2003 04:49 AM - edited 03-13-2019 02:05 AM
Can I block numbers using the number of digits?.
For example, can I block numbers who have 6 digits?
10-16-2003 05:17 AM
you can use route patterns to block numbers
10-16-2003 05:21 AM
Hi,
If you had dial-peers with explicit matches you could do this it Could be a lenghty process configuring a the dial-plan with your requirement.
Definetly needs thought.
Some ideas..
Forward digits command on dial-peer could be of some benifet for example
forward-digits 7 & destination patern 99..... this would match anything with 7 digits or mor startingi with 99.
This would help to reduce the number of dialpeers required.
Another thought..
I like this method I havnt tried it though.
You could also try useing the num-exp to tranform the number to something that would be null i.e. match nothing this should work.
An example a 6 digit number hits the H.323 GW gets transformed to 333522222 and wont match a dial-peer
so the call will fail.
num-exp 5..... 333......
Because the 6 digit numbers wouldnt match anything..
If you have CM its a different story you could just not route 9.XXXXXX explicit match !!
Block this pattern.
You could also use CoR on the h.323gw this is pretty cool.Though every dial-peer needs configuration otherwise the call is allowed.
Let us if you want to block all 6digit numbers or perkhaps only ones start with 5
If you want to know more let us know.
It really depends on your HW/SW as to what you can and cant achieve.
Let us know how you get on.
Give it a try
Allan
10-16-2003 08:36 AM
Hi Allan
Your trick of using the longest match rule seems fine. But sometimes I realised that IOS does not respect longest match rule and I rather prefer not to use longest match rule for dialpeer routing (always explicit rules).
What I need is to permit only 7 digits numbers and to block anything else.
Alex
10-16-2003 12:25 PM
Hi Alex,
Try this dial-peer voice 35 pots
destination-pattern 9[1-9]......
port whichever one your sending to.
This will strip the first 9 then match any digit between 1-9 + six other digits ......
Give this a go I' not sure if longer numbers match I would think not
But I cant test this at the moment for you to clarify.
I would expect the behaviour to be a match on 7 digits only but longer matches may go through too.
Let me get back to you.
Allan
10-16-2003 04:44 PM
9[1-9].....#
10-16-2003 10:41 PM
Hi Alex,
sorry about that last post ..
I tested this scenario and this is what was successfull 9[1-9].......$
I tested/dialed any number longer than 8 digits or shorter failed.
Dial-peer voice 44 pots
destination-pattern 9[1-9].......$
port 1/0/0
Allan
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide