Gateway routing table examples
Stripping unwanted leading digits in both directions
In this example, unwanted leading digits are stripped from numbers in both
directions. You may occasionally need to strip digits from a number; for example, the
trunk prefix, area code, and country code. Only the last seven digits are passed from
PSTN to SIP or from SIP to PSTN.
ID
To incoming
1
tel:\d*(\d{7})$
2
sip:\d*(\d{7})@.*
The following rules are used in this example:
Rule
Description
1
Matches any PSTN calling/called numbers containing at least seven digits, captures only the last
seven digits to insert into SIP From/To headers.
2
Matches From/To URI containing at least seven digits before @, captures only the last seven
digits to insert into PSTN calling/called numbers.
Sample Input/Output: Incoming PSTN call (rule 1 match)
Calling: tel:18479258900 => sip:9258900@gateway
Called: tel:5082711000 => sip:2711000@hostname.com
Sample Input/Output: Incoming SIP call (rule 2 match)
From: sip:18479258900@10.3.6.9 => tel:9258900
To: sip:5082711000@10.3.6.1 => tel:2711000
76
Dialogic® Vision™ CX Video Gateway Administration Manual
From incoming
Mode
tel:\d*(\d{7})$
Route
sip:\d*(\d{7})@.*
Route
To outgoing
sip:$1@hostname.com
tel:$1
From outgoing
sip:$1@gateway
tel:$1
Dialogic
Need help?
Do you have a question about the Vision CX Video and is the answer not in the manual?