<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Thomas,<div><br></div><div>Sure, you can't find a regexp to match a list of random numbers, as the whole point of a regexp is to match numbers which have some common part(s).</div><div>And also, the RegExp implementation in FreeSWITCH is not as complete as in the lib (named placeholders for example would be nice).</div><div><br></div><div>I think in your situation, you should go for the simplest/easiest.</div><div>Just add a condition before the one with your regexp, with break on-true:</div><div><br></div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#1C00FF"><font class="Apple-style-span" color="#000000" face="Helvetica"><span class="Apple-style-span" style="font-size: medium;"><condition field="caller_id_number" expression="^03066664|</span></font></font></span>0800330\d$" break="on-true"></div><div> <action application="hangup"/></div><div></condition></div><div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#1C00FF"><font class="Apple-style-span" color="#000000" face="Helvetica"><span class="Apple-style-span" style="font-size: medium; "><condition field="caller_id_number" expression="^your regexp from hell</span></font></font></span>$"></div></div><div>etc...</div><div><br></div><div>If you need to manage this blacklist from a DB, I would do something different:</div><div><div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#1C00FF"><font class="Apple-style-span" color="#000000" face="Helvetica"><span class="Apple-style-span" style="font-size: medium; "><br></span></font></font></span></div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#1C00FF"><font class="Apple-style-span" color="#000000" face="Helvetica"><span class="Apple-style-span" style="font-size: medium; "><condition field="caller_id_number" expression="^your regexp from hell</span></font></font></span>$"></div></div></div><div><div> <action application="lua" data="validate-callerid.lua"/></div></div><div> etc....</div><div></condition></div><div><br></div><div>validate-callerid.lua is a rather easy to write LUA script, where you check the caller_id_number variable against your DB (one SQL SELECT) and if it matches, you can hangup or redirect the call to a message saying "Due to the past activity from your number, your calls to our system have been filtered".</div><div>If it doesn't match, you do nothing, and the dialplan will go to the next action, where your "bridge" is, probably.</div><div><br></div><div>You may rather call this LUA from a previous extension, quite early in the dialplan, if you want to drop the call ASAP and globally for all your platform.</div><div><br></div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "></span></div><div><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#1C00FF"><font class="Apple-style-span" color="#000000" face="Helvetica"><span class="Apple-style-span" style="font-size: medium;"></span></font>David Ponzone </font></span><span class="Apple-style-span" style="font-family: 'Helvetica Neue'; font-size: 14px; "><font class="Apple-style-span" color="#000000" size="3"><span class="Apple-style-span" style="font-size: 12px; ">Direction Technique</span></font></span></div><div><div><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><font class="Apple-style-span" face="'Helvetica Neue'"><font class="Apple-style-span" size="3"><span class="Apple-style-span" style="font-size: 13px; ">email: <a href="mailto:david.ponzone@ipeva.fr">david.ponzone@ipeva.fr</a></span></font></font></div><div><font class="Apple-style-span" face="'Helvetica Neue'"><font class="Apple-style-span" size="3"><span class="Apple-style-span" style="font-size: 13px; ">tel: 01 74 03 18 97</span></font></font></div><div><font class="Apple-style-span" face="'Helvetica Neue'"><font class="Apple-style-span" size="3"><span class="Apple-style-span" style="font-size: 13px; ">gsm: 06 66 98 76 34</span></font></font></div><div><font class="Apple-style-span" face="'Helvetica Neue'"><br></font></div><div><font class="Apple-style-span" color="#1C00FF" face="'Helvetica Neue'">Service Client<span class="Apple-converted-space"> </span></font><font class="Apple-style-span" face="'Helvetica Neue'"><font class="Apple-style-span" color="#FF0000">IP</font></font><font class="Apple-style-span" color="#1C00FF" face="'Helvetica Neue'">eva</font></div><div><font class="Apple-style-span" color="#1C00FF" face="'Helvetica Neue'"><span class="Apple-style-span" style="color: rgb(0, 0, 0); font-family: Helvetica; "><div><font class="Apple-style-span" face="'Helvetica Neue'"><font class="Apple-style-span" size="3"><span class="Apple-style-span" style="font-size: 13px; ">tel: 0811 46 26 26</span></font></font></div><div><font class="Apple-style-span" face="'Helvetica Neue'" size="3"><span class="Apple-style-span" style="font-size: 13px; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Arial; color: rgb(0, 34, 243); "><span style="text-decoration: underline; "><a href="BLOCKED::http://www.ipeva.fr/">www.ipeva.fr</a></span><span style="color: rgb(101, 104, 149); "> - <span style="color: rgb(0, 34, 243); text-decoration: underline; "><a href="BLOCKED::http://www.ipeva-studio.com/">www.ipeva-studio.com</a></span></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Arial; color: rgb(0, 34, 243); "><span class="Apple-style-span" style="text-decoration: underline; "><br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 10px/normal Arial; color: rgb(0, 34, 243); "><span class="Apple-style-span"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; text-align: justify; font: normal normal normal 10px/normal Arial; color: rgb(192, 192, 192); "><i>Ce message et toutes les pièces jointes sont confidentiels et établis à l'intention exclusive de ses destinataires. Toute utilisation ou diffusion non autorisée est interdite. Tout message électronique est susceptible d'altération. </i><b><i>IPeva</i></b><i> décline toute responsabilité au titre de ce message s'il a été altéré, déformé ou falsifié. Si vous n'êtes pas destinataire de ce message, merci de le détruire immédiatement et d'avertir l'expéditeur.</i></div><div style="text-decoration: underline; text-align: justify; "><font class="Apple-style-span" color="#C0C0C0"><i><br></i></font></div></span></div></span></font></div></span></font></div></div></span><br class="Apple-interchange-newline"></span><br class="Apple-interchange-newline">
</div>
<br><div><div>Le 11/05/2011 à 23:45, Thomas Hoellriegel a écrit :</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>Hi all, i have create a inbound dialingrestriction for the german landline numbers<br>my expression:<br> ^(0(?:2\d{3}|3[0-1,3-9]\d{2}|[4-6]\d{3}|7[1-9]\d{2}|70[1-9]\d{1}|<br> 8\d{3}|9[1-9]\d{2}|90[1-9]\d{1})\d*)$<br><br>The problem: i cant.t exclude (blacklist) a number for examle:<br>03066664<br>0800330x<br>or so on.<br>I have many calls from callcenters. i must block numbers and ranges.<br>I don.t find a reluar expression for allow al and deny limited numbers.<br>Can your help please? thanks.<br><br><br><br>---------------<br>Du kannst mich jederzeit kostenlos per Festnetz erreichen unter:<br><a href="http://www.blindi.net/callback">http://www.blindi.net/callback</a><br>homepage: http://www.blindi.net<br>blinde-misc mailingliste für blinde. anmeldung unter:<br>http://www.blindi.net/mailman/listinfo/blinde-misc<br>_______________________________________________<br>FreeSWITCH-users mailing list<br>FreeSWITCH-users@lists.freeswitch.org<br>http://lists.freeswitch.org/mailman/listinfo/freeswitch-users<br>UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users<br>http://www.freeswitch.org<br></div></blockquote></div><br></div></body></html>