Mobiion Forum  
February 04, 2012, 01:00:40 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: 1   Go Down
  Print  
Author Topic: RegEx Rules Problem  (Read 769 times)
funnyPC
Newbie
*
Offline Offline

Posts: 5


View Profile
« on: August 17, 2010, 12:26:53 am »

When RegEx rules defined in SMS filters, SMS with words not defined in expressions are also filtered.

To confirm this bug, I use the 'Run Application' action with different parameter to show a dialog when filters works, so I could distinguish which rules has problem. But the result shows, messages are wrongly filtered by random rules.

So I think there's a character compare bug in regex function when use unicode charset (Simplified Chinese in my case)

« Last Edit: August 18, 2010, 11:36:04 pm by funnyPC » Logged
admin
Administrator
Hero Member
*****
Offline Offline

Posts: 1185


View Profile
« Reply #1 on: August 17, 2010, 08:26:53 pm »

No, RegEx in MagiCall can and only can filter Unicode characters.
Can you provide your SMS filter? Maybe I can find problem from it.
Logged
funnyPC
Newbie
*
Offline Offline

Posts: 5


View Profile
« Reply #2 on: August 18, 2010, 04:07:03 am »

for example, sms does NOT include any one of following words often filtered by this rule:

Quote
<[现房|名城|开盘|典藏|旺铺|金铺|美宅|美墅|高层|户型].*\d{4,}>

I don't know if your system could display chinese correctly,so I uploaded pictures also(with another rules).


* Screen001.png (19.43 KB, 320x240 - viewed 108 times.)

* Screen002.png (19.55 KB, 320x240 - viewed 1108 times.)
Logged
funnyPC
Newbie
*
Offline Offline

Posts: 5


View Profile
« Reply #3 on: August 18, 2010, 04:10:25 am »

ps:

I use many '.*' pattern in rules because spam sms sender insert chars such as '.\~;%' to evade sms filter applications without regex support.
Logged
admin
Administrator
Hero Member
*****
Offline Offline

Posts: 1185


View Profile
« Reply #4 on: August 18, 2010, 01:08:47 pm »

Hi, there is a problem in your regular expression. You use [] to enclose keywords, which is a wrong way. [] is used to define character class, every character in it is a keyword. You may just replace [] with (), it should work:

<(现房|名城|开盘|典藏|旺铺|金铺|美宅|美墅|高层|户型).*\d{4,}>
Logged
funnyPC
Newbie
*
Offline Offline

Posts: 5


View Profile
« Reply #5 on: August 18, 2010, 11:35:02 pm »

thanks for reply, i'll correct it & test for some days...
Logged
Pages: 1   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006, Simple Machines LLC Valid XHTML 1.0! Valid CSS!