cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1172
Views
0
Helpful
1
Replies

Regular expressions and content filters

coulbournc
Level 1
Level 1

I'm having difficulty dropping unwanted mail that contain chinese characters. I have a content filter that looks for the gb2312 charset but it fails to match properly.

Sample header:
Content-Type: text/html; charset="gb2312"

Filter:
header("Content-type") == "(?i)gb2312"
I run a trace and it does not match and the message gets through.
I have noticed some messages have the Content-type header with a different case like "Content-Type". I tried it both ways and it fails.
Some messsages are chines but do not specify a character set. I typically see somethiong like ?utf-8? in the subject line and that will not match either.

1 Reply 1

kluu_ironport
Level 2
Level 2

You may have try and match the message-body of the email. The following support portal kb article goes over the common character sets and how to match against it.

How to block Russian / Cyrillic / Ukrainian char sets

http://tinyurl.com/23287c

-kevin