From: Scott Morris (swm@emanon.com)
Date: Mon Jul 12 2004 - 13:51:33 GMT-3
The [] are reserved for single characters only, so all you are doing there
is saying that this one charcter can be a 0 or a 0 or a 1 or a 1 or a 1 or a
1 or a 1 or a 1 or a 1. :) And the router is going, "buh dee, buh dee, buh
dee, that's all folks" ;)
It seems we have had this problem before where it depends on the level of
code you happen to be running to whether all of the reg-exp functionality is
included. The () are used for string matches. The the | is used inside
there to denote OR.
On my router, I can pull it off, although some people have been unable to
duplicate the identical commands. *shrug*
dial-peer voice 500 voip
destination-pattern 12345(00|11)11
session target ipv4:1.1.1.1
!
BRI-VoIP#sh dialplan number 123450011
Macro Exp.: 123450011
VoiceOverIpPeer500
information type = voice,
description = `',
tag = 500, destination-pattern = `12345(00|11)11',
answer-address = `', preference=0,
numbering Type = `unknown'
group = 500, Admin state is up, Operation state is up,
incoming called-number = `', connections/maximum = 0/unlimited,
DTMF Relay = disabled,
modem passthrough = system,
huntstop = disabled,
in bound application associated: 'DEFAULT'
out bound application associated: ''
permission :both
incoming COR list:maximum capability
outgoing COR list:minimum requirement
type = voip, session-target = `ipv4:1.1.1.1',
technology prefix:
settle-call = disabled
ip media DSCP = default, ip signaling DSCP = default, UDP checksum =
disabled,
session-protocol = cisco, session-transport = udp, req-qos =
best-effort,
acc-qos = best-effort,
fax rate = voice, payload size = 20 bytes
fax protocol = system
fax NSF = 0xAD0051 (default)
codec = g729r8, payload size = 20 bytes,
Expect factor = 0, Icpif = 20,
Playout Mode is set to default,
Initial 60 ms, Max 300 ms
Playout-delay Minimum mode is set to default, value 40 ms
Expect factor = 0,
Max Redirects = 1, Icpif = 20,signaling-type = cas,
CLID Restrict = disabled
VAD = enabled, Poor QOV Trap = disabled,
voice class perm tag = `'
Connect Time = 0, Charged Units = 0,
Successful Calls = 0, Failed Calls = 0, Incomplete Calls = 0
Accepted Calls = 0, Refused Calls = 0,
Last Disconnect Cause is "",
Last Disconnect Text is "",
Last Setup Time = 0.
Matched: 123450011 Digits: 7
Target: ipv4:1.1.1.1
BRI-VoIP#sh dialplan number 123451111
Macro Exp.: 123451111
VoiceOverIpPeer500
information type = voice,
description = `',
tag = 500, destination-pattern = `12345(00|11)11',
answer-address = `', preference=0,
numbering Type = `unknown'
group = 500, Admin state is up, Operation state is up,
incoming called-number = `', connections/maximum = 0/unlimited,
DTMF Relay = disabled,
modem passthrough = system,
huntstop = disabled,
in bound application associated: 'DEFAULT'
out bound application associated: ''
permission :both
incoming COR list:maximum capability
outgoing COR list:minimum requirement
type = voip, session-target = `ipv4:1.1.1.1',
technology prefix:
settle-call = disabled
ip media DSCP = default, ip signaling DSCP = default, UDP checksum =
disabled,
session-protocol = cisco, session-transport = udp, req-qos =
best-effort,
acc-qos = best-effort,
fax rate = voice, payload size = 20 bytes
fax protocol = system
fax NSF = 0xAD0051 (default)
codec = g729r8, payload size = 20 bytes,
Expect factor = 0, Icpif = 20,
Playout Mode is set to default,
Initial 60 ms, Max 300 ms
Playout-delay Minimum mode is set to default, value 40 ms
Expect factor = 0,
Max Redirects = 1, Icpif = 20,signaling-type = cas,
CLID Restrict = disabled
VAD = enabled, Poor QOV Trap = disabled,
voice class perm tag = `'
Connect Time = 0, Charged Units = 0,
Successful Calls = 0, Failed Calls = 0, Incomplete Calls = 0
Accepted Calls = 0, Refused Calls = 0,
Last Disconnect Cause is "",
Last Disconnect Text is "",
Last Setup Time = 0.
Matched: 123451111 Digits: 7
Target: ipv4:1.1.1.1
BRI-VoIP#sh dialplan number 123451011
Macro Exp.: 123451011
No match, result=1
BRI-VoIP#sh dialplan number 123450111
Macro Exp.: 123450111
No match, result=1
BRI-VoIP#
Scott Morris, CCIE4 (R&S/ISP-Dial/Security/Service Provider) #4713, CISSP,
JNCIP, et al.
IPExpert CCIE Program Manager
IPExpert Sr. Technical Instructor
swm@emanon.com/smorris@ipexpert.net
http://www.ipexpert.net
-----Original Message-----
From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of Tom
Rogers
Sent: Sunday, July 11, 2004 11:36 AM
To: Mike Calhoon; 'Geert Nijs'; ccielab@groupstudy.com
Subject: RE: Destination Pattern
How about 12345[0011,1111]
Mike Calhoon <mcalhoon27@earthlink.net> wrote:Hi Geert,
I think you are looking for 12345[00,11]11, but someone please correct me if
I am mistaken.
Thanks,
Mike
-----Original Message-----
From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of
Geert Nijs
Sent: Sunday, July 11, 2004 10:52 AM
To: ccielab@groupstudy.com
Subject: Destination Pattern
Hello group,
I am looking to match the following telephone numbers in ONE "destination
pattern" match:
123451111
123450011
(if possible at all, don't know....)
I was thinking about: destination-pattern 12345[01][01]11
but this also matches: 123450111 and 123451011
I was also thinking about: destination-pattern 12345[(00)(11)]11
but this doesn't work...
Any other ideas ??
Regards,
Geert
############################################################################
#########
This e-mail and any attached files are confidential and may be legally
privileged.
If you are not the addressee, any disclosure, reproduction, copying,
distribution, or other dissemination or use of this communication is
strictly prohibited.
If you have received this transmission in error please notify Simac
immediately and then delete this e-mail.
Simac has taken all reasonable precautions to avoid virusses in this email.
Simac does not accept liability for damage by virusses, for the correct and
complete transmission of the information, nor for any delay or interruption
of the transmission, nor for damages arising from the use of or reliance on
the information.
All e-mail messages addressed to, received or sent by Simac or Simac
employees are deemed to be professional in nature. Accordingly, the sender
or recipient of these messages agrees that they may be read by other Simac
employees than the official recipient or sender in order to ensure the
continuity of work-related activities and allow supervision thereof.
############################################################################
#########
This archive was generated by hypermail 2.1.4 : Sun Aug 01 2004 - 10:11:53 GMT-3