<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
h4
        {mso-style-priority:9;
        mso-style-link:"Heading 4 Char";
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
code
        {mso-style-priority:99;
        font-family:"Courier New";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.Heading4Char
        {mso-style-name:"Heading 4 Char";
        mso-style-priority:9;
        mso-style-link:"Heading 4";
        font-family:"Calibri Light",sans-serif;
        color:#2F5496;
        font-style:italic;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
p.title, li.title, div.title
        {mso-style-name:title;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
p.berschrift4, li.berschrift4, div.berschrift4
        {mso-style-name:"Überschrift 4";
        mso-style-link:"Überschrift 4 Zchn";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.berschrift4Zchn
        {mso-style-name:"Überschrift 4 Zchn";
        mso-style-priority:9;
        mso-style-link:"Überschrift 4";
        font-weight:bold;}
span.EmailStyle24
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.EmailStyle25
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
span.EmailStyle26
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.EmailStyle27
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
span.EmailStyle29
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:1431971149;
        mso-list-type:hybrid;
        mso-list-template-ids:-2119118342 67698705 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
@list l0:level1
        {mso-level-text:"%1\)";
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level2
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level3
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l0:level4
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level5
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level6
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
@list l0:level7
        {mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level8
        {mso-level-number-format:alpha-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;}
@list l0:level9
        {mso-level-number-format:roman-lower;
        mso-level-tab-stop:none;
        mso-level-number-position:right;
        text-indent:-9.0pt;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Hi Matthias,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Will try it and will inform you later.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Best Regards,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Syaiful<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b>From:</b> Hohl Matthias <matthias.hohl@telematica.at> <br>
<b>Sent:</b> Thursday, March 8, 2018 7:32 PM<br>
<b>To:</b> 'Syaiful Bahri Kamaruddin' <chefsyaiful@outlook.com>; spce-user@lists.sipwise.com<br>
<b>Subject:</b> AW: [Spce-user] NEED HELP On Rewrite Rules<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="color:#1F497D">Btw don’t forget about the outbound numbers too… if you didn’t use there rewrite rules, it will display just the E.164 number (6012345566) on your phone if you recieve a call from SPCE<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span lang="DE">Von:</span></b><span lang="DE"> Spce-user [<a href="mailto:spce-user-bounces@lists.sipwise.com">mailto:spce-user-bounces@lists.sipwise.com</a>]
<b>Im Auftrag von </b>Hohl Matthias<br>
<b>Gesendet:</b> Donnerstag, 8. März 2018 12:29<br>
<b>An:</b> 'Syaiful Bahri Kamaruddin' <<a href="mailto:chefsyaiful@outlook.com">chefsyaiful@outlook.com</a>>;
<a href="mailto:spce-user@lists.sipwise.com">spce-user@lists.sipwise.com</a><br>
<b>Betreff:</b> Re: [Spce-user] NEED HELP On Rewrite Rules<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="DE-AT"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="DE-AT" style="color:#1F497D">Hello,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="DE-AT" style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">firstly, just read this: <a href="https://www.sipwise.org/doc/mr5.5.3/spce/ar01s06.html#dialplans">
https://www.sipwise.org/doc/mr5.5.3/spce/ar01s06.html#dialplans</a><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">If you just want to manipulate the INBOUND numbers, from a subscriber to SPCE you need the Inbound Rules for the subscriber.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">If you want to manipulate the OUTBOUND numbers, from the SPCE to a subscribe you need the Outbound Rules for the subscriber.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">What you need is: <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Strip leading 00 or +<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^(00|\+)([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: \2<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: International to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Caller<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replace 0 by caller’s country code:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^0([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: ${caller_cc}\1<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: National to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Caller<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">This is just if you also want to allow somebody to dial a local number without CC and AC<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Normalize local calls:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: ${caller_cc}${caller_ac}\1<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: Local to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Caller<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">And again the same for the Callee number:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Strip leading 00 or +<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^(00|\+)([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: \2<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: International to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Callee<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replace 0 by caller’s country code:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^0([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: ${caller_cc}\1<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: National to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Callee<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">This is just if you also want to receive calls from somebody with a local number without CC and AC and to see the full number on the subscribers phone.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Normalize areacode-internal calls:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Match Pattern: ^([1-9][0-9]+)$<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Replacement Pattern: ${caller_cc}${caller_ac}\1<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Description: Local to E.164<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Direction: Inbound<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Field: Callee<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Hope this help you a bit.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span lang="DE">Von:</span></b><span lang="DE"> Spce-user [<a href="mailto:spce-user-bounces@lists.sipwise.com">mailto:spce-user-bounces@lists.sipwise.com</a>]
<b>Im Auftrag von </b>Syaiful Bahri Kamaruddin<br>
<b>Gesendet:</b> Donnerstag, 8. März 2018 12:04<br>
<b>An:</b> <a href="mailto:spce-user@lists.sipwise.com">spce-user@lists.sipwise.com</a><br>
<b>Betreff:</b> [Spce-user] NEED HELP On Rewrite Rules<br>
<b>Priorität:</b> Hoch<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="DE-AT"><o:p> </o:p></span></p>
<p class="MsoNormal">Hi All,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">As I installing SPCE Mr 5.5.2 for my school project and used the system for online call and messaging only (sip + xmpp)  (no sip trunk or peering – only intended after further exploration).<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Hereby need some help on rewrite rule . (as mimicking the original number they have on the contact list in their phone)<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">As default system is using ENUM [60 , either mobile code or state code 2/3/4/11/12/13/14/15/16/18/19, subscriber numberXXXXXXXX]<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">My Country code is 60 (Malaysia).<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">How should I do the rewrite call for caller and callee – inbound / outbound<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">As here (on normal operator) can dial : example subscriber number +60 13 6654329<o:p></o:p></p>
<ol style="margin-top:0in" start="1" type="1">
<li class="MsoNormal" style="mso-list:l0 level1 lfo2">00 60 13 xxxx  – can go through<o:p></o:p></li><li class="MsoNormal" style="mso-list:l0 level1 lfo2">+60     13 xxxx – can go through<o:p></o:p></li><li class="MsoNormal" style="mso-list:l0 level1 lfo2">013 xxxx – can go through<o:p></o:p></li></ol>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">How can I setup the call rewrite in the admin so either a caller dial by the initial prefix ie: 0060 , +60 , 013   still can pass to the subscriber number of  60136654329 set in the admin ENUM form. ( so using any SIP Apk need not to change
 their contact number which they might set either 3 way of the above. <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Your help is highly appreciated.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Best Regards<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Syaiful<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Newbie..<o:p></o:p></p>
<p class="MsoListParagraph"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>